JP5581838B2 - Automatic focusing control device, electronic camera and automatic focusing control method - Google Patents

Automatic focusing control device, electronic camera and automatic focusing control method Download PDF

Info

Publication number
JP5581838B2
JP5581838B2 JP2010139435A JP2010139435A JP5581838B2 JP 5581838 B2 JP5581838 B2 JP 5581838B2 JP 2010139435 A JP2010139435 A JP 2010139435A JP 2010139435 A JP2010139435 A JP 2010139435A JP 5581838 B2 JP5581838 B2 JP 5581838B2
Authority
JP
Japan
Prior art keywords
filter
control
focus
focusing control
lens
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2010139435A
Other languages
Japanese (ja)
Other versions
JP2012003128A (en
Inventor
克征 鈴木
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
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 JP2010139435A priority Critical patent/JP5581838B2/en
Publication of JP2012003128A publication Critical patent/JP2012003128A/en
Application granted granted Critical
Publication of JP5581838B2 publication Critical patent/JP5581838B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、コントラスト検出方式のオートフォーカス制御(AF制御)を行う自動合焦制御装置、電子カメラ及び自動合焦制御方法に関する。   The present invention relates to an automatic focusing control device, an electronic camera, and an automatic focusing control method for performing contrast detection type autofocus control (AF control).

近年、デジタルカメラやビデオカメラなどの電子カメラには、オートフォーカス装置(自動合焦装置)が設けられている。オートフォーカス装置では主な一つの方式としてコントラスト検出方式が広く利用されている。コントラスト検出方式は、フォーカスレンズを光軸方向に移動させつつ各位置における撮像画像のコントラスト値を求め、コントラスト値が最も高くなるレンズ位置をフォーカス位置として検出する方式である(例えば特許文献1)。   In recent years, electronic cameras such as digital cameras and video cameras have been provided with an autofocus device (autofocus device). In an autofocus device, a contrast detection method is widely used as one of main methods. The contrast detection method is a method of obtaining a contrast value of a captured image at each position while moving the focus lens in the optical axis direction, and detecting a lens position having the highest contrast value as a focus position (for example, Patent Document 1).

特に特許文献1における合焦検出装置は、被写体光のエッジ部分を所定範囲にわたって複数個検出し、各エッジ部分の画素数を検出するエッジ検出手段と、検出された複数のエッジ部分の画素数とその度数から算出される重心値に基づいて被写体の合焦状態を判別する判別手段とを備えた構成となっていた。   In particular, the focus detection apparatus disclosed in Patent Document 1 detects a plurality of edge portions of subject light over a predetermined range, detects edge detection means for detecting the number of pixels in each edge portion, and the detected number of pixels in the plurality of edge portions. The discriminating means for discriminating the in-focus state of the subject based on the gravity center value calculated from the frequency is provided.

特開平4−274405号公報JP-A-4-274405

ところで、近年のデジタルスチルカメラでは、モニタに画像を表示させながらコントラスト値を得るため、ウォブリングによる画像の乱れやAFレンズ群のサーチ時間がかかるという問題があった。   By the way, in recent digital still cameras, there is a problem in that since the contrast value is obtained while displaying an image on a monitor, the image is disturbed due to wobbling and the AF lens group search time is required.

例えば特許文献1のような輝度情報を使用したコントラストによる検出方法では、AFレンズを広範囲で駆動させるため、スルー画表示中や動画撮影中にウォブリングによるぶれた画像となってしまうという問題があった。   For example, the contrast detection method using luminance information as in Patent Document 1 has a problem in that an AF lens is driven in a wide range, resulting in a blurred image due to wobbling during live view display or moving image shooting. .

本発明は上記問題点に鑑みてなされたものであって、その目的は、コントラスト検出方式を採用するオートフォーカス装置において、合焦動作時のウォブリングに起因する画像のぶれを低減できる自動合焦制御装置、電子カメラ及び自動合焦制御方法を提供することにある。   The present invention has been made in view of the above problems, and an object thereof is an automatic focusing control capable of reducing image blurring due to wobbling during a focusing operation in an autofocus apparatus employing a contrast detection method. An apparatus, an electronic camera, and an automatic focusing control method are provided.

上記問題点を解決するために、本発明は、撮影レンズを光軸方向に移動させる第1駆動手段と、撮像手段が取得した画像のコントラスト値に基づいて、前記撮影レンズを合焦位置に配置するよう前記第1駆動手段を制御する第1の合焦制御手段と、前記撮影レンズと前記撮像手段との間の光路に対して挿抜可能に設けられるとともに前記撮影レンズの合焦位置からのずれ量を補償可能な屈折率を有する少なくとも一つのフィルタと、前記フィルタを前記光路に対して挿抜させる第2駆動手段と、前記撮影レンズの合焦位置に対するずれ量を検出する検出手段と、前記検出手段が検出したずれ量に応じた屈折率のフィルタを前記光路に対して挿抜するよう前記第2駆動手段を制御して合焦を行う第2の合焦制御手段と、を備えたことを要旨とする。   In order to solve the above-described problems, the present invention provides a first driving unit that moves the photographic lens in the optical axis direction, and the photographic lens is arranged at a focus position based on a contrast value of an image acquired by the imaging unit. A first focusing control means for controlling the first driving means, and an optical path between the photographing lens and the imaging means, provided so as to be insertable / removable, and a deviation from the focusing position of the photographing lens At least one filter having a refractive index capable of compensating the amount, second drive means for inserting / removing the filter with respect to the optical path, detection means for detecting a shift amount with respect to a focus position of the photographing lens, and the detection And a second focus control means for controlling the second drive means so as to insert and remove a filter having a refractive index corresponding to the deviation detected by the means with respect to the optical path. Toss .

本発明の自動合焦制御装置では、前記フィルタを複数備え、前記第2の合焦制御手段は、複数のフィルタを重ね合わせて光路上に配置することにより複数のフィルタの組合せによって異なる屈折率を作り出すことが好ましい。   The automatic focusing control device according to the present invention includes a plurality of the filters, and the second focusing control unit arranges the plurality of filters on the optical path so that the refractive index varies depending on the combination of the plurality of filters. It is preferable to produce.

本発明の自動合焦制御装置では、前記第2の合焦制御手段は、前記光路上における前記フィルタの挿抜と、前記光路上に挿入された該フィルタの光軸方向における移動とにより合焦を行うことが好ましい。   In the automatic focusing control device according to the present invention, the second focusing control means performs focusing by inserting and removing the filter on the optical path and movement of the filter inserted on the optical path in the optical axis direction. Preferably it is done.

本発明の自動合焦制御装置では、ズームレンズと、前記ズームレンズを光軸方向に移動させて焦点距離を変化させることでズーム量を調整する第3駆動手段と、前記第2の合焦制御手段は、前記ズーム量及び前記ずれ量に応じて前記光路上に挿入すべきフィルタを選択することが好ましい。   In the automatic focusing control device of the present invention, the zoom lens, the third driving means for adjusting the zoom amount by moving the zoom lens in the optical axis direction and changing the focal length, and the second focusing control. The means preferably selects a filter to be inserted on the optical path in accordance with the zoom amount and the shift amount.

本発明の自動合焦制御装置では、前記検出手段は、前記撮像手段が取得した画像のRGB3色の信号値のうち2色毎の組合せの値の比で示される3つの感度比のうち少なくとも1つを算出する感度比算出手段を備え、前記少なくとも1つの感度比に基づいて前記合焦位置からの前記ずれ量を求めることが好ましい。   In the automatic focusing control device according to the present invention, the detection means includes at least one of three sensitivity ratios indicated by a ratio of combinations of two colors among the RGB three-color signal values of the image acquired by the imaging means. It is preferable that a sensitivity ratio calculation unit is provided for calculating a deviation amount from the in-focus position based on the at least one sensitivity ratio.

本発明の自動合焦制御装置では、前記撮像手段で取得されたRGB信号値の前記画像中のエッジ部分を横切るときの傾きを求める傾き算出手段を備え、前記傾きが閾値以上のときに前記第2の合焦制御手段による第2の合焦制御を行い、前記傾きが前記閾値未満になると、前記第2の合焦制御から前記第1の合焦制御手段による第1の合焦制御へ切り替えることが好ましい。   In the automatic focusing control device of the present invention, there is provided an inclination calculation means for obtaining an inclination when the RGB signal value acquired by the imaging means crosses an edge portion in the image, and the first signal is obtained when the inclination is not less than a threshold value. When the second focus control by the second focus control means is performed and the inclination becomes less than the threshold value, the second focus control is switched to the first focus control by the first focus control means. It is preferable.

本発明は、電子カメラであって、被写体を撮影する撮像手段と、上記発明の自動合焦制御装置と、を備えたことを要旨とする。
本発明は、撮影レンズを光軸方向に移動させながら撮像手段が取得した画像のコントラスト値に基づいて、前記撮影レンズを合焦位置に配置するよう合焦制御を行う第1の合焦制御ステップと、前記第1の合焦制御ステップによる合焦が行われた前記撮影レンズの合焦位置に対するずれ量を検出する検出ステップと、前記ずれ量を補償可能な屈折率を有するフィルタが前記撮影レンズの光路上に配置されるように前記光路に対してフィルタの挿抜を行うことで合焦する第2の合焦制御ステップと、を備えたことを要旨とする。
The gist of the present invention is an electronic camera comprising an imaging means for photographing a subject and the automatic focusing control device according to the invention.
The present invention provides a first focus control step for performing focus control so as to place the photographing lens at a focus position based on the contrast value of the image acquired by the imaging means while moving the photographing lens in the optical axis direction. A detecting step for detecting a shift amount of the photographing lens that has been focused by the first focusing control step with respect to a focus position, and a filter having a refractive index that can compensate for the shift amount. And a second focusing control step of focusing by inserting and removing a filter with respect to the optical path so as to be disposed on the optical path.

本発明によれば、コントラスト検出方式を採用するオートフォーカス装置において、合焦動作時のウォブリングに起因する画像のぶれを低減できる、という優れた効果が得られる。   According to the present invention, in an autofocus device that employs a contrast detection method, an excellent effect is obtained that image blur due to wobbling during a focusing operation can be reduced.

電子カメラの斜視図。The perspective view of an electronic camera. 電子カメラの背面図。The rear view of an electronic camera. 電子カメラの電気的構成を示すブロック図。The block diagram which shows the electric constitution of an electronic camera. コントラスト検出方式によるAF制御を説明するグラフ。The graph explaining AF control by a contrast detection system. (a)フィルタ装置の構成を示す模式側面図、(b)その模式正面図。(A) The model side view which shows the structure of a filter apparatus, (b) The model front view. フィルタ挿抜方式の原理を説明する模式側面図。The schematic side view explaining the principle of a filter insertion / extraction system. 撮像光学系における軸上色収差を示す模式側面図。FIG. 3 is a schematic side view showing axial chromatic aberration in an imaging optical system. エッジ検出を説明する主要被写体画像の模式図。FIG. 6 is a schematic diagram of a main subject image for explaining edge detection. 正規化出力R(x),G(x),B(x)を示すグラフ。The graph which shows normalized output R (x), G (x), and B (x). AFレンズ位置によるエッジの傾きの変動を示すグラフ。The graph which shows the fluctuation | variation of the inclination of the edge by AF lens position. AFレンズ位置による感度比の変動を示すグラフ。The graph which shows the fluctuation | variation of the sensitivity ratio by AF lens position. フィルタ非挿入時における撮像光学系を示す模式側面図。The schematic side view which shows the imaging optical system at the time of filter non-insertion. フィルタ挿入時における撮像光学系を示す模式側面図。The schematic side view which shows the imaging optical system at the time of filter insertion. AF制御処理を示すフローチャート。The flowchart which shows AF control processing. 変形例におけるフィルタ装置の構成を示す模式側面図。The schematic side view which shows the structure of the filter apparatus in a modification.

以下、本発明を電子カメラの一種であるデジタルカメラに具体化した一実施形態を図1〜図14に基づいて説明する。
図1はデジタルカメラの斜視図、図2はその背面図である。図1に示すように、本実施形態のデジタルカメラ(以下、単に「カメラ11」という)は、略直方体形状をなすカメラ本体12を有している。カメラ本体12の前面(正面)略中央部には撮像レンズ13を内装した伸縮自在な鏡筒13aが設けられるとともに、鏡筒13aよりも上側となる二位置にはストロボ14(フラッシュ)、合焦動作時に赤外線等を被写体に向けて照射する発光体及びセルフ撮影を行うときに点滅するセルフLED等の光を照射する照射窓部15が設けられている。
Hereinafter, an embodiment in which the present invention is embodied in a digital camera which is a kind of electronic camera will be described with reference to FIGS.
FIG. 1 is a perspective view of a digital camera, and FIG. 2 is a rear view thereof. As shown in FIG. 1, the digital camera of the present embodiment (hereinafter simply referred to as “camera 11”) has a camera body 12 having a substantially rectangular parallelepiped shape. The camera body 12 is provided with a telescopic lens barrel 13a with an imaging lens 13 in the front (front) substantially central portion thereof, and a strobe 14 (flash) and in-focus at two positions above the lens barrel 13a. A light emitting body that irradiates infrared rays or the like toward a subject during operation and an irradiation window portion 15 that irradiates light such as a self LED that blinks when performing self-photographing are provided.

また、カメラ本体12の上面には左寄りの二位置に電源スイッチ17及びレリーズスイッチ18が設けられ、略中央寄りの位置にスピーカ19が設けられている。電源スイッチ17は、カメラ11を電源オン状態とするときに撮像者により押し下げ操作されるものである。レリーズスイッチ18はカメラ11に撮像動作を開始させるときに撮像者により押し下げ操作(すなわち、オン操作)される操作ボタンである。   Further, on the upper surface of the camera body 12, a power switch 17 and a release switch 18 are provided at two positions on the left side, and a speaker 19 is provided at a position near the center. The power switch 17 is pressed down by the photographer when the camera 11 is turned on. The release switch 18 is an operation button that is pushed down (ie, turned on) by the photographer when the camera 11 starts an imaging operation.

一方、図2に示すように、カメラ本体12の背面側には、矩形状をなすモニタ20が設けられている。モニタ20は、一例として液晶表示装置(LiquidCrystalDisplay)(LCD)により構成されている。そして、モニタ20の上側右寄りの位置には静止画モードと動画モードとの間で切り換可能なモード選択スイッチ21が設けられている。また、カメラ本体12の背面におけるモニタ20の右上位置には、主として撮像レンズ13をズームアップ又はズームダウンさせるときに操作されるズームボタン22が設けられている。ズームボタン22の下側位置には、主としてモニタ20にメニュー画面を表示させるときに操作されるメニューボタン23が設けられている。   On the other hand, as shown in FIG. 2, a rectangular monitor 20 is provided on the back side of the camera body 12. As an example, the monitor 20 includes a liquid crystal display (LCD). A mode selection switch 21 that can be switched between the still image mode and the moving image mode is provided at a position on the upper right side of the monitor 20. A zoom button 22 that is mainly operated when zooming up or down the imaging lens 13 is provided at the upper right position of the monitor 20 on the back of the camera body 12. A menu button 23 that is operated mainly when displaying a menu screen on the monitor 20 is provided below the zoom button 22.

また、メニューボタン23の下方には、撮影ボタン24と再生ボタン25とが設けられている。再生モード中に撮影ボタン24を操作すると撮影モードに切り換わり、撮影モード中に再生ボタン25を操作すると再生モードに切り換わるようになっている。動画撮影を行う際は、動画モードかつ撮影モードにし、レリーズスイッチ18を操作すると動画撮影が開始され、その動画撮影中にレリーズスイッチ18を操作するとその動画撮影が終了するようになっている。   In addition, a shooting button 24 and a playback button 25 are provided below the menu button 23. When the shooting button 24 is operated during the playback mode, the mode is switched to the shooting mode, and when the playback button 25 is operated during the shooting mode, the mode is switched to the playback mode. When performing moving image shooting, the moving image mode is set to the shooting mode and the release switch 18 is operated to start moving image shooting. When the release switch 18 is operated during the moving image shooting, the moving image shooting is ended.

さらに各ボタン24,25の下側位置には、上下左右の4方向を含む複数方向の選択操作が可能なセレクトボタン26(選択ボタン)が設けられ、その中央部には決定ボタン27(OKボタン)が設けられている。セレクトボタン26は、主としてメニュー画面における項目の選択及び設定内容の変更を行う操作に用いられる。決定ボタン27は、メニュー画面で選択した項目や設定内容を確定(決定)する操作に用いられる。   Further, a select button 26 (select button) capable of selecting in a plurality of directions including four directions of up, down, left and right is provided at a lower position of each button 24, 25, and an enter button 27 (OK button) is provided at the center. ) Is provided. The select button 26 is mainly used for an operation of selecting an item on the menu screen and changing a setting content. The determination button 27 is used for an operation of confirming (determining) an item or setting content selected on the menu screen.

次に、本実施形態のカメラ11における回路構成を図3に示すブロック図に基づき説明する。図3に示すように、カメラ11は各種動作を統括的に制御するMPU(Micro Processing Unit)などからなるエンジン30を備えている。エンジン30はコンピュータ31を内蔵し、コンピュータ31が各種プログラムを実行することによりカメラ11の各種制御を行う。また、カメラ11は、撮像レンズ13のレンズ群を通過した被写体光を撮像レンズ13の像空間側において結像させるための撮像素子32をカメラ本体12内に有している。この撮像素子32は、例えばCCD(Charge Coupled Device)イメージセンサ、又はCMOS(Complementary Metal Oxide Semiconductor)イメージセンサからなり、その撮像面に結像した被写体像に対応した信号電荷を蓄積し、その蓄積した信号電荷を画素信号と呼ばれるアナログ信号として出力する。なお、撮像素子32は、電源スイッチ17が押し下げ操作された後において、レリーズスイッチ18が押し下げ操作される前段階の待機モードにおいても、被写体の経時変化するスルー画像の画素信号を出力し得るように構成されている。   Next, the circuit configuration of the camera 11 of the present embodiment will be described based on the block diagram shown in FIG. As shown in FIG. 3, the camera 11 includes an engine 30 including an MPU (Micro Processing Unit) that comprehensively controls various operations. The engine 30 includes a computer 31 and controls the camera 11 by the computer 31 executing various programs. In addition, the camera 11 has an imaging element 32 in the camera body 12 for forming an image of subject light that has passed through the lens group of the imaging lens 13 on the image space side of the imaging lens 13. The imaging element 32 is composed of, for example, a CCD (Charge Coupled Device) image sensor or a CMOS (Complementary Metal Oxide Semiconductor) image sensor, and accumulates signal charges corresponding to the subject image formed on the imaging surface. The signal charge is output as an analog signal called a pixel signal. It should be noted that the imaging element 32 can output a pixel signal of a through image that changes with time in the subject even in the standby mode before the release switch 18 is pressed after the power switch 17 is pressed down. It is configured.

図3に示す撮像レンズ13は、鏡筒13a内に、撮影画角を変更するズームレンズ33a、焦点を合わせるフォーカスレンズ33bを備えている。そして、鏡筒13a内には、絞り34及びシャッタ35が設けられている。さらにフォーカスレンズ33bと撮像素子32との間には、フィルタ37を撮像レンズ13の光路に対して挿抜可能な状態に備えるフィルタ装置36が設けられている。本例では、フィルタ37は複数枚備えられている。   The imaging lens 13 shown in FIG. 3 includes a zoom lens 33a for changing the shooting angle of view and a focus lens 33b for focusing in the lens barrel 13a. A diaphragm 34 and a shutter 35 are provided in the lens barrel 13a. Further, a filter device 36 is provided between the focus lens 33 b and the image pickup device 32 so that the filter 37 can be inserted into and removed from the optical path of the image pickup lens 13. In this example, a plurality of filters 37 are provided.

エンジン30には、撮像レンズ13、絞り34、シャッタ35及びフィルタ装置36などを撮影条件に応じて駆動制御するため、フィルタ駆動回路38、フォーカス駆動回路39、シャッタ駆動回路40、絞り駆動回路41及びズーム駆動回路42が接続されている。   The engine 30 includes a filter driving circuit 38, a focus driving circuit 39, a shutter driving circuit 40, an aperture driving circuit 41, and the like in order to drive and control the imaging lens 13, the diaphragm 34, the shutter 35, the filter device 36, and the like according to the shooting conditions. A zoom drive circuit 42 is connected.

ズームレンズ33aは、ズーム用モータ43の駆動により光軸方向に沿って移動可能に構成されている。エンジン30はズーム駆動回路42を介してズーム用モータ43を駆動制御し、ズームレンズ33aを光軸方向に移動させることによって撮影画角を変更する。   The zoom lens 33 a is configured to be movable along the optical axis direction by driving the zoom motor 43. The engine 30 drives and controls the zoom motor 43 via the zoom drive circuit 42, and changes the shooting angle of view by moving the zoom lens 33a in the optical axis direction.

フォーカスレンズ33bは、フォーカス用モータ(以下、「AFモータ44」と称す)の駆動により光軸方向に沿って移動可能に構成されている。エンジン30はフォーカス駆動回路39を介してAFモータ44を駆動制御し、フォーカスレンズ33bを光軸方向に移動させることによって焦点を合わせ、例えば撮像レンズ13を透過した被写体光を撮像素子32の像面に結像させる。このとき、エンジン30は、AFセンサ45の検出信号に基づきフォーカスレンズ33bの光軸方向の位置を取得する。   The focus lens 33b is configured to be movable along the optical axis direction by driving a focus motor (hereinafter referred to as “AF motor 44”). The engine 30 drives and controls the AF motor 44 via the focus drive circuit 39 to focus by moving the focus lens 33b in the optical axis direction, for example, subject light transmitted through the imaging lens 13 is image plane of the imaging device 32. To form an image. At this time, the engine 30 acquires the position of the focus lens 33b in the optical axis direction based on the detection signal of the AF sensor 45.

絞り34は、絞り駆動回路41により駆動される不図示のアクチュエータにより駆動される。エンジン30は絞り駆動回路41を介してアクチュエータを駆動制御することによって絞り34を調節し、撮像レンズ13を通過する光量を調整する。   The diaphragm 34 is driven by an actuator (not shown) driven by the diaphragm drive circuit 41. The engine 30 adjusts the amount of light passing through the imaging lens 13 by adjusting the diaphragm 34 by driving and controlling the actuator via the diaphragm drive circuit 41.

シャッタ35は、シャッタ駆動回路40により駆動される不図示のアクチュエータにより開閉可能に構成されている。エンジン30はシャッタ駆動回路40を介してアクチュエータを駆動制御することによってシャッタ35を作動させ、露光時間を制御する。   The shutter 35 can be opened and closed by an actuator (not shown) driven by a shutter drive circuit 40. The engine 30 controls the exposure time by operating the shutter 35 by controlling the driving of the actuator via the shutter driving circuit 40.

また、エンジン30には、撮像素子32に接続された撮像制御回路47及び映像回路48が接続されている。撮像制御回路47は、撮像素子32を駆動して、露光時間制御、結像された像の電気信号への変換、変換した電気信号の出力等を制御する。   In addition, an imaging control circuit 47 and a video circuit 48 connected to the imaging device 32 are connected to the engine 30. The imaging control circuit 47 drives the imaging device 32 to control exposure time control, conversion of the formed image into an electrical signal, output of the converted electrical signal, and the like.

映像回路48は、撮像素子32の出力する電気信号を増幅し、デジタル信号に変換してエンジン30に出力する。詳しくは、撮像素子32の出力側に直列に接続されている映像回路48は、AFE(Analog Front End)部とA/D変換器とを有している。AFE部は、撮像素子32で光電変換されて出力されたアナログ信号からなる画素信号を所定のタイミングでサンプリング(相関二重サンプリング)して、例えばISO感度に基づく所定の信号レベルとなるように増幅させる。A/D変換器は、AFE部から出力された増幅後の画素信号(アナログ信号)をデジタル信号に変換し、このデジタル画素信号をエンジン30に出力する。   The video circuit 48 amplifies the electrical signal output from the image sensor 32, converts it into a digital signal, and outputs it to the engine 30. Specifically, the video circuit 48 connected in series to the output side of the image sensor 32 has an AFE (Analog Front End) unit and an A / D converter. The AFE unit samples a pixel signal composed of an analog signal that has been photoelectrically converted by the image pickup device 32 and outputs it at a predetermined timing (correlated double sampling), and amplifies the signal to a predetermined signal level based on, for example, ISO sensitivity. Let The A / D converter converts the amplified pixel signal (analog signal) output from the AFE unit into a digital signal, and outputs the digital pixel signal to the engine 30.

エンジン30は、映像回路48から入力したデジタル画素信号に対して、色補間処理、階調補正、ホワイトバランス処理及び輪郭補償等の画像処理を施すことにより所定の画像データを生成する。   The engine 30 generates predetermined image data by performing image processing such as color interpolation processing, gradation correction, white balance processing, and contour compensation on the digital pixel signal input from the video circuit 48.

さらに、エンジン30には、バスを介して不揮発性メモリ49及びバッファメモリ50が接続されている。また、エンジン30には、モニタ制御回路51(LCD駆動回路)、メモリ制御回路52及び操作検出回路53等が接続されている。   Furthermore, a nonvolatile memory 49 and a buffer memory 50 are connected to the engine 30 via a bus. Further, a monitor control circuit 51 (LCD drive circuit), a memory control circuit 52, an operation detection circuit 53, and the like are connected to the engine 30.

不揮発性メモリ49には、エンジン30を動作させるためにエンジン30内のコンピュータ31が実行するためのプログラムが記憶されている。本実施形態では、図14にフローチャートで示す自動合焦制御(AF制御)用のプログラムなどが不揮発性メモリ49に記憶されている。また、不揮発性メモリ49には、フィルタ装置36を用いた自動合焦制御で使用するマップデータM1,M2,…Mmが記憶されている。このマップデータM1〜Mmについては後述する。   The nonvolatile memory 49 stores a program that is executed by the computer 31 in the engine 30 in order to operate the engine 30. In the present embodiment, a program for automatic focusing control (AF control) shown in the flowchart of FIG. Further, the nonvolatile memory 49 stores map data M1, M2,... Mm used in automatic focusing control using the filter device 36. The map data M1 to Mm will be described later.

バッファメモリ50は、撮影画像データを一時的に格納し、画像処理過程のデータ、画像処理後のデータ、画像圧縮後のデータ、さらにエンジン30のその他の処理過程のデータの一時記憶に使用される。バッファメモリ50は、例えばDRAM等により構成される。   The buffer memory 50 temporarily stores captured image data, and is used for temporary storage of data in the image processing process, data after image processing, data after image compression, and data in other processing processes of the engine 30. . The buffer memory 50 is composed of, for example, a DRAM.

エンジン30が画像処理を行って生成した画像データは、バッファメモリ50に一時記憶される。エンジン30は、バッファメモリ50に一時記憶した画像データをモニタ制御回路51へ送り、モニタ制御回路51は画像データに基づく画像をモニタ20に表示させる。モニタ20には、例えばスルー画像、撮影中の動画画像、撮影直後の確認画像(静止画)、再生画像(再生動画・再生静止画)が表示される。   Image data generated by the image processing by the engine 30 is temporarily stored in the buffer memory 50. The engine 30 sends the image data temporarily stored in the buffer memory 50 to the monitor control circuit 51, and the monitor control circuit 51 causes the monitor 20 to display an image based on the image data. On the monitor 20, for example, a through image, a moving image being photographed, a confirmation image (still image) immediately after photographing, and a reproduced image (reproduced moving image / reproduced still image) are displayed.

その後、エンジン30は、バッファメモリ50から画像データを読出して、例えばJPEG方式でデータ圧縮処理を行い、圧縮処理後の画像データを含む画像ファイルを生成し、生成した画像ファイルをメモリ制御回路52に接続された不図示のカードスロットを介してカメラ11に着脱可能とされたメモリカード54に記憶するようになっている。また、エンジン30は、メモリカード54から画像ファイルを読出して伸張処理を施した後の画像データをバッファメモリ50に一時記憶させてモニタ制御回路51を介してモニタ20に再生画像(再生動画・再生静止画)を表示させる。   Thereafter, the engine 30 reads the image data from the buffer memory 50, performs data compression processing by, for example, the JPEG method, generates an image file including the image data after the compression processing, and sends the generated image file to the memory control circuit 52. The data is stored in a memory card 54 that can be attached to and detached from the camera 11 through a connected card slot (not shown). The engine 30 also reads the image file from the memory card 54 and decompresses the image data, temporarily stores the image data in the buffer memory 50, and reproduces the reproduced image (reproduced moving image / reproduced image) on the monitor 20 via the monitor control circuit 51. (Still image) is displayed.

モニタ制御回路51は、エンジン30より出力された表示データをモニタ20に出力するとともに、モニタ20の点灯、消灯、表示制御を行い、モニタ20にスルー画や再生画像等を表示させる。   The monitor control circuit 51 outputs the display data output from the engine 30 to the monitor 20 and controls the monitor 20 to turn on / off and display, thereby causing the monitor 20 to display a through image, a reproduced image, and the like.

メモリ制御回路52は、メモリカード54を挿抜可能な構造のスロットを有し、スロットに挿着されたメモリカード54に撮影画像ファイルを転送・記憶したり、メモリカード54に記憶されている画像ファイル等の情報を読み取り、エンジン30に出力したりする機能を有している。   The memory control circuit 52 has a slot having a structure in which the memory card 54 can be inserted and removed, and transfers and stores a photographed image file in the memory card 54 inserted in the slot, or an image file stored in the memory card 54 Etc., and has a function of outputting the information to the engine 30.

操作検出回路53には、電源スイッチ17、レリーズスイッチ18、モード選択スイッチ21、ズームボタン22、メニューボタン23、撮影ボタン24、再生ボタン25、セレクトボタン26及び決定ボタン27などの各種操作スイッチが接続されている(但し、図3では一部のスイッチ(ボタン)のみ図示)。操作検出回路53は、ユーザーによるスイッチ操作を検出してその操作情報をエンジン30に出力する。   Various operation switches such as a power switch 17, a release switch 18, a mode selection switch 21, a zoom button 22, a menu button 23, a shooting button 24, a playback button 25, a select button 26, and an enter button 27 are connected to the operation detection circuit 53. (However, only some switches (buttons) are shown in FIG. 3). The operation detection circuit 53 detects a switch operation by the user and outputs the operation information to the engine 30.

エンジン30内のコンピュータ31は、不揮発性メモリ49に記憶されたプログラムを実行してカメラ11の動作を制御するとともに、撮影された画像の処理及び再生を行う。エンジン30は、電源スイッチ17の操作に応答してカメラ11の電源の投入(ON)/遮断(OFF)を行う。また、エンジン30は、電源ON状態の下で、ズームボタン22の操作に応答してズーム駆動回路42を介してズーム用モータ43を駆動してズームレンズ33aを移動させるズーミング動作を行わせ、フォーカス駆動回路39を介してAFモータ44を駆動してフォーカスレンズ33bを移動させるフォーカシング動作を行わせる。さらに、エンジン30は、絞り駆動回路41及びシャッタ駆動回路40を駆動して絞り34の調整及びシャッタ35の開放時間調整を行うことにより露出制御を行う。   The computer 31 in the engine 30 executes a program stored in the non-volatile memory 49 to control the operation of the camera 11 and processes and reproduces the captured image. The engine 30 turns on (ON) / cuts off (OFF) the power of the camera 11 in response to the operation of the power switch 17. In addition, the engine 30 performs a zooming operation in which the zoom lens 33a is moved by driving the zoom motor 43 via the zoom drive circuit 42 in response to the operation of the zoom button 22 under the power ON state. The AF motor 44 is driven via the drive circuit 39 to perform a focusing operation for moving the focus lens 33b. Further, the engine 30 controls the exposure by driving the aperture driving circuit 41 and the shutter driving circuit 40 to adjust the aperture 34 and the opening time of the shutter 35.

エンジン30は、撮影準備段階においてはシャッタ35を開放し、撮像レンズ13を透過した光を撮像素子32に結像させる。撮像素子32に結像した被写体像はエンジン30によって周期的に画像処理され、被写体を動画的にモニタ20に映し出すことにより、モニタ20にスルー画が表示される。   The engine 30 opens the shutter 35 and forms an image of the light transmitted through the imaging lens 13 on the imaging element 32 in the shooting preparation stage. The subject image formed on the image sensor 32 is periodically subjected to image processing by the engine 30, and the subject is projected on the monitor 20 as a moving image, whereby a through image is displayed on the monitor 20.

また、エンジン30によって、画像のコントラストを検出し、フォーカスレンズ33bを移動させ、最もコントラストの高いフォーカスレンズ位置を探索し、その位置にフォーカスレンズ33bを移動させることによりオートフォーカス制御(AF制御)を行う。   Further, the engine 30 detects the contrast of the image, moves the focus lens 33b, searches for the focus lens position with the highest contrast, and moves the focus lens 33b to that position, thereby performing autofocus control (AF control). Do.

また、エンジン30は画像の輝度レベルを検出し、検出した輝度レベルから絞り34とシャッタ35のシャッタ速度を制御して自動露出制御(AE制御)を行う。
図4は、エンジン30内のCPU(コンピュータ)がプログラムを実行することによりエンジン30内に構築される機能構成を示す。図4に示すように、エンジン30内のコンピュータ31には、主制御部61、画像処理部62、ズーム制御部63、切換制御部64、第1合焦制御部65、第2合焦制御部66、表示制御部67などが備えられている。なお、コンピュータ31内の各機能部は、AF制御及びズーム制御に関係する部分のみを示し、その他の各種制御に係る機能部分は省略している。
The engine 30 detects the brightness level of the image, and controls the shutter speed of the diaphragm 34 and the shutter 35 based on the detected brightness level to perform automatic exposure control (AE control).
FIG. 4 shows a functional configuration constructed in the engine 30 when a CPU (computer) in the engine 30 executes a program. As shown in FIG. 4, the computer 31 in the engine 30 includes a main control unit 61, an image processing unit 62, a zoom control unit 63, a switching control unit 64, a first focusing control unit 65, and a second focusing control unit. 66, a display control unit 67, and the like. In addition, each function part in the computer 31 shows only a part related to AF control and zoom control, and other function parts related to various controls are omitted.

主制御部61は、各部を統括制御し、AF制御、ズーム制御以外に、絞り制御、シャッタ制御などを行う。
画像処理部62は、撮像素子32から映像回路48(図3を参照)を介して入力した画素信号に基づいて各種の画像処理(ホワイトバランス処理等)を施して画像データを生成する画像処理を行う機能を有している。画像処理部62は、顔検出部62Aを備えている。顔検出部62Aは、画像中における人物の顔を検出する顔検出を行う。両眼、鼻、口などの顔の部品の特徴を抽出しその特徴量に基づいて顔の各部品を抽出し、両眼と鼻と口の各位置関係を利用して顔を検出する。顔検出部62Aは、検出した顔について、さらに瞳検出、顔向き検出、顔輪郭検出、表情検出(笑顔検出)などの顔に関する各種検出処理を行う。AF制御では、検出した顔に焦点を合わせるようにフォーカスレンズの位置制御が行われる。このため、検出した顔のコントラスト評価値が最大になるようにフォーカスレンズの位置制御が行われる。
The main control unit 61 performs overall control of each unit, and performs aperture control, shutter control, and the like in addition to AF control and zoom control.
The image processing unit 62 performs image processing for generating image data by performing various types of image processing (white balance processing or the like) based on pixel signals input from the image sensor 32 via the video circuit 48 (see FIG. 3). Has the function to perform. The image processing unit 62 includes a face detection unit 62A. The face detection unit 62A performs face detection for detecting a human face in the image. Features of facial parts such as binoculars, nose and mouth are extracted, each part of the face is extracted based on the feature amount, and a face is detected using each positional relationship between both eyes, nose and mouth. The face detection unit 62A performs various detection processes relating to the detected face, such as pupil detection, face orientation detection, face contour detection, and facial expression detection (smile detection). In AF control, focus lens position control is performed so as to focus on the detected face. For this reason, focus lens position control is performed so that the detected contrast evaluation value of the face is maximized.

ズーム制御部63は、ズームボタン22の操作に基づき広角側と望遠側のうちその操作方向に応じた回転方向へズーム用モータ43を駆動させることにより、ズームレンズ33aを広角側と望遠側のうちその操作方向に応じた方向へ移動させてズーム(倍率)の調節を行う。   The zoom control unit 63 drives the zoom motor 43 in the rotation direction corresponding to the operation direction of the wide-angle side and the telephoto side based on the operation of the zoom button 22, thereby moving the zoom lens 33a between the wide-angle side and the telephoto side. The zoom (magnification) is adjusted by moving in the direction corresponding to the operation direction.

切換制御部64、第1合焦制御部65及び第2合焦制御部66は、AF制御装置の制御手段を構成し、これらの各制御部64〜66によりAF制御が行われる。そして、切換制御部64は、第1合焦制御部65と第2合焦制御部66のうち一方を選択して両者の間でAF制御の主体を切り換える。   The switching control unit 64, the first focusing control unit 65, and the second focusing control unit 66 constitute a control unit of the AF control device, and AF control is performed by each of these control units 64-66. Then, the switching control unit 64 selects one of the first focusing control unit 65 and the second focusing control unit 66 and switches the subject of the AF control between them.

ここで、第1合焦制御部65は、コントラスト検出方式のAF制御を行う。第1合焦制御部65は、コントラスト検出部71、レンズ制御部72及びサーチ部73を備えている。コントラスト検出部71は、撮像素子32により撮像されてエンジン30に入力された画像データに対して顔検出部62Aが検出した顔の領域のコントラストを検出する。レンズ制御部72は、AFモータ44を駆動させてフォーカスレンズ33bを光軸方向に移動させるレンズ位置制御を行う。   Here, the first focus control unit 65 performs AF detection using a contrast detection method. The first focus control unit 65 includes a contrast detection unit 71, a lens control unit 72, and a search unit 73. The contrast detection unit 71 detects the contrast of the face area detected by the face detection unit 62 </ b> A from the image data captured by the image sensor 32 and input to the engine 30. The lens control unit 72 performs lens position control for driving the AF motor 44 to move the focus lens 33b in the optical axis direction.

サーチ部73は、レンズ制御部72がAFモータ44を駆動させてフォーカスレンズ33bを光軸方向に移動させつつコントラスト検出部71が各レンズ位置毎に検出及び算出したコントラスト評価値を逐次取得して、今回と前回の各評価値を比較しつつ、所謂「山登り制御」を行って、最大のコントラスト評価値となるレンズ位置(AFモータパルス数)をサーチする。   The search unit 73 sequentially acquires the contrast evaluation values detected and calculated by the contrast detection unit 71 for each lens position while the lens control unit 72 drives the AF motor 44 to move the focus lens 33b in the optical axis direction. The so-called “mountain climbing control” is performed while comparing the current evaluation value with the previous evaluation value, and the lens position (the number of AF motor pulses) that provides the maximum contrast evaluation value is searched.

図4は、コントラスト検出方式によるAF制御を説明するグラフである。このグラフにおいて、横軸はレンズ位置(AFモータパルス数)であり、縦軸はコントラスト評価値である。例えばAF制御開始位置がP1であるとすると、フォーカスレンズ33bを光軸方向に1パルスずつ移動させつつコントラスト評価値Cを算出し、各レンズ位置P1,P2,…毎にコントラスト評価値C1,C2,…を逐次算出する所謂「山登り制御」を行い、最大のコントラスト評価値Cmaxとなるレンズ位置Pmax(AFモータパルス数)を求める。図5に示すように、例えば、位置P1→P2→…→Pn→Pn+1ときて、位置Pnの評価値Cnと位置Pn+1の評価値Cn+1とを比較したときに、それまで増加していた評価値が減少するか又は同じ値をとると、サーチ部73は、それまでで最大の評価値Cn(=Cmax)をとるレンズ位置Pn(AFモータパルス数)を合焦位置として取得する。   FIG. 4 is a graph for explaining AF control by the contrast detection method. In this graph, the horizontal axis is the lens position (number of AF motor pulses), and the vertical axis is the contrast evaluation value. For example, if the AF control start position is P1, the contrast evaluation value C is calculated while moving the focus lens 33b one pulse at a time in the optical axis direction, and the contrast evaluation values C1, C2 are calculated for each lens position P1, P2,. ,... Are sequentially calculated to obtain a lens position Pmax (number of AF motor pulses) at which the maximum contrast evaluation value Cmax is obtained. As shown in FIG. 5, for example, when the position P1 → P2 →... → Pn → Pn + 1, when the evaluation value Cn at the position Pn is compared with the evaluation value Cn + 1 at the position Pn + 1, When the evaluation value that has been increased decreases or takes the same value, the search unit 73 sets the lens position Pn (number of AF motor pulses) that takes the maximum evaluation value Cn (= Cmax) as the in-focus position. get.

レンズ制御部72は、サーチ部73がサーチして得たレンズ位置Pn(AFモータパルス数Pn)で規定される合焦位置までの移動方向及び移動量を求め、AFモータ44を駆動してフォーカスレンズ33bをその移動方向へその移動量だけ移動させる。そして、フォーカスレンズ33bが合焦位置に到達すると、レンズ制御部72は、AFモータ44の駆動を停止する。第1合焦制御部65は、このような手順でコントラスト検出方式によるAF制御を行う。   The lens control unit 72 obtains the moving direction and moving amount to the in-focus position defined by the lens position Pn (AF motor pulse number Pn) obtained by the search by the search unit 73, and drives the AF motor 44 to focus. The lens 33b is moved in the moving direction by the moving amount. When the focus lens 33b reaches the in-focus position, the lens control unit 72 stops driving the AF motor 44. The first focus control unit 65 performs AF control by the contrast detection method in such a procedure.

ここで、コントラスト検出方式によるAF制御では、サーチ部73が比較的広範囲に亘りサーチするので、フォーカスレンズ33bのサーチ時の移動に起因し、表示制御部67の表示制御によりモニタ20に表示される画像が小刻みにぶれるウォブリングが発生し易い。スルー画はメモリカード54に保存されないデータなので、多少ウォブリングが発生してもさほど問題ではないが、動画撮影時にサーチに起因するウォブリングが発生すると、画像がぶれた低品質の動画が保存されることになる。このため、本実施形態では、AF制御として、第1合焦制御部65が行うコントラスト検出方式の他に、フォーカスレンズ33bを移動させずにAF制御が可能な第2合焦制御部66によるフィルタ挿抜方式によるAF制御も採用している。   Here, in the AF control based on the contrast detection method, the search unit 73 searches over a relatively wide range, so that the display is displayed on the monitor 20 by the display control of the display control unit 67 due to the movement of the focus lens 33b during the search. Wobbling that causes the image to wiggle is likely to occur. Since the through image is data that is not stored in the memory card 54, there is no problem even if some wobbling occurs. However, if wobbling caused by search occurs during movie shooting, a low-quality movie with blurred images is saved. become. For this reason, in the present embodiment, as the AF control, in addition to the contrast detection method performed by the first focus control unit 65, a filter by the second focus control unit 66 that can perform AF control without moving the focus lens 33b. AF control by the insertion / extraction method is also adopted.

第2合焦制御部66によるフィルタ挿抜方式は、撮像レンズ13の光路に対してフィルタ37を挿抜することによりAF制御である。詳しくは、第2合焦制御部66は、第1合焦制御部65によるコントラスト検出方式で合焦した後、被写体が移動するなどして焦点がずれた場合、その焦点のずれた分をフィルタ37の挿抜により補償し、撮像レンズ13を透過した被写体光を撮像素子32の像面上に結像させる。   The filter insertion / extraction method by the second focus control unit 66 is AF control by inserting / extracting the filter 37 with respect to the optical path of the imaging lens 13. Specifically, the second focus control unit 66 filters the amount of defocusing when the subject is defocused, for example, when the subject moves after being focused by the contrast detection method by the first focus control unit 65. The object light transmitted through the imaging lens 13 is compensated by insertion / removal 37 and is imaged on the image plane of the imaging element 32.

フィルタ装置36を制御してフィルタ挿抜方式のAF制御を実現するために、図3に示す第2合焦制御部66は、エッジ検出部81、エッジ傾き算出部82、判定部83、感度比算出部84、フィルタ選択部85及びフィルタ制御部86を備えている。   In order to control the filter device 36 and realize the AF control of the filter insertion / extraction method, the second focus control unit 66 shown in FIG. 3 includes an edge detection unit 81, an edge inclination calculation unit 82, a determination unit 83, and a sensitivity ratio calculation. Unit 84, filter selection unit 85, and filter control unit 86.

ここで、フィルタ挿抜方式によるAF制御の原理を簡単に説明する。図6に示すように、被写体光が透過する撮像レンズ13の焦点位置が、撮像素子32よりも撮影者側(図6における右側)に位置するときに「前ボケ」、焦点位置が撮像素子32よりも撮像レンズ側(図6における左側)に位置するときに「後ボケ」になる。撮像レンズ13を透過した光は、フィルタ37で屈折するので、フィルタ37の挿抜によって、焦点位置が前後方向(光軸方向)にずれる。このため、フィルタ挿入前において図6に破線で示すように、焦点位置が前ボケ寄りにあっても、フィルタ37が挿入されると、図6に実線で示すように、被写体光を撮像素子32の像面32a上に結像させることが可能になる。但し、フィルタ37での屈折率は、光の色毎(つまり波長毎)に異なる。なお、図6では、前ボケ及び後ボケの様子を、撮像素子32を光軸方向へ位置変化させることで表現している。   Here, the principle of AF control by the filter insertion / extraction method will be briefly described. As shown in FIG. 6, when the focal position of the imaging lens 13 through which the subject light is transmitted is located on the photographer side (right side in FIG. 6) with respect to the imaging element 32, “front blur”, and the focal position is the imaging element 32. When the lens is located closer to the imaging lens (the left side in FIG. 6), it becomes “rear blur”. Since the light transmitted through the imaging lens 13 is refracted by the filter 37, the focal position is shifted in the front-rear direction (optical axis direction) by inserting and removing the filter 37. Therefore, before the filter is inserted, as shown by a broken line in FIG. 6, even if the focal position is close to the front blur, if the filter 37 is inserted, the subject light is transmitted to the image sensor 32 as shown by a solid line in FIG. It is possible to form an image on the image plane 32a. However, the refractive index of the filter 37 is different for each color of light (that is, for each wavelength). In FIG. 6, the front blur and the rear blur are expressed by changing the position of the image sensor 32 in the optical axis direction.

図7は、撮像レンズ13を透過した光の色別の軸上色収差の様子を示す。図7に示すように、撮像レンズ13を透過した光は波長の違いによる軸上色収差が発生し、焦点位置がずれる。軸上色収差は、光学系の設計値によって傾向が異なる。図7に一例で示す撮像レンズ13は、赤(R)と緑(G)の両光線の屈折率が、青(B)の光線の屈折率よりも大きく、赤(R)と緑(G)の両光線の各焦点位置が、青(B)の光線の焦点位置よりも撮像レンズ側に位置している。このため、図7に示す撮像レンズ13を備えたカメラ11では、赤(R)と緑(G)の光線の屈折率より青(B)の光線の屈折率の方が大きいフィルタ37を選定している。このように、撮像レンズ13を含む光学系の光波長特性はその光学系の設計値によって異なるので、これを考慮してRGB各色で焦点位置を一致させうる屈折率のフィルタ37を選定する。   FIG. 7 shows the state of axial chromatic aberration for each color of light transmitted through the imaging lens 13. As shown in FIG. 7, the light transmitted through the imaging lens 13 is subject to axial chromatic aberration due to the difference in wavelength, and the focal position is shifted. The tendency of axial chromatic aberration varies depending on the design value of the optical system. The imaging lens 13 shown as an example in FIG. 7 has a refractive index of both red (R) and green (G) rays larger than that of blue (B) rays, and red (R) and green (G). The focal positions of the two light beams are located closer to the imaging lens than the focal position of the blue (B) light beam. For this reason, in the camera 11 having the imaging lens 13 shown in FIG. 7, a filter 37 is selected in which the refractive index of blue (B) light is larger than that of red (R) and green (G) light. ing. As described above, the optical wavelength characteristic of the optical system including the imaging lens 13 differs depending on the design value of the optical system. Therefore, the refractive index filter 37 that can match the focal positions of the RGB colors is selected in consideration of this.

図5は、フィルタ装置36の構造を示す模式図である。図5(a)が模式側面図、図5(b)が模式正面図である。図5(a)に示すように、フィルタ装置36が備える複数枚(N枚)のフィルタ37は、それぞれ屈折率が異なる。また、各フィルタ37の屈折率は、前述のように撮像レンズ13を含む光学系の設計値に応じて異なる光波長特性も考慮し、RGB各色の焦点ずれを補償できる値に設定されている。本例では、図5に示すフィルタ装置36が備えるN枚(一例として5枚)のフィルタ37a,37b,37c,37d,37eは、補償できる焦点ずれ量がそれぞれの屈折率に応じて異なっている。   FIG. 5 is a schematic diagram showing the structure of the filter device 36. FIG. 5A is a schematic side view, and FIG. 5B is a schematic front view. As shown in FIG. 5A, the plurality of (N) filters 37 included in the filter device 36 have different refractive indexes. Further, as described above, the refractive index of each filter 37 is set to a value that can compensate for the defocus of each RGB color in consideration of the light wavelength characteristics that differ depending on the design value of the optical system including the imaging lens 13. In this example, the N (five as an example) filters 37a, 37b, 37c, 37d, and 37e included in the filter device 36 shown in FIG. 5 have different defocus amounts that can be compensated according to their refractive indexes. .

各フィルタ37はアーム91の先端部に支持されており、各アーム91の基端部はそれぞれ回転軸92に固定されている。各回転軸92はN個のフィルタ用モータ46が正逆転駆動されることにより正逆転可能に構成されている。   Each filter 37 is supported at the distal end portion of the arm 91, and the base end portion of each arm 91 is fixed to the rotation shaft 92. Each rotating shaft 92 is configured to be able to rotate forward and backward by driving N filter motors 46 to rotate forward and backward.

図5(b)に示すように、フィルタ用モータ46が正転駆動又は逆転駆動すると、フィルタ37は回転軸92を中心とする正方向又は逆方向に回動し、図5(b)に二点鎖線で示す退避位置と、同図に実線で示す挿入位置との間を移動する。このため、フィルタ37は撮像レンズ13と撮像素子32との間の光路に対して挿抜可能になっている。そして、N枚のフィルタ37a〜37eは、光軸方向に異なる位置に配置されるとともに、フィルタ1枚毎にフィルタ用モータ46が1個ずつ設けられているので、本例では、N枚のフィルタ37a〜37eのうちの任意のJ枚を重ねて同時に挿入することも可能になっている。そして、エンジン30は、挿入すべきJ枚のフィルタ37を選択して光路上に挿入すべく、N個のフィルタ用モータ46を駆動制御する。なお、フィルタ用モータ46には、薄型構造をとりうる例えば超音波モータが使用される。   As shown in FIG. 5B, when the filter motor 46 is driven forward or backward, the filter 37 rotates in the forward direction or the reverse direction about the rotation shaft 92. It moves between the retracted position indicated by the dotted line and the insertion position indicated by the solid line in the figure. For this reason, the filter 37 can be inserted into and removed from the optical path between the imaging lens 13 and the imaging element 32. The N filters 37a to 37e are arranged at different positions in the optical axis direction, and one filter motor 46 is provided for each filter. Therefore, in this example, N filters Arbitrary J of 37a to 37e can be overlapped and inserted at the same time. Then, the engine 30 drives and controls the N filter motors 46 so as to select and insert the J filters 37 to be inserted into the optical path. For example, an ultrasonic motor that can have a thin structure is used as the filter motor 46.

ここで、フォーカスレンズ33bの焦点の合焦位置からのずれ量は、フォーカスレンズ33bの光軸方向の位置に対応するAFモータパルス数Pで表すことができる。AF制御ではフォーカスレンズ33bの位置をAFモータ44のモータパルス数で制御しており、コントラスト検出方式によるAF制御は、フォーカスレンズ33bの最小移動単位を1パルスとする精度で行われる。これは、コントラスト検出方式によるAF制御により静止画撮影時のピント精度が決まるからである。   Here, the amount of deviation of the focus of the focus lens 33b from the in-focus position can be expressed by the number of AF motor pulses P corresponding to the position of the focus lens 33b in the optical axis direction. In the AF control, the position of the focus lens 33b is controlled by the number of motor pulses of the AF motor 44, and the AF control by the contrast detection method is performed with the accuracy that the minimum movement unit of the focus lens 33b is one pulse. This is because the focus accuracy at the time of still image shooting is determined by AF control using the contrast detection method.

これに対して、フィルタ挿抜方式によるAF制御は、スルー画表示中や動画撮影時においてモニタ20に表示される画像のウォブリングの低減を目的とする制御であり、主に動画撮影モードで使用され、静止画撮影モードではスルー画表示中にのみ使用される。このため、フィルタ挿抜方式によるAF制御は、一例としてAFモータパルス数換算で「2パルス」をフォーカスレンズ33bの最小移動単位とする精度で行われる。   On the other hand, the AF control by the filter insertion / extraction method is a control for the purpose of reducing wobbling of an image displayed on the monitor 20 during live view display or moving image shooting, and is mainly used in the moving image shooting mode. In still image shooting mode, it is used only during live view display. For this reason, the AF control by the filter insertion / extraction method is performed with an accuracy that uses “two pulses” in terms of the number of AF motor pulses as a minimum movement unit of the focus lens 33b.

本例の場合、図5に示すフィルタ装置36が備えるN枚のフィルタ37a〜37eは、それぞれの屈折率に応じて決まる、補償できる焦点ずれ量をAFモータパルス数で表すことができる。N枚のフィルタ37a,37b,37c,37d,37eは、この順番で屈折率が段階的に大きくなり、補償できる焦点ずれ量は、屈折率の小さいものから順番に、AFモータパルス数換算で「2パルス」、「4パルス」、「8パルス」、「16パルス」、「32パルス」に設定されている。   In the case of this example, the N filters 37a to 37e provided in the filter device 36 shown in FIG. 5 can represent a defocus amount that can be compensated, which is determined according to the refractive index, by the number of AF motor pulses. The N filters 37a, 37b, 37c, 37d, and 37e have a refractive index that increases stepwise in this order, and the amount of defocus that can be compensated is calculated in terms of the number of AF motor pulses in ascending order of refractive index. “2 pulses”, “4 pulses”, “8 pulses”, “16 pulses”, and “32 pulses” are set.

図3に示す第2合焦制御部66は、フィルタ装置36を制御するために、エッジ検出部81、エッジ傾き算出部82、判定部83、感度比算出部84、フィルタ選択部85及びフィルタ制御部86を備えている。   The second focus control unit 66 shown in FIG. 3 controls the filter device 36 by using an edge detection unit 81, an edge inclination calculation unit 82, a determination unit 83, a sensitivity ratio calculation unit 84, a filter selection unit 85, and a filter control. A portion 86 is provided.

エッジ検出部81は、主要被写体の領域でエッジを検出する。ここで、主要被写体とは、合焦させるべき被写体を指し、例えば人物が被写体である場合は、顔検出部62Aが検出した顔が主要被写体となる。図8に示す主要被写体の領域(例えば顔領域)がAF判定領域FAとなり、このAF判定領域FA内でコントラスト差の大きいエッジを検出する。このエッジの検出は、エッジ検出部81がAF判定領域FA内でRGB別もしくは輝度/色相/彩度で検索することで行う。   The edge detection unit 81 detects an edge in the area of the main subject. Here, the main subject refers to a subject to be focused. For example, when a person is a subject, the face detected by the face detection unit 62A is the main subject. A main subject area (for example, a face area) shown in FIG. 8 is an AF determination area FA, and an edge having a large contrast difference is detected in the AF determination area FA. The edge detection is performed by the edge detection unit 81 searching in the AF determination area FA for each RGB or by luminance / hue / saturation.

図8では、横方向にx座標軸、縦方向にy座標軸が与えられ、この例ではAF判定領域FA内のx=qの位置にエッジが検出される。エッジ検出部81は、エッジを横切る方向(図8ではx方向)においてRGB別の色信号値を取得する。このとき、AF判定領域FA内のある1ピクセル行だけの信号値を取得すると、その1ピクセル行がノイズを含んで誤った値が取得される虞がある。そのため、本例では、1ピクセル行の画素値をy方向にnピクセル幅に亘ってn本積算し、その積算値をnで除した平均値を、x=qに位置するエッジを横切るRGB別の色信号値として取得し、次の式(1)〜(3)により計算する。   In FIG. 8, the x coordinate axis is given in the horizontal direction and the y coordinate axis is given in the vertical direction. In this example, an edge is detected at the position of x = q in the AF determination area FA. The edge detection unit 81 acquires RGB color signal values in the direction across the edge (the x direction in FIG. 8). At this time, if a signal value of only one pixel row in the AF determination area FA is acquired, there is a possibility that the one pixel row includes noise and an incorrect value is acquired. Therefore, in this example, n pixel values in one pixel row are integrated over the width of n pixels in the y direction, and an average value obtained by dividing the integrated value by n is determined for each RGB crossing the edge located at x = q. Is obtained as the color signal value of and calculated by the following equations (1) to (3).

Figure 0005581838
ここで、r(x,k)、g(x,k)、b(x,k)は、y方向のnピクセル幅におけるn本(k=1,2,…,n)の1ピクセル行のR信号値、G信号値、B信号値をそれぞれ示す。但し、xは、図8の例ではx=qを含む所定範囲Q(例えばAF判定領域FAの一部の範囲(一例としてq−Q/2≦x≦q+Q/2))を変域とする1行幅分の値をとる。y方向のnピクセル幅内の各1ピクセル行を指すy座標をy=y1,y2,…,yn(但し、y1<y2<…<yn)とすると、r(x,k)、g(x,k)、b(x,k)は、y座標がy=y1+1−kの1ピクセル行のR信号値、G信号値、B信号値をそれぞれ示す。
Figure 0005581838
Here, r (x, k), g (x, k), and b (x, k) are n (k = 1, 2,..., N) one pixel row in the n pixel width in the y direction. R signal value, G signal value, and B signal value are shown, respectively. However, in the example of FIG. 8, x is a predetermined range Q including x = q (for example, a partial range of the AF determination area FA (for example, q−Q / 2 ≦ x ≦ q + Q / 2)). Takes the value for one line width. .., yn (where y1 <y2 <... <yn), where r (x, k), g (x , K) and b (x, k) respectively indicate an R signal value, a G signal value, and a B signal value of one pixel row whose y coordinate is y = y1 + 1−k.

さらにエッジ検出部81は、r_ave(x)、g_ave(x)、b_ave(x)を、エッジの最大値と最小値に正規化する。エッジ検出部81は、RGBのエッジ(x=q)における正規化出力R(x),G(x),B(x)を、次の式(4)〜(6)により算出する。   Further, the edge detection unit 81 normalizes r_ave (x), g_ave (x), and b_ave (x) to the maximum value and the minimum value of the edge. The edge detection unit 81 calculates normalized outputs R (x), G (x), and B (x) at the RGB edge (x = q) by the following equations (4) to (6).

Figure 0005581838
ここで、xminは、エッジ検出対象範囲EA内で信号値が最小(例えば図8の黒領域)となるx座標値を示し、xmaxは、エッジ検出対象範囲EA内で信号値が最大(例えば図8の白領域)となるx座標値を示す。
Figure 0005581838
Here, xmin indicates an x-coordinate value at which the signal value is minimum (for example, the black region in FIG. 8) within the edge detection target range EA, and xmax is the maximum (for example, FIG. 8) within the edge detection target range EA. (8 white area)).

図9は、正規化出力R(x),G(x),B(x)を示すグラフである。このグラフにおいて横軸がx座標軸(エッジを横切る方向の座標軸)、縦軸が正規化出力を示す。図9に示す例では、正規化出力R(x),G(x),B(x)の各ラインはほぼ重なっている。図9は、例えばコントラスト検出方式AF制御による合焦時点における正規化出力R(x),G(x),B(x)を示す。この合焦後、例えば被写体の移動などによってフォーカスレンズ33bの現在位置が合焦位置からずれる場合がある。フォーカスレンズ33bの現在位置が合焦位置に近いほど、正規化出力R(x),G(x),B(x)の各ラインの傾きは急峻となり、傾きは「1」に近い値をとる。フォーカスレンズ33bの現在位置が合焦位置から徐々にずれるに従って、正規化出力R(x),G(x),B(x)のエッジ(x=q)における傾きは徐々に小さくなる。このため、傾きがある閾値以上の値をとれば、焦点のずれ量が比較的小さい所定範囲(第2AF制御範囲W2)内であることが分かる。   FIG. 9 is a graph showing normalized outputs R (x), G (x), and B (x). In this graph, the horizontal axis indicates the x coordinate axis (the coordinate axis in the direction crossing the edge), and the vertical axis indicates the normalized output. In the example shown in FIG. 9, the lines of the normalized outputs R (x), G (x), and B (x) are almost overlapped. FIG. 9 shows normalized outputs R (x), G (x), and B (x) at the time of focusing by, for example, contrast detection AF control. After the in-focus state, the current position of the focus lens 33b may deviate from the in-focus position due to, for example, movement of the subject. The closer the current position of the focus lens 33b is to the in-focus position, the steeper the slope of each line of the normalized outputs R (x), G (x), B (x), and the slope takes a value close to “1”. . As the current position of the focus lens 33b gradually shifts from the in-focus position, the gradients at the edges (x = q) of the normalized outputs R (x), G (x), and B (x) gradually decrease. For this reason, if the inclination is a value equal to or greater than a certain threshold value, it can be seen that the amount of defocus is within a predetermined range (second AF control range W2).

エッジ傾き算出部82は、エッジ検出部81が検出したエッジの傾きを検出する。ここで、エッジの傾きとは、エッジを横切る方向(図8の例ではx方向)における画素値(RGB信号値)の変化率を指す。エッジにおけるRGB各信号値の各傾きKR,KG,KBは、正規化出力R(x),G(x),B(x)の微分式にx=qを代入して算出する。本例では、エッジ傾き算出部82は、KR=|R(x+Δp)−R(x)|、KG=|G(x+Δp)−G(x)|、KB=|B(x+Δp)−B(x)|を用いて、エッジの位置を示すx=qを代入して計算する。但し、Δpは所定の微小値である。   The edge inclination calculation unit 82 detects the edge inclination detected by the edge detection unit 81. Here, the slope of the edge refers to the rate of change of the pixel value (RGB signal value) in the direction crossing the edge (x direction in the example of FIG. 8). The slopes KR, KG, KB of the RGB signal values at the edge are calculated by substituting x = q into the differential expression of the normalized outputs R (x), G (x), B (x). In this example, the edge inclination calculation unit 82 has KR = | R (x + Δp) −R (x) |, KG = | G (x + Δp) −G (x) |, KB = | B (x + Δp) −B (x ) | Is used to calculate by substituting x = q indicating the position of the edge. However, Δp is a predetermined minute value.

図10は、エッジの傾きKをAFモータパルス数に対してプロットしたグラフを示す。横軸がAFモータパルス数(レンズ位置)を示し、縦軸が傾きKを示す。図10の例では、エッジにおけるRGB信号値の傾きKR,KG,KBの各ラインはほぼ重なっている。   FIG. 10 shows a graph in which the slope K of the edge is plotted against the number of AF motor pulses. The horizontal axis indicates the number of AF motor pulses (lens position), and the vertical axis indicates the inclination K. In the example of FIG. 10, each line of the gradients KR, KG, and KB of the RGB signal values at the edge substantially overlaps.

図10の例では、合焦位置(AFモータパルス数=約170)で傾きKが最大となり、合焦位置からフォーカスレンズ33bの位置がずれるに従って傾きKは徐々に小さくなる。本実施形態では、コントラスト検出方式の第1AF制御で合焦した後、その合焦時のフォーカスレンズ33bの位置(AFレンズ位置)が、被写体の移動などによって光軸方向に移動するその時々の焦点位置からのずれ量が所定範囲内にある第2AF制御範囲W2にあるうちはフィルタ挿抜方式の第2AF制御を継続する。そして、AFレンズ位置が第2AF制御範囲W2から外れ、第1AF制御範囲内に入ると、コントラスト検出方式の第1AF制御へ移行する。   In the example of FIG. 10, the inclination K becomes maximum at the in-focus position (number of AF motor pulses = about 170), and the inclination K gradually decreases as the position of the focus lens 33b deviates from the in-focus position. In this embodiment, after focusing by the first AF control of the contrast detection method, the position of the focus lens 33b (AF lens position) at the time of focusing moves in the optical axis direction due to the movement of the subject or the like. While the amount of deviation from the position is in the second AF control range W2 within the predetermined range, the second AF control of the filter insertion / extraction method is continued. When the AF lens position deviates from the second AF control range W2 and enters the first AF control range, the control shifts to the first AF control of the contrast detection method.

判定部83は、最初のコントラスト検出方式による合焦後、AFレンズ位置が、第2AF制御範囲内にあるか、第1AF制御範囲内にあるかを判定する。詳しくは、判定部83は、エッジ傾き算出部82が所定周期毎に算出する傾きKが閾値Koより大きければAFレンズ位置が第2AF制御範囲W2にあると判定し、一方、傾きKが閾値Ko以下になると、AFレンズ位置が第1AF制御範囲W1にあると判定する。本例では、図9の例における微分特性により、RGBのうち2色(R,G)の閾値Koを予め設定し、判定部83が、この2色の傾きKR,KGが閾値Koより大きいか否かを判定するようにしている。図10の例では、閾値Koは一例として約0.85に設定されている。   The determination unit 83 determines whether the AF lens position is within the second AF control range or the first AF control range after focusing by the first contrast detection method. Specifically, the determination unit 83 determines that the AF lens position is in the second AF control range W2 if the inclination K calculated by the edge inclination calculation unit 82 every predetermined period is larger than the threshold value Ko, while the inclination K is the threshold value Ko. When it is below, it is determined that the AF lens position is in the first AF control range W1. In this example, the threshold value Ko for two colors (R, G) of RGB is set in advance by the differential characteristics in the example of FIG. 9, and the determination unit 83 determines whether the slopes KR, KG of these two colors are larger than the threshold value Ko. It is determined whether or not. In the example of FIG. 10, the threshold value Ko is set to about 0.85 as an example.

感度比算出部84は、感度比R/G,B/G,R/Bを算出する。ここで、感度比R/G,B/G,R/Bとは、エッジにおけるRGB各信号値の正規化出力R(x),G(x),B(x)のうちの2色毎の比である。このため、感度比算出部84は、式 R/G=R(q)/G(q)、B/G=B(q)/G(q)、R/B=R(q)/B(q)により、各感度比R/G,B/G,R/Bを算出する。   The sensitivity ratio calculation unit 84 calculates sensitivity ratios R / G, B / G, and R / B. Here, the sensitivity ratios R / G, B / G, and R / B are the normalized outputs R (x), G (x), and B (x) of each RGB signal value at the edge. Is the ratio. Therefore, the sensitivity ratio calculation unit 84 uses the formulas R / G = R (q) / G (q), B / G = B (q) / G (q), R / B = R (q) / B ( Each sensitivity ratio R / G, B / G, R / B is calculated by q).

図11は、フォーカスレンズ33bを光軸方向に移動させつつその移動過程で得られた感度比R/G,B/G,R/Bをプロットしたものである。横軸はAFモータパルス数(AFレンズ位置)、縦軸は感度比をそれぞれ示す。感度比R/G,B/G,R/Bは、撮像レンズ13を含む光学系の設計値に依存し、またズーム量(ズームレンズ33aの光軸方向の位置)によって傾向が異なる。図11に示すズーム量の例では、AF制御が適正になされている場合、フォーカスレンズ33bは合焦位置にあり、感度比R/G,B/G,R/Bは「ほぼ1」になる。ここから被写体が撮影側(カメラ側)に向かってくる場合、感度比R/G,B/G,R/Bは位置Aのときの値に変化する。一方、フォーカスレンズ33bが合焦位置にある状態から、被写体が撮影側(カメラ側)から遠ざかる場合、感度比R/G,B/G,R/Bは位置Bのときの値に変化する。   FIG. 11 is a plot of sensitivity ratios R / G, B / G, and R / B obtained in the process of moving the focus lens 33b in the optical axis direction. The horizontal axis represents the number of AF motor pulses (AF lens position), and the vertical axis represents the sensitivity ratio. The sensitivity ratios R / G, B / G, and R / B depend on the design value of the optical system including the imaging lens 13, and the tendency varies depending on the zoom amount (the position of the zoom lens 33a in the optical axis direction). In the example of the zoom amount shown in FIG. 11, when the AF control is appropriately performed, the focus lens 33b is in the in-focus position, and the sensitivity ratios R / G, B / G, and R / B are “almost 1”. . When the subject comes from here toward the photographing side (camera side), the sensitivity ratios R / G, B / G, and R / B change to the values at the position A. On the other hand, when the subject moves away from the photographing side (camera side) from the state where the focus lens 33b is at the in-focus position, the sensitivity ratios R / G, B / G, and R / B change to the values at the position B.

図11に示すように、感度比B/Gは、A−B間の範囲においてAFモータパルス数が大きくなるほど一様に増加し、一方、感度比R/Bは、A−B間の範囲においてAFモータパルス数が大きくなるほど一様に減少している。これに対して感度比R/Gは、A−B間の範囲において、値の変動が小さくかつ増減している。A−B間の範囲において感度比の変化がほぼ一様なB/GとR/Bとを用いることで、感度比B/G,R/Bから合焦位置からのずれ量が分かる。   As shown in FIG. 11, the sensitivity ratio B / G increases uniformly as the number of AF motor pulses increases in the range between A and B, while the sensitivity ratio R / B increases in the range between A and B. As the number of AF motor pulses increases, it decreases uniformly. On the other hand, the sensitivity ratio R / G has a small variation and increases or decreases in the range between A and B. By using B / G and R / B in which the change in the sensitivity ratio is substantially uniform in the range between A and B, the shift amount from the in-focus position can be determined from the sensitivity ratios B / G and R / B.

感度比算出部84は、コントラスト検出方式によるAF制御(第1AF制御)によりフォーカスレンズ33bが合焦位置に配置された合焦時に、感度比Ro/Go,Bo/Go,Ro/Boを算出する。この合焦後、感度比算出部84は、所定時間(例えば10マイクロ秒〜100ミリ秒の範囲内の所定値)周期で感度比R/G,B/G,R/Bを算出する。そして、感度比算出部84は、所定時間周期毎に、合焦時の感度比Ro/Go,Bo/Go,Ro/Boと現在の感度比R/G,B/G,R/Bとの差分ΔR/G,ΔB/G,ΔR/Bをそれぞれ計算する。   The sensitivity ratio calculation unit 84 calculates the sensitivity ratios Ro / Go, Bo / Go, Ro / Bo at the time of focusing when the focus lens 33b is disposed at the in-focus position by AF control (first AF control) using a contrast detection method. . After this in-focus, the sensitivity ratio calculation unit 84 calculates the sensitivity ratios R / G, B / G, R / B at a predetermined time (for example, a predetermined value within a range of 10 microseconds to 100 milliseconds). Then, the sensitivity ratio calculation unit 84 calculates the sensitivity ratio Ro / Go, Bo / Go, Ro / Bo at the time of focusing and the current sensitivity ratios R / G, B / G, R / B for each predetermined time period. Differences ΔR / G, ΔB / G, and ΔR / B are calculated.

差分ΔR/G,ΔB/G,ΔR/Bが分かれば、図11のA−B間の範囲における感度比R/G,B/G,R/Bの関係から、第1AF制御による合焦時点の合焦位置から現在合焦させるべきAFレンズ位置までの距離がAFモータパルス数換算で求めることができる。そして、予め図11に示すようなAFモータパルス数と感度比R/G,B/G,R/Bとの関係を示すデータを、ズーム量毎に測定し、差分ΔR/G,ΔB/G,ΔR/Bと合焦位置からのずれ量ΔPとの関係を示すマップデータを作成する。このように全ズーム範囲を複数分割(m分割)し、そのm分割したズーム量毎のm個のマップデータM1〜Mmを不揮発性メモリ49に格納している。   If the differences ΔR / G, ΔB / G, and ΔR / B are known, the focus point by the first AF control is determined from the relationship between the sensitivity ratios R / G, B / G, and R / B in the range between A and B in FIG. The distance from the in-focus position to the AF lens position to be focused at present can be calculated in terms of the number of AF motor pulses. Then, data indicating the relationship between the number of AF motor pulses and the sensitivity ratios R / G, B / G, R / B as shown in FIG. 11 is measured for each zoom amount, and the differences ΔR / G, ΔB / G are measured. , ΔR / B and map data showing the relationship between the in-focus position deviation amount ΔP. In this way, the entire zoom range is divided into a plurality of divisions (m divisions), and m pieces of map data M1 to Mm for each of the m divisional zoom amounts are stored in the nonvolatile memory 49.

なお、A−B間の範囲ではフィルタ挿抜方式によるAF制御が可能であり、このA−B間の範囲に合わせて閾値Koを設定している。このため、傾きKが閾値Koより大きければ、そのときの感度比R/G,B/G,R/BはA−B間の範囲内にあることになる。   In the range between A and B, AF control by a filter insertion / extraction method is possible, and the threshold value Ko is set in accordance with the range between A and B. Therefore, if the slope K is larger than the threshold value Ko, the sensitivity ratios R / G, B / G, and R / B at that time are within the range between A and B.

フィルタ選択部85は、感度比算出部84が算出した差分ΔR/G,ΔB/G,ΔR/Bを基に、そのときのズーム量に応じて不揮発性メモリ49から読み出したマップデータMを参照して、差分ΔR/G,ΔB/G,ΔR/Bに応じた焦点ずれ量ΔPを求める。そして、フィルタ選択部85は、求めた焦点ずれ量ΔPから挿入すべきフィルタ37を選択する。コントラスト検出方式の第1AF制御時は、「32パルス」分補償可能なフィルタ37eを挿入して行われる。このため、フィルタ選択部85は、初期挿入(デフォルト)分の「32パルス」に、焦点ずれ量ΔPの補償に必要なパルス数(=「−ΔP」)を加算して補償パルス数ΔPt(=32−ΔP)を求め、この補償パルス数ΔPt分相当のフィルタ37を選択する。本実施形態では、N枚(5枚)のフィルタ37a〜37eは、それぞれ補償パルス数が、2,4,8,16,32パルスなので、N枚(5枚)のフィルタ37a〜37eを組み合わせて必要に応じて重ねて挿入することにより、0〜62パルスの範囲内で2パルス毎の精度でAF制御を行うことが可能である。   Based on the differences ΔR / G, ΔB / G, ΔR / B calculated by the sensitivity ratio calculation unit 84, the filter selection unit 85 refers to the map data M read from the nonvolatile memory 49 according to the zoom amount at that time. Then, a defocus amount ΔP corresponding to the differences ΔR / G, ΔB / G, ΔR / B is obtained. Then, the filter selection unit 85 selects the filter 37 to be inserted from the obtained defocus amount ΔP. The first AF control of the contrast detection method is performed by inserting a filter 37e that can compensate for “32 pulses”. For this reason, the filter selection unit 85 adds the number of pulses (= “− ΔP”) necessary for compensation of the defocus amount ΔP to “32 pulses” for the initial insertion (default) and adds the number of compensation pulses ΔPt (= 32−ΔP), and the filter 37 corresponding to the number of compensation pulses ΔPt is selected. In this embodiment, the N (5) filters 37a to 37e have 2, 4, 8, 16, and 32 compensation pulses, respectively. Therefore, N (5) filters 37a to 37e are combined. By superimposing and inserting as necessary, it is possible to perform AF control with an accuracy of every two pulses within a range of 0 to 62 pulses.

フィルタ制御部86は、フィルタ選択部85が選択したフィルタ37に対応するフィルタ用モータ46をフィルタ駆動回路38を介して駆動制御し、選択したフィルタ37を、撮像レンズ13と撮像素子32との間の光路上に挿入する。このとき、それまで挿入されていたフィルタ37を抜く駆動と、新たにフィルタ37を挿入する駆動とを同時に行う。但し、新たなフィルタ37が挿入される前にそれまで挿入されていたフィルタ37が抜かれると、一瞬ピントがずれるので、複数枚の入れ換えがあるときは、一瞬の入れ換え過程でもその中で段階的に入れ換える制御を採用することが望ましい。例えばまず補償パルス数の一番小さなフィルタ37の挿入と、それまで挿入されていたフィルタのうち補償パルス数の一番小さなフィルタ37の抜出とを同時に行う。次に補償パルス数の2番目に小さなフィルタ37の挿入と、それまで挿入されていたフィルタのうち補償パルス数の2番目に小さなフィルタの抜出とを同時に行う。そして、以降、この手順を同様に行ってフィルタ37の入れ換えを段階的に行ってもよい。このとき、挿入と抜出とで各フィルタ37の補償パルス数が大きく異なる場合は、入れ換え過程で補償パルス数の大きな変化を回避できるように入れ換えるべきフィルタ37を段階毎に選択して入れ換えを行うとよい。   The filter control unit 86 controls driving of the filter motor 46 corresponding to the filter 37 selected by the filter selection unit 85 via the filter driving circuit 38, and the selected filter 37 is interposed between the imaging lens 13 and the imaging element 32. Insert it into the optical path. At this time, the drive for removing the filter 37 inserted so far and the drive for newly inserting the filter 37 are simultaneously performed. However, if the filter 37 that has been inserted is removed before the new filter 37 is inserted, the focus is shifted for a moment. Therefore, when there are a plurality of replacements, a step-by-step process is performed even during the replacement process. It is desirable to adopt control that replaces For example, the filter 37 having the smallest number of compensation pulses is first inserted and the filter 37 having the smallest number of compensation pulses among the filters that have been inserted is simultaneously performed. Next, the insertion of the filter 37 with the second smallest number of compensation pulses and the extraction of the filter with the second smallest number of compensation pulses among the filters that have been inserted are performed simultaneously. Thereafter, this procedure may be performed in the same manner to replace the filter 37 stepwise. At this time, if the number of compensation pulses of each filter 37 is greatly different between insertion and extraction, the filter 37 to be replaced is selected at each stage so as to avoid a large change in the number of compensation pulses in the replacement process. Good.

表示制御部67は、モニタ制御回路51を介してモニタ20に、スルー画、撮影中の動画、撮影直後の静止画、再生時の静止画及び再生中の動画や、メニュー画面等を表示させる表示制御を行う。   The display control unit 67 displays on the monitor 20 via the monitor control circuit 51 a through image, a moving image being shot, a still image immediately after shooting, a still image at the time of reproduction, a moving image being reproduced, a menu screen, and the like. Take control.

次にカメラ11におけるAF制御について説明する。電源スイッチ17が操作されてカメラ11が電源ONされると、エンジン30内のコンピュータ31が図14にフローチャートで示すAF制御処理用のプログラムを実行する。   Next, AF control in the camera 11 will be described. When the power switch 17 is operated and the camera 11 is turned on, the computer 31 in the engine 30 executes an AF control processing program shown in the flowchart of FIG.

以下、カメラ11におけるAF制御を、図14に示すフローチャートに従って、図12及び図13を適宜用いて説明する。ここで、カメラ11の電源ON時は撮影モードにあり、モニタ20にはスルー画が表示される。そして、動画撮影モードにおいて、レリーズスイッチ18が操作されると、動画撮影が開始される。また、このスルー画表示中や動画撮影中にユーザーによりズームボタン22が操作されると、エンジン30内のコンピュータ31は、ズーム駆動回路42を介してズーム用モータ43を駆動し、ズームレンズ33aを光軸方向に沿って移動させ、ズームボタン22の操作に応じたズーム量に調整する。このスルー画表示中と動画撮影中においては、コンピュータ31が図14に示すAF制御を実行する。   Hereinafter, the AF control in the camera 11 will be described according to the flowchart shown in FIG. 14 and using FIGS. 12 and 13 as appropriate. Here, when the camera 11 is turned on, the camera 11 is in the shooting mode, and a through image is displayed on the monitor 20. When the release switch 18 is operated in the moving image shooting mode, moving image shooting is started. When the zoom button 22 is operated by the user during the live view display or the moving image shooting, the computer 31 in the engine 30 drives the zoom motor 43 via the zoom drive circuit 42 to move the zoom lens 33a. It is moved along the optical axis direction and adjusted to a zoom amount corresponding to the operation of the zoom button 22. During the through image display and the moving image shooting, the computer 31 executes the AF control shown in FIG.

まずステップS10では、コンピュータ31は、不揮発性メモリ49から現在のズーム量(初期ズーム量)に応じたマップを読み出す。
次のステップS20では、コンピュータ31は、コントラスト検出方式によるAF制御を(第1AF制御)行う。この第1AF制御は、詳しくはコンピュータ31の第1合焦制御部65が行う。この第1AF制御開始に際して、「32パルス」分のフィルタ37eを最初に挿入し、このフィルタ挿入状態で第1AF制御は行われる。レンズ制御部72がAFモータ44を駆動させてフォーカスレンズ33bを光軸方向に沿って移動させつつ、コントラスト検出部71が主要被写体のコントラストを逐次検出してそのコントラスト評価値Cを算出し、その評価値Cが増加する方向へフォーカスレンズ33bを移動させる。そして、サーチ部73が、図4に示す「山登り制御」を行って最大のコントラスト評価値Cmaxとなるレンズ位置Pmax(AFモータパルス数)をサーチし、レンズ制御部72がフォーカスレンズ33bをそのサーチしたレンズ位置Pmax(合焦位置)まで移動させる。こうして主要被写体光が撮像素子32の像面32aに結像するように、フォーカスレンズ33bが合焦位置に配置される。
First, in step S <b> 10, the computer 31 reads a map corresponding to the current zoom amount (initial zoom amount) from the nonvolatile memory 49.
In the next step S20, the computer 31 performs AF control by the contrast detection method (first AF control). Specifically, the first AF control is performed by the first focus control unit 65 of the computer 31. When starting the first AF control, the filter 37e for “32 pulses” is inserted first, and the first AF control is performed in this filter insertion state. While the lens control unit 72 drives the AF motor 44 to move the focus lens 33b along the optical axis direction, the contrast detection unit 71 sequentially detects the contrast of the main subject and calculates its contrast evaluation value C. The focus lens 33b is moved in the direction in which the evaluation value C increases. Then, the search unit 73 performs “mountain climbing control” shown in FIG. 4 to search for the lens position Pmax (number of AF motor pulses) at which the maximum contrast evaluation value Cmax is reached, and the lens control unit 72 searches the focus lens 33b for the lens position Pmax. The lens is moved to the lens position Pmax (focus position). In this way, the focus lens 33b is disposed at the in-focus position so that the main subject light is focused on the image plane 32a of the image sensor 32.

次のステップS30では、コンピュータ31は、主要被写体のエッジのRGB検出を行う。このRGB検出は、詳しくはコンピュータ31のエッジ検出部81が行う。エッジ検出部81は、コントラスト検出方式によるAF制御で合焦した後(S20)、その合焦時点における主要被写体のAF判定領域FAにおけるエッジ(図8参照)を検出し、さらに検出したエッジにおける正規化出力R(x),G(x),B(x)を算出する(図9参照)。   In the next step S30, the computer 31 performs RGB detection of the edge of the main subject. Specifically, the RGB detection is performed by the edge detection unit 81 of the computer 31. After focusing by AF control using the contrast detection method (S20), the edge detection unit 81 detects the edge (see FIG. 8) in the AF determination area FA of the main subject at the time of focusing, and further detects the regularity at the detected edge. The calculated outputs R (x), G (x), and B (x) are calculated (see FIG. 9).

次のステップS40では、コンピュータ31は、ズーム量が所定量以上変化したか否かを判断する。つまり、マップデータMの変更が必要なほどズーム量が変化したか否かを判断する。マップデータMの変更が必要なほどズーム量が変化した場合はステップS50に進み、マップデータMの変更が必要なほどはズーム量が変化しなかった場合は、ステップS60に進む。   In the next step S40, the computer 31 determines whether or not the zoom amount has changed by a predetermined amount or more. That is, it is determined whether or not the zoom amount has changed so that the map data M needs to be changed. If the zoom amount has changed enough to change the map data M, the process proceeds to step S50. If the zoom amount has not changed so much that the map data M needs to be changed, the process proceeds to step S60.

ステップS50では、コンピュータ31は、ズーム量に応じたマップデータMを読み出し、使用するマップデータMを変更する。なお、この例では、例えば図11に示す感度比特性データに基づくマップデータMが読み出されているものとする。   In step S50, the computer 31 reads map data M corresponding to the zoom amount, and changes the map data M to be used. In this example, it is assumed that map data M based on, for example, sensitivity ratio characteristic data shown in FIG. 11 has been read.

ステップS60では、コンピュータ31は、コントラスト検出方式AF制御による合焦時点の主要被写体のエッジにおける感度比Ro/Go,Bo/Go,Ro/Boを算出する。
次のステップS70では、コンピュータ31は、電源OFFであるか否かを判断する。すなわち、このAF制御ルーチンの終了条件を満たすか否かを判断する。電源OFFであれば当該ルーチンを終了し、電源OFFでなければ(つまり電源ONであれば)ステップS80に進む。但し、通常、ユーザーは撮影を終えるまでは電源OFFすることはない。
In step S60, the computer 31 calculates the sensitivity ratios Ro / Go, Bo / Go, Ro / Bo at the edge of the main subject at the time of focusing by contrast detection AF control.
In the next step S70, the computer 31 determines whether or not the power is off. That is, it is determined whether or not the end condition of this AF control routine is satisfied. If the power is off, the routine ends. If the power is not off (that is, if the power is on), the process proceeds to step S80. However, normally, the user does not turn off the power until shooting is completed.

ステップS80では、コンピュータ31は、主要被写体のエッジの傾きKR,KGを算出する。この傾きKR,KGの算出は、詳しくはコンピュータ31のエッジ傾き算出部82が行う。エッジ傾き算出部82は、エッジ(x=q)におけるR信号値の傾きKR,KGを、式 KR=|R(x+Δp)−R(x)|、KG=|G(x+Δp)−G(x)|に、エッジの位置を示すx=qを代入して計算する。   In step S80, the computer 31 calculates the inclinations KR and KG of the edge of the main subject. The slopes KR and KG are calculated in detail by the edge slope calculation unit 82 of the computer 31. The edge inclination calculation unit 82 uses the expressions KR = | R (x + Δp) −R (x) | and KG = | G (x + Δp) −G (x) to calculate the inclinations KR and KG of the R signal value at the edge (x = q). ) | Is substituted by x = q indicating the position of the edge.

次のステップS90では、コンピュータ31は傾きKR,KGが閾値Koより大きいか否かを判定する。この判定は、詳しくはコンピュータ31の判定部83が行う。判定部83は、傾きKR,KGが閾値Koより大きいと判定した場合はステップS100に進み、傾きKR,KGが閾値Koより大きくない(つまり傾きKR,KGが閾値Ko以下である)と判定した場合はステップS120に進む。   In the next step S90, the computer 31 determines whether or not the slopes KR and KG are larger than the threshold value Ko. This determination is performed in detail by the determination unit 83 of the computer 31. If it is determined that the slopes KR and KG are greater than the threshold value Ko, the determination unit 83 proceeds to step S100, and determines that the slopes KR and KG are not greater than the threshold value Ko (that is, the slopes KR and KG are less than or equal to the threshold value Ko). If so, the process proceeds to step S120.

ステップS100では、コンピュータ31は、主要被写体のエッジにおける感度比R/G,B/G,R/Bを算出し、この現在の感度比R/G,B/G,R/Bと合焦時点の感度比Ro/Go,Bo/Go,Ro/Boとの差分ΔR/G,ΔB/G,ΔR/Bを算出する(ΔR/G=R/G−Ro/Go、ΔB/G=B/G−Bo/Go、ΔR/B=R/B−Ro/Bo)。この感度比及び感度比の差分の算出は、詳しくはコンピュータ31の感度比算出部84が行う。   In step S100, the computer 31 calculates the sensitivity ratios R / G, B / G, and R / B at the edge of the main subject, and the current sensitivity ratios R / G, B / G, and R / B are in focus. ΔR / G, ΔB / G, ΔR / B from the sensitivity ratios Ro / Go, Bo / Go, and Ro / Bo are calculated (ΔR / G = R / G−Ro / Go, ΔB / G = B / G-Bo / Go, [Delta] R / B = R / B-Ro / Bo). The sensitivity ratio and the difference between the sensitivity ratios are calculated in detail by the sensitivity ratio calculator 84 of the computer 31.

次のステップS110では、コンピュータ31は、差分ΔR/G,ΔB/G,ΔR/Bに適したフィルタ37を挿入する。この処理は、詳しくはコンピュータ31のフィルタ選択部85とフィルタ制御部86とが行う。例えば撮像レンズ13の光学系特性及び現在のズーム量において、感度比が図11に示すように変動する場合、A−B間の範囲で、R/Gは1つの値から2つのAFモータパルス数が決まる場合があるので、差分ΔR/Gをフィルタ選択に使用するのは不適切である。このため、図11の例では、まずフィルタ選択部85は、1つの感度比から必ず1つのAFモータパルス数が決まる差分ΔB/G,ΔR/Bを基に、挿入すべきフィルタ37を選択する。   In the next step S110, the computer 31 inserts a filter 37 suitable for the differences ΔR / G, ΔB / G, ΔR / B. This process is specifically performed by the filter selection unit 85 and the filter control unit 86 of the computer 31. For example, when the sensitivity ratio fluctuates as shown in FIG. 11 in the optical system characteristics of the imaging lens 13 and the current zoom amount, R / G ranges from one value to two AF motor pulses within the range between A and B. Therefore, it is inappropriate to use the difference ΔR / G for filter selection. Therefore, in the example of FIG. 11, first, the filter selection unit 85 selects the filter 37 to be inserted based on the differences ΔB / G and ΔR / B in which one AF motor pulse number is always determined from one sensitivity ratio. .

例えば図11において、合焦位置における感度比Bo/Go,Ro/Boが「約1」であり、現在のフォーカスレンズ33bの位置が図11におけるA位置にあるとすると、現在の感度比B/G,R/Bはそれぞれ「0.88」と「1.13」なので、差分ΔB/G=−0.12、差分ΔR/B=0.13と算出される。そして、フィルタ選択部85は、差分ΔB/G=−0.12を基にマップデータMを参照することで焦点ずれ量ΔP=「−20パルス」を取得し、またΔR/B=0.13を基にマップデータMを参照することで焦点ずれ量ΔP=「−20パルス」を取得する。そして、フィルタ選択部85は、焦点ずれ量ΔP=−20パルスを補償しうる分のフィルタ37を選択する。   For example, in FIG. 11, if the sensitivity ratios Bo / Go and Ro / Bo at the in-focus position are “about 1” and the current position of the focus lens 33b is at the A position in FIG. 11, the current sensitivity ratio B / Since G and R / B are “0.88” and “1.13”, respectively, the difference ΔB / G = −0.12 and the difference ΔR / B = 0.13 are calculated. The filter selection unit 85 obtains the defocus amount ΔP = “− 20 pulses” by referring to the map data M based on the difference ΔB / G = −0.12, and ΔR / B = 0.13. By referring to the map data M based on the above, the defocus amount ΔP = “− 20 pulses” is acquired. The filter selection unit 85 selects the filter 37 that can compensate for the defocus amount ΔP = −20 pulses.

本例では、「32パルス」分のフィルタ37eを最初に挿入した状態で、コントラスト検出方式によるAF制御(第1AF制御)を行っている。このため、フィルタ選択部85は、初期挿入(デフォルト)分の「32パルス」に、焦点ずれ量ΔPの補償に必要なパルス数(=「−ΔP」)を加算して、補償パルス数ΔPt(=32−ΔP)を求め、この補償パルス数ΔPt分相当のフィルタ37を選択する。この例では、補償パルス数ΔPt=52パルスなので、「52パルス」分のフィルタ37を挿入すればよいことになる。そのため、フィルタ選択部85は、「16パルス」補償可能なフィルタ37dと、「4パルス」補償可能なフィルタ37bとを、合焦時の「32パルス」のフィルタ37eに加えた、合計3枚のフィルタ37b,37d,37eを選択する。   In this example, AF control (first AF control) by the contrast detection method is performed with the filter 37e for “32 pulses” inserted first. For this reason, the filter selection unit 85 adds the number of pulses (= “− ΔP”) necessary for compensation of the defocus amount ΔP to “32 pulses” for initial insertion (default) to obtain the number of compensation pulses ΔPt ( = 32−ΔP), and the filter 37 corresponding to the number of compensation pulses ΔPt is selected. In this example, since the number of compensation pulses ΔPt = 52 pulses, it is only necessary to insert filters 37 for “52 pulses”. Therefore, the filter selection unit 85 adds a filter 37d capable of compensating for "16 pulses" and a filter 37b capable of compensating for "4 pulses" to the filter 32e of "32 pulses" at the time of focusing, for a total of three sheets. Filters 37b, 37d, and 37e are selected.

そして、フィルタ制御部86は、選択された3枚のフィルタ37b,37d,37eのうち現在既に挿入されているフィルタ37e以外の2枚のフィルタ37b,37dに対応する2個のフィルタ用モータ46を駆動して、2枚のフィルタ37b,37dをさらに挿入する。この結果、3枚のフィルタ37b,37d,37eが挿入され、主要被写体は撮像素子32の像面32a上に結像するようになる。   Then, the filter control unit 86 includes two filter motors 46 corresponding to the two filters 37b and 37d other than the filter 37e that is already inserted among the three selected filters 37b, 37d, and 37e. The two filters 37b and 37d are further inserted by driving. As a result, the three filters 37b, 37d, and 37e are inserted, and the main subject is focused on the image plane 32a of the image sensor 32.

また、現在のフォーカスレンズ33bの位置が図11におけるB位置にあったとすると、このとき、現在の感度比B/G,R/Bはそれぞれ「1.10」と「0.93」なので、差分ΔB/G=0.10,差分ΔR/B=−0.07として算出される。そして、これらの差分ΔB/G,ΔR/Bのときの焦点ずれ量ΔPは共に「+18パルス」と算出される。フィルタ選択部85は、補償パルス数ΔPt=32−ΔP=32−18=14パルスと算出するので、「14パルス」分のフィルタ37を挿入すればよいことになる。そのため、フィルタ選択部85は、「2パルス」、「4パルス」、「8パルス」を補償可能な3枚のフィルタ37a,37b,37cを選択する。そして、フィルタ制御部86は、4つのフィルタ用モータ46を駆動して、選択された3枚のフィルタ37a,37b,37cを、現在既に挿入されているフィルタ37eに入れ換えて挿入する。この結果、主要被写体は撮像素子32の像面32a上に結像するようになる。   If the current position of the focus lens 33b is at position B in FIG. 11, the current sensitivity ratios B / G and R / B are “1.10” and “0.93”, respectively. Calculated as ΔB / G = 0.10 and the difference ΔR / B = −0.07. The defocus amount ΔP when these differences ΔB / G, ΔR / B are both calculated as “+18 pulses”. Since the filter selection unit 85 calculates the number of compensation pulses ΔPt = 32−ΔP = 32−18 = 14 pulses, it is only necessary to insert “14 pulses” of filters 37. Therefore, the filter selection unit 85 selects the three filters 37a, 37b, and 37c that can compensate for “2 pulses”, “4 pulses”, and “8 pulses”. Then, the filter control unit 86 drives the four filter motors 46, and inserts the selected three filters 37a, 37b, and 37c in place of the filter 37e that has already been inserted. As a result, the main subject is imaged on the image plane 32 a of the image sensor 32.

上記ではA位置とB位置という第2AF制御範囲の境界位置という極端な例を説明したが、実際は焦点が合焦位置に対して少しずれる度にフィルタ37の挿抜が行われる。このため、第2AF制御範囲においては、逐次実行されるフィルタ挿抜方式による第2AF制御により、常にほぼ合焦状態に保たれる。この結果、動画撮影時におけるコントラスト検出方式AF制御時のサーチに起因する画像のウォブリングを回避できる。よって、ウォブリングの発生頻度の少ない高品質な動画画像を撮影及び保存することができる。   In the above description, an extreme example of the boundary position of the second AF control range, that is, the A position and the B position has been described. However, in practice, the filter 37 is inserted / removed each time the focus is slightly shifted from the in-focus position. For this reason, in the second AF control range, the in-focus state is always maintained substantially by the second AF control by the filter insertion / removal method executed sequentially. As a result, it is possible to avoid image wobbling caused by a search during contrast detection AF control during moving image shooting. Therefore, it is possible to shoot and store a high-quality moving image with a low frequency of wobbling.

一方、ステップS90で傾きKR,KGが閾値Ko以下と判定した場合は、ステップS120において、コンピュータ31は、フィルタ37が初期状態であるか否かを判断する。詳しくは、コンピュータ31の切換制御部64が、初期挿入されるべきフィルタ37eが挿入され、かつその他のフィルタ37a〜37dが挿入されていない初期状態にあるか否かを判断する。フィルタ37が初期状態になければステップS130に進み、フィルタ37が初期状態にあればステップS140に進む。   On the other hand, when it is determined in step S90 that the slopes KR and KG are equal to or smaller than the threshold value Ko, in step S120, the computer 31 determines whether or not the filter 37 is in an initial state. Specifically, the switching control unit 64 of the computer 31 determines whether or not the filter 37e to be initially inserted is inserted and the other filters 37a to 37d are not inserted. If the filter 37 is not in the initial state, the process proceeds to step S130, and if the filter 37 is in the initial state, the process proceeds to step S140.

ステップS130では、コンピュータ31はフィルタ37を初期状態にする。詳しくは、コンピュータ31のフィルタ制御部86がフィルタ用モータ46を駆動して、初期挿入されるべきフィルタ37eのみ挿入され、その他のフィルタ37a〜37dが抜かれた初期状態にする。   In step S130, the computer 31 sets the filter 37 to an initial state. Specifically, the filter control unit 86 of the computer 31 drives the filter motor 46 so that only the filter 37e to be initially inserted is inserted and the other filters 37a to 37d are removed.

そして、ステップS140では、コンピュータ31は、コントラスト検出方式によるAF制御(第1AF制御)を実行する。この第1AF制御は、詳しくはコンピュータ31の第1合焦制御部65が実行する。第1AF制御が終了して合焦すると、フィルタ挿抜方式の第2AF制御に移行すべくステップS40に戻り、S40〜S60の処理を行った後、S70〜S110の処理を繰り返すことで、所定時間周期毎にフィルタ挿抜方式の第2AF制御を行う。そして、第2AF制御中に傾きKR,KGが閾値Ko以下になると(S90で否定判定)、切換制御部64が、フィルタ37を必要に応じて初期状態とした後(S130)、コントラスト検出方式の第1AF制御(S140)に切り換える。   In step S140, the computer 31 executes AF control (first AF control) using a contrast detection method. Specifically, the first AF control is executed by the first focusing control unit 65 of the computer 31. When the first AF control is finished and focused, the process returns to step S40 to shift to the second AF control of the filter insertion / removal method, and after performing the processes of S40 to S60, the processes of S70 to S110 are repeated to obtain a predetermined time period. The second AF control of the filter insertion / extraction method is performed every time. If the slopes KR and KG become equal to or smaller than the threshold value Ko during the second AF control (No in S90), the switching control unit 64 sets the filter 37 to an initial state as necessary (S130), and then the contrast detection method. Switch to the first AF control (S140).

以上詳述したようにこの第1実施形態によれば、以下の効果が得られる。
(1)コントラスト検出方式によるAF制御による合焦後に、フィルタ挿抜方式のAF制御を行うので、コントラスト検出方式によるAF制御時のサーチ動作に起因するウォブリングの発生頻度を低減し、ウォブリングに起因する画像のぶれを低減することができる。
As described above in detail, according to the first embodiment, the following effects can be obtained.
(1) Since AF control using the filter insertion / extraction method is performed after focusing by AF control using the contrast detection method, the occurrence frequency of wobbling caused by the search operation during AF control using the contrast detection method is reduced, and an image caused by wobbling is reduced. The blur can be reduced.

(2)フィルタ37を複数枚(N枚)備え、第2合焦制御部66は、複数のフィルタ37を重ね合わせて光路上に配置することにより複数のフィルタの組合せによって異なる屈折率を作り出す。よって、少ない枚数のフィルタ37で細かくAF制御を行うことができる。   (2) A plurality of (N) filters 37 are provided, and the second focusing control unit 66 creates a different refractive index depending on the combination of the plurality of filters by overlapping the plurality of filters 37 and arranging them on the optical path. Therefore, the AF control can be finely performed with a small number of filters 37.

(3)特に、N枚のフィルタ37を、補償可能なパルス数を、2、4、8、16、32パルスとした。つまり、N枚のフィルタ37を、最小移動単位のパルス数をDとした場合に、D、2D、4D、8D,…,2^(N−1)・Dパルス分を補償可能なそれぞれ屈折率の異なるフィルタとした。このため、第2AF制御の精度の割に、フィルタ37の枚数を少なく済ませることができる。よって、第2AF制御の精度の割に、フィルタ装置36の小型化(薄型化)が可能であり、カメラ11をコンパクトに構成することができる。   (3) In particular, the number of pulses that can be compensated for the N filters 37 is 2, 4, 8, 16, and 32 pulses. That is, when the number of pulses in the minimum movement unit is D, the N filters 37 have respective refractive indexes that can compensate for D, 2D, 4D, 8D,..., 2 ^ (N−1) · D pulses. Different filters. For this reason, the number of filters 37 can be reduced for the accuracy of the second AF control. Therefore, the filter device 36 can be downsized (thinned) for the accuracy of the second AF control, and the camera 11 can be configured compactly.

(4)ズーム量毎にマップデータを用意したので、ズーム量に応じた適切な第2AF制御を実現できる。
(5)エッジにおける色信号値の傾きKを求め、傾きKと閾値Koとの比較によって、第1AF制御と第2AF制御とを切り換えるので、第1AF制御と第2AF制御との間で適切な切り換えを行うことができる。
(4) Since map data is prepared for each zoom amount, appropriate second AF control according to the zoom amount can be realized.
(5) Since the slope K of the color signal value at the edge is obtained and the first AF control and the second AF control are switched by comparing the slope K with the threshold value Ko, appropriate switching between the first AF control and the second AF control is performed. It can be performed.

(6)感度比R/G,B/G,R/Bを用いて、第1AF制御による合焦時点の感度比Ro/Go,Bo/Go,Ro/Boとの差分ΔR/G,ΔB/G,ΔR/Bを基に、挿入すべきフィルタ37を選択するので、第2AF制御を適切に行うことができる。   (6) Using the sensitivity ratios R / G, B / G, and R / B, differences ΔR / G and ΔB / from the sensitivity ratios Ro / Go, Bo / Go, and Ro / Bo at the time of focusing by the first AF control. Since the filter 37 to be inserted is selected based on G and ΔR / B, the second AF control can be performed appropriately.

前記実施形態は上記に限定されず、以下の態様に変更することもできる。
・図15に示すように、フィルタ37を光軸方向に移動させるスライダ94及びリニアモータ95を更に設け、フィルタ37を光路に対してフィルタ用モータ46の駆動により挿抜可能かつリニアモータ95の駆動により光軸方向に移動可能な構成も採用できる。この場合、フィルタ37を挿入し、かつ挿入したフィルタ37を光軸方向に移動させることにより第2AF制御を行う。この構成によれば、フィルタ37の光軸方向の移動によってもAF制御を行えるので、フィルタ37の枚数を少なくすることができるうえ、前記実施形態のような断続的な第2AF制御に替えて、連続的な第2AF制御が可能になる。なお、図15の例では、屈折率の異なる複数枚(2枚)のフィルタ37を設けたが、フィルタ37は1枚でもよいし、3枚以上の複数枚でもよい。
The said embodiment is not limited above, It can also change into the following aspects.
As shown in FIG. 15, a slider 94 and a linear motor 95 for moving the filter 37 in the optical axis direction are further provided. The filter 37 can be inserted into and removed from the optical path by driving the filter motor 46 and driven by the linear motor 95. A configuration capable of moving in the optical axis direction can also be employed. In this case, the second AF control is performed by inserting the filter 37 and moving the inserted filter 37 in the optical axis direction. According to this configuration, since the AF control can be performed also by the movement of the filter 37 in the optical axis direction, the number of the filters 37 can be reduced, and instead of the intermittent second AF control as in the above embodiment, Continuous second AF control becomes possible. In the example of FIG. 15, a plurality of (two) filters 37 having different refractive indexes are provided, but the number of the filters 37 may be one, or may be three or more.

・図11のグラフにおけるA位置とB位置とに相当する焦点ずれ量ΔPa又はΔPaになったか否かを判定し、焦点ずれ量ΔPとΔPa又はΔPaとの比較結果に基づいて、第1AF制御と第2AF制御との間で切り換えを行う構成としてもよい。   It is determined whether or not the defocus amount ΔPa or ΔPa corresponding to the A position and the B position in the graph of FIG. 11 is reached, and the first AF control is performed based on the comparison result between the defocus amount ΔP and ΔPa or ΔPa. It is good also as a structure which switches between 2nd AF control.

・前記実施形態において、フィルタを重ね合わせて挿入する構成に替えて、複数枚のフィルタ37のうち選択された1枚のみを挿入する構成でもよい。
・前記実施形態において、フィルタは透明でもスモークなどの色付きでもよい。
In the above-described embodiment, a configuration in which only one selected from the plurality of filters 37 is inserted instead of the configuration in which the filters are overlaid and inserted.
In the above embodiment, the filter may be transparent or colored such as smoke.

・前記実施形態において、フィルタを1枚のみ備えたフィルタ装置とした構成も採用してよい。
・電子カメラは、デジタルカメラに限定されず、ビデオカメラの他、カメラ機能を備えたPDA(Personal Digital Assistant)や携帯電話、携帯用ゲーム機などでもよい。
-In the said embodiment, you may also employ | adopt the structure used as the filter apparatus provided with only one filter.
The electronic camera is not limited to a digital camera, but may be a video camera, a PDA (Personal Digital Assistant) having a camera function, a mobile phone, a portable game machine, or the like.

11…電子カメラとしてのカメラ、13…撮像レンズ、17…電源スイッチ、18…レリーズスイッチ、20…モニタ、21…モード選択スイッチ、22…ズームボタン、24…撮影ボタン、30…エンジン、31…コンピュータ、32…撮像手段を構成する撮像素子、33a…ズームレンズ、33b…撮影レンズとしてのフォーカスレンズ、34…絞り、35…シャッタ、36…フィルタ装置、37,37a〜37e…フィルタ、38…第2駆動手段を構成するフィルタ駆動回路、39…第1駆動手段を構成するフォーカス駆動回路、40…シャッタ駆動回路、41…絞り駆動回路、42…第3駆動手段を構成するズーム駆動回路、43…第3駆動手段を構成するズーム用モータ、44…第1駆動手段を構成するフォーカス用モータ(AFモータ)、45…AFセンサ、46…第2駆動手段を構成するフィルタ用モータ、47…撮像制御回路、48…映像回路、49…不揮発性メモリ、51…モニタ制御回路、52…メモリ制御回路、53…操作検出回路、54…メモリカード、61…主制御部、62…画像処理部、62A…顔検出部、63…ズーム制御部、64…切換制御部、65…第1の合焦制御手段としての第1合焦制御部、66…第2合焦制御部、67…表示制御部、71…コントラスト検出部、69…レンズ制御部、73…サーチ部、81…検出手段を構成するエッジ検出部、82…傾き算出手段としてのエッジ傾き算出部、83…判定部、84…検出手段を構成するとともに感度比算出手段としての感度比算出部、85…第2の合焦制御手段を構成するフィルタ選択部、86…第2の合焦制御手段を構成するフィルタ制御部、R/G,B/G,R/B…感度比、ΔR/G,ΔB/G,ΔR/B…差分、ΔP…ずれ量としての焦点ずれ量、ΔPt…補償パルス数。 DESCRIPTION OF SYMBOLS 11 ... Camera as an electronic camera, 13 ... Imaging lens, 17 ... Power switch, 18 ... Release switch, 20 ... Monitor, 21 ... Mode selection switch, 22 ... Zoom button, 24 ... Shooting button, 30 ... Engine, 31 ... Computer 32 ... an image sensor constituting an imaging means, 33a ... a zoom lens, 33b ... a focus lens as a photographic lens, 34 ... aperture, 35 ... shutter, 36 ... filter device, 37, 37a to 37e ... filter, 38 ... second. Filter driving circuit constituting driving means 39. Focus driving circuit constituting first driving means 40. Shutter driving circuit 41. Diaphragm driving circuit 42. Zoom driving circuit constituting third driving means 43. Zoom motor constituting three drive means, 44... Focus motor constituting first drive means (AF 45 ... AF sensor, 46 ... filter motor constituting second drive means, 47 ... imaging control circuit, 48 ... video circuit, 49 ... nonvolatile memory, 51 ... monitor control circuit, 52 ... memory control circuit 53 ... Operation detection circuit 54 ... Memory card 61 ... Main control unit 62 ... Image processing unit 62A ... Face detection unit 63 ... Zoom control unit 64 ... Switch control unit 65 ... First focus control First focusing control unit as means 66 66 Second focusing control unit 67 Display control unit 71 Contrast detection unit 69 Lens control unit 73 Search unit 81 Edges constituting detection unit Detecting unit, 82... Edge tilt calculating unit as tilt calculating unit, 83... Determining unit, 84... Detecting unit and sensitivity ratio calculating unit as sensitivity ratio calculating unit, 85. Filter selection 86: Filter control unit constituting second focusing control means, R / G, B / G, R / B: Sensitivity ratio, ΔR / G, ΔB / G, ΔR / B: Difference, ΔP: Deviation amount Defocus amount, ΔPt: number of compensation pulses.

Claims (8)

撮影レンズを光軸方向に移動させる第1駆動手段と、
撮像手段が取得した画像のコントラスト値に基づいて、前記撮影レンズを合焦位置に配置するよう前記第1駆動手段を制御する第1の合焦制御手段と、
前記撮影レンズと前記撮像手段との間の光路に対して挿抜可能に設けられるとともに前記撮影レンズの合焦位置からのずれ量を補償可能な屈折率を有する少なくとも一つのフィルタと、
前記フィルタを前記光路に対して挿抜させる第2駆動手段と
前記撮影レンズの合焦位置に対するずれ量を検出する検出手段と、
前記検出手段が検出したずれ量に応じた屈折率のフィルタを前記光路に対して挿抜するよう前記第2駆動手段を制御して合焦を行う第2の合焦制御手段と、
を備えたことを特徴とする自動合焦制御装置。
First driving means for moving the photographic lens in the optical axis direction;
First focusing control means for controlling the first driving means so as to arrange the photographing lens at a focusing position based on a contrast value of an image acquired by the imaging means;
At least one filter having a refractive index provided so as to be able to be inserted into and removed from an optical path between the photographing lens and the imaging unit and capable of compensating for a deviation amount from the in-focus position of the photographing lens;
A second driving means for inserting and removing the filter with respect to the optical path; and a detecting means for detecting a shift amount with respect to a focusing position of the photographing lens;
Second focus control means for controlling the second drive means to focus so that a filter having a refractive index corresponding to the amount of deviation detected by the detection means is inserted into and removed from the optical path;
An automatic focusing control device characterized by comprising:
前記フィルタを複数備え、
前記第2の合焦制御手段は、複数のフィルタを重ね合わせて光路上に配置することにより複数のフィルタの組合せによって異なる屈折率を作り出すことを特徴とする請求項1に記載の自動合焦制御装置。
A plurality of the filters;
2. The automatic focusing control according to claim 1, wherein the second focusing control unit creates a different refractive index depending on a combination of the plurality of filters by superimposing a plurality of filters on the optical path. apparatus.
前記第2の合焦制御手段は、前記光路上における前記フィルタの挿抜と、前記光路上に挿入された該フィルタの光軸方向における移動とにより合焦を行うことを特徴とする請求項1又は2に記載の自動合焦制御装置。   The second focusing control means performs focusing by inserting / removing the filter on the optical path and moving the filter inserted on the optical path in the optical axis direction. 2. The automatic focusing control device according to 2. ズームレンズと、
前記ズームレンズを光軸方向に移動させて焦点距離を変化させることでズーム量を調整する第3駆動手段と、
前記第2の合焦制御手段は、前記ズーム量及び前記ずれ量に応じて前記光路上に挿入すべきフィルタを選択することを特徴とする請求項2に記載の自動合焦制御装置。
A zoom lens,
Third driving means for adjusting the zoom amount by moving the zoom lens in the optical axis direction and changing the focal length;
The automatic focusing control apparatus according to claim 2, wherein the second focusing control unit selects a filter to be inserted on the optical path in accordance with the zoom amount and the shift amount.
前記検出手段は、前記撮像手段が取得した画像のRGB3色の信号値のうち2色毎の組合せの値の比で示される3つの感度比のうち少なくとも1つを算出する感度比算出手段を備え、前記少なくとも1つの感度比に基づいて前記合焦位置からの前記ずれ量を求めることを特徴とする請求項1乃至4のうちいずれか一項に記載の自動合焦制御装置。   The detection means includes sensitivity ratio calculation means for calculating at least one of three sensitivity ratios indicated by a ratio of combinations of two colors among the RGB three color signal values of the image acquired by the imaging means. 5. The automatic focusing control device according to claim 1, wherein the shift amount from the in-focus position is obtained based on the at least one sensitivity ratio. 前記撮像手段で取得されたRGB信号値の前記画像中のエッジ部分を横切るときの傾きを求める傾き算出手段を備え、
前記傾きが閾値以上のときに前記第2の合焦制御手段による第2の合焦制御を行い、前記傾きが前記閾値未満になると、前記第2の合焦制御から前記第1の合焦制御手段による第1の合焦制御へ切り替えることを特徴とする請求項1乃至5のうちいずれか一項に記載の自動合焦制御装置。
Inclination calculation means for obtaining an inclination when the RGB signal value acquired by the imaging means crosses an edge portion in the image,
When the tilt is equal to or greater than a threshold value, second focus control is performed by the second focus control unit. When the tilt is less than the threshold value, the second focus control is changed to the first focus control. The automatic focusing control device according to claim 1, wherein the first focusing control is switched to first focusing control by means.
被写体を撮影する撮像手段と、
請求項1乃至6のうちいずれか一項に記載の自動合焦制御装置と、
を備えたことを特徴とする電子カメラ。
Imaging means for photographing a subject;
An automatic focusing control device according to any one of claims 1 to 6,
An electronic camera characterized by comprising:
撮影レンズを光軸方向に移動させながら撮像手段が取得した画像のコントラスト値に基づいて、前記撮影レンズを合焦位置に配置するよう合焦制御を行う第1の合焦制御ステップと、
前記第1の合焦制御ステップによる合焦が行われた前記撮影レンズの合焦位置に対するずれ量を検出する検出ステップと、
前記ずれ量を補償可能な屈折率を有するフィルタが前記撮影レンズの光路上に配置されるように前記光路に対してフィルタの挿抜を行うことで合焦する第2の合焦制御ステップと、
を備えたことを特徴とする自動合焦制御方法。
A first focusing control step for performing focusing control so that the photographing lens is arranged at a focusing position based on a contrast value of an image acquired by the imaging unit while moving the photographing lens in the optical axis direction;
A detecting step for detecting a shift amount of the photographing lens that has been focused by the first focusing control step with respect to a focusing position;
A second focusing control step of focusing by inserting and removing the filter with respect to the optical path so that a filter having a refractive index capable of compensating the shift amount is disposed on the optical path of the photographing lens;
An automatic focusing control method comprising:
JP2010139435A 2010-06-18 2010-06-18 Automatic focusing control device, electronic camera and automatic focusing control method Expired - Fee Related JP5581838B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010139435A JP5581838B2 (en) 2010-06-18 2010-06-18 Automatic focusing control device, electronic camera and automatic focusing control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010139435A JP5581838B2 (en) 2010-06-18 2010-06-18 Automatic focusing control device, electronic camera and automatic focusing control method

Publications (2)

Publication Number Publication Date
JP2012003128A JP2012003128A (en) 2012-01-05
JP5581838B2 true JP5581838B2 (en) 2014-09-03

Family

ID=45535149

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010139435A Expired - Fee Related JP5581838B2 (en) 2010-06-18 2010-06-18 Automatic focusing control device, electronic camera and automatic focusing control method

Country Status (1)

Country Link
JP (1) JP5581838B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5889010B2 (en) * 2012-01-31 2016-03-22 キヤノン株式会社 Imaging apparatus and control method thereof
CN104981734B (en) * 2013-01-30 2018-01-05 佳能电子株式会社 Light quantity adjustment apparatus and optical device
CN115484416B (en) * 2021-06-15 2023-10-31 中移(成都)信息通信科技有限公司 Protection device for camera device and early warning system

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6254435A (en) * 1985-09-03 1987-03-10 Nippon Kogaku Kk <Nikon> Projection optical device
JPH01126946A (en) * 1987-11-12 1989-05-19 Olympus Optical Co Ltd Television camera for endoscope
JP2974338B2 (en) * 1989-09-10 1999-11-10 キヤノン株式会社 Automatic focusing device
JPH03204277A (en) * 1990-01-05 1991-09-05 Canon Inc Focus detection method
JPH11218673A (en) * 1998-01-30 1999-08-10 Olympus Optical Co Ltd Camera system
JP4269386B2 (en) * 1999-01-27 2009-05-27 株式会社ニコン Imaging optical system
JP3950707B2 (en) * 2002-02-22 2007-08-01 キヤノン株式会社 Optical equipment
JP2004085936A (en) * 2002-08-27 2004-03-18 Olympus Corp Camera
JP2004101421A (en) * 2002-09-11 2004-04-02 Nidec Copal Corp Optical range finder
JP4777177B2 (en) * 2005-07-28 2011-09-21 京セラ株式会社 Imaging apparatus and imaging method
JP2009103800A (en) * 2007-10-22 2009-05-14 Sony Corp Automatic focusing device and method, and program

Also Published As

Publication number Publication date
JP2012003128A (en) 2012-01-05

Similar Documents

Publication Publication Date Title
US8890993B2 (en) Imaging device and AF control method
JP4982997B2 (en) Image processing device
JP3823921B2 (en) Imaging device
JP2013013050A (en) Imaging apparatus and display method using imaging apparatus
JP2009036986A (en) Photographing device and control method for photographing device
JP4509081B2 (en) Digital camera and digital camera program
JP4760302B2 (en) Imaging device
JP4645413B2 (en) Imaging device
JP2008116844A (en) Imaging apparatus
JP2006091915A (en) Imaging apparatus
JP5203657B2 (en) Camera with enlarged display function
JP2007142702A (en) Image processing apparatus
JP2009069170A (en) Photographing device and control method of photographing device
JP5883564B2 (en) Imaging device
JP2007133301A (en) Autofocus camera
JP5581838B2 (en) Automatic focusing control device, electronic camera and automatic focusing control method
JP2009036985A (en) Photographing device and control method for photographing device
JP4941141B2 (en) Imaging device
JP4693709B2 (en) Image processing apparatus and image processing method
JP2005345833A (en) Imaging device and its focusing control method
JP2009053296A (en) Imaging device and control method for same
JP2007124278A (en) Imaging apparatus
JP4977996B2 (en) Imaging device
JP5403087B2 (en) Image processing device
JP2009036987A (en) Photographing device and control method for photographing device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20130606

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20140326

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140630

R150 Certificate of patent or registration of utility model

Ref document number: 5581838

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees