JP2009021893A - Imaging device and method - Google Patents

Imaging device and method Download PDF

Info

Publication number
JP2009021893A
JP2009021893A JP2007183950A JP2007183950A JP2009021893A JP 2009021893 A JP2009021893 A JP 2009021893A JP 2007183950 A JP2007183950 A JP 2007183950A JP 2007183950 A JP2007183950 A JP 2007183950A JP 2009021893 A JP2009021893 A JP 2009021893A
Authority
JP
Japan
Prior art keywords
distance
image
evaluation value
face
focusing
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.)
Withdrawn
Application number
JP2007183950A
Other languages
Japanese (ja)
Inventor
Kanichi Furuyama
貫一 古山
Hideto Fujita
日出人 藤田
Yukio Mori
幸夫 森
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.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric Co Ltd
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 Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP2007183950A priority Critical patent/JP2009021893A/en
Publication of JP2009021893A publication Critical patent/JP2009021893A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To prevent erroneous operation in the case where a photograph including a particular item is selected as an imaging object in the imaging device in which the focus is placed on a particular object by detecting the particular object. <P>SOLUTION: In an image obtained with an imaging device for detecting a face of person as the particular object and setting the focus on the particular object by moving the focus distance corresponding to a size of the face, detecting regions are set to the upper and lower portions and right and left portions of the face of detected person. Characteristics such as profiles of changes when focus distance of an evaluation value used for focusing is changed are compared with that in the region including the particular object and the detecting regions. When the characteristics are not similar to that in the regions including the particular object in the predetermined number of detecting regions, for example, two or more detecting regions, an actual person is judged as an object locating in front of the background. When the characteristics are similar to that in the region including the particular object under two detecting regions, a photograph or a picture locating in front of the person is judged as an imaging object. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は自動的に焦点合わせが可能な撮像装置及び撮影方法に関するもので、特に対象とする被写体が特定の部位を有する場合に、その被写体に正確に焦点合わせが可能な撮像装置に関する。   The present invention relates to an imaging apparatus and an imaging method capable of automatically focusing, and more particularly to an imaging apparatus capable of accurately focusing on a subject when the target subject has a specific part.

現在、デジタルカメラやデジタルビデオカメラのようなデジタル方式の撮像装置が広く普及している。このような撮像装置では、レンズの焦点は自動制御で合わせるオートフォーカス(AF;auto focus)が一般的である。   Currently, digital imaging devices such as digital cameras and digital video cameras are widely used. In such an image pickup apparatus, the focus of the lens is generally an autofocus (AF) that is automatically controlled.

焦点合わせの制御方法としては、最近点から無限遠又はその逆の方向に合焦距離を変化させながら画像内の輝度信号の高周波成分に基づくAF評価値を検出し、そのAF評価値が極大値を取る位置に焦点を合わせることによって行う方法がある。   As a focusing control method, an AF evaluation value based on a high-frequency component of a luminance signal in an image is detected while changing a focusing distance from the nearest point to infinity or vice versa, and the AF evaluation value is a maximum value. There is a way to do it by focusing on the position to take.

図14に示すような、背景の前に実際の人物が配置されたような構図の画像を撮像する場合、AF評価値とレンズの合焦距離との関係は図15のグラフのようになる。図15のグラフは、横軸が合焦距離(レンズ位置)、縦軸がAF評価値であり、横軸は左端を無限遠、右端を最近接距離としている。図15のグラフでは、2箇所に極大値が現れている。無限遠側の極大値は背景の山、最近接側の極大値は手前の人物のものであり、この場合は撮像装置に近い方の極大値を選択する。   When capturing an image having a composition in which an actual person is placed in front of the background as shown in FIG. 14, the relationship between the AF evaluation value and the focal distance of the lens is as shown in the graph of FIG. In the graph of FIG. 15, the horizontal axis is the in-focus distance (lens position), the vertical axis is the AF evaluation value, and the horizontal axis is the left end at infinity and the right end is the closest distance. In the graph of FIG. 15, maximum values appear at two locations. The local maximum on the infinity side is that of the background mountain, and the local maximum on the nearest side is that of the person in front. In this case, the local maximum closest to the imaging device is selected.

AF機能を有する撮像装置では、使用者が撮影したいときにすぐ焦点のあった画像を撮像できるように、焦点合わせに必要な時間を短縮し、又、合焦の精度を向上させることが必要である。そのため、特許文献1では、上述のような焦点合わせの制御方法を有するデジタルカメラにおいて、画像内の人物の顔を検出し、画像中でのその顔の大きさにに基づいて人物までのおよその距離を算出して、その距離から最近接方向へ合焦位置を移動させて合焦制御を開始する方法が開示されている。例えば図14の画像から検出した人物の顔の大きさに基づいて人物までの距離をデジタルカメラから1.6m付近と推測し、AF評価値の検出に際して、その距離(図15中に示す「開始位置」)から合焦距離を変化させる。この方法によると、無限遠から合焦距離を変化させる場合と比べて人物に焦点を合わせるのに必要な時間を短くすることができる。
特開2006−201282号公報
In an imaging device having an AF function, it is necessary to reduce the time required for focusing and improve the focusing accuracy so that the user can take a focused image immediately when he / she wants to take a picture. is there. Therefore, in Patent Document 1, in a digital camera having the focusing control method as described above, the face of a person in an image is detected, and the approximate distance to the person is determined based on the size of the face in the image. A method is disclosed in which the distance is calculated, the focus position is moved in the closest direction from the distance, and focus control is started. For example, the distance to the person is estimated to be around 1.6 m from the digital camera based on the size of the person's face detected from the image of FIG. 14, and when detecting the AF evaluation value, the distance (“Start” shown in FIG. The focus distance is changed from the position “)”. According to this method, the time required to focus on the person can be shortened compared to the case where the focus distance is changed from infinity.
JP 2006-201282 A

しかし、特許文献1に開示されたデジタルカメラでは、人物の顔を検出する際に、実際の人物であるか、テレビの画面や写真、絵画等の画面の中の人物であるかを区別しない。そのため、被写体として人物を含む写真が近くにあり、その人物が小さい場合には、人物が遠方にあるものと誤って推測していまい、逆に焦点合わせに必要な時間が長くなってしまうこととなる。   However, the digital camera disclosed in Patent Document 1 does not distinguish whether a person's face is an actual person or a person on a screen of a television screen, a photograph, or a picture. Therefore, if there is a photograph that includes a person nearby as a subject and the person is small, it may be mistakenly assumed that the person is far away, and conversely, the time required for focusing will become longer. Become.

例えば図16に示すような、壁面上に掛けられた人物を含む写真を被写体とする場合、AF評価値と合焦距離との関係は図17のグラフのようになる。縦軸、横軸については図15と同様である。図17のグラフでは、被写体である写真に相当する位置のみの1箇所に極大値が現れている。特許文献1のデジタルカメラでは、画像内でのこの写真に含まれる人物の顔の大きさに基づいて人物までのおよその距離を算出すると、実際の写真までの距離(例えば1.6m)よりもはるかに遠い位置(例えば20m、図17の「開始位置」)に、誤って推測してしまう。   For example, when a photograph including a person hung on the wall as shown in FIG. 16 is used as a subject, the relationship between the AF evaluation value and the in-focus distance is as shown in the graph of FIG. The vertical and horizontal axes are the same as in FIG. In the graph of FIG. 17, the maximum value appears only in one position corresponding to the photograph as the subject. In the digital camera disclosed in Patent Document 1, when the approximate distance to a person is calculated based on the size of the face of the person included in the photograph in the image, the distance to the actual photograph (for example, 1.6 m) is greater. A far-inferred position (for example, 20 m, “start position” in FIG. 17) is erroneously estimated.

そこで、本発明は、画面上にある特定部分を有する被写体を撮影しようしているのか否かを判定できる撮像装置を提供することを目的とする。   Therefore, an object of the present invention is to provide an imaging apparatus that can determine whether or not a subject having a specific portion on a screen is being photographed.

上記目的を達成するために、本発明の撮像装置は、合焦距離が変化可能であるレンズ部と、前記レンズ部を通じて被写体が含まれる撮像画像を取得する撮像部と、前記撮像画像から焦点合わせの評価値を算出する評価値算出部と、を備え、前記レンズ部において変化可能な範囲の合焦距離で取得した前記撮像画像の前記評価値が極大値となる位置に前記レンズ部の合焦位置を設定する撮像装置において、前記撮像画像中から前記被写体の特定部分を検出する特定部分検出部を備え、前記特定部分検出部で検出された前記特定部分の周囲に複数の検知領域を設定し、前記被写体の特定部分を検出したとき、前記特定部分検出部における評価値の特性と、前記検知領域における評価値の特性とを比較し、前記特定部分の特性と類似した前記検知領域の数が所定の数以下である、前記特定部分の大きさに対応した合焦距離に前記レンズ部を移動させてから合焦距離の設定動作を継続することを特徴とする。評価値の特性としては、評価値の値や合焦距離の変化に伴う評価値の変化の方向(符号)を用いることができる。   In order to achieve the above object, an imaging apparatus according to the present invention includes a lens unit that can change a focusing distance, an imaging unit that acquires a captured image including a subject through the lens unit, and focusing from the captured image. An evaluation value calculation unit that calculates the evaluation value of the lens unit, and the focus of the lens unit is at a position where the evaluation value of the captured image acquired at a focus distance within a variable range in the lens unit is a maximum value. An imaging apparatus for setting a position includes a specific part detection unit that detects a specific part of the subject from the captured image, and sets a plurality of detection regions around the specific part detected by the specific part detection unit. When the specific part of the subject is detected, the characteristic of the evaluation value in the specific part detection unit is compared with the characteristic of the evaluation value in the detection region, and the detection region similar to the characteristic of the specific part is compared. The number of is smaller than the predetermined number, characterized by continuing the setting operation of the focal length from by moving the lens unit in focusing distance corresponding to the size of the particular portion. As a characteristic of the evaluation value, a direction (sign) of a change in the evaluation value accompanying a change in the evaluation value or the focus distance can be used.

又、前記特定部分の大きさから算出した合焦距離に前記レンズ部を合わせた後、前記特定部分における前記評価値に基づいて前記合焦距離の設定動作を継続するものとしても構わない。   In addition, after the lens unit is adjusted to the in-focus distance calculated from the size of the specific portion, the in-focus distance setting operation may be continued based on the evaluation value in the specific portion.

又、前記撮像画像を複数の分割領域に分割する領域分割部を備え、前記検知領域が、前期分割領域からなるとともに前記特定部分を含む前記分割領域と同じ形状であり、前記特定部分の上下左右の4箇所に設定されているものとしても構わない。   In addition, the image processing apparatus includes an area dividing unit that divides the captured image into a plurality of divided areas, wherein the detection area includes the previous divided area and has the same shape as the divided area including the specific part, However, it may be set at four locations.

又、前記特定部分が、人物の顔であるものとしても構わない。   The specific portion may be a human face.

又、前記合焦距離の設定動作において、前記レンズ部の合焦距離を変化させる方向が、無限遠側から最近接距離側に向けてであるものとしても構わない。   In the focusing distance setting operation, the direction in which the focusing distance of the lens unit is changed may be from the infinity side toward the closest distance side.

又、本発明の階調補正方法は、所定の合焦距離で前記レンズ部を通じて被写体が含まれる撮像画像を取得する第1のステップと、前記撮像画像から焦点合わせの評価値を算出する第2のステップと、前記撮像画像から被写体の特定部分を検出する第3のステップと、前記特定部分の前記評価値の特性と、前記特定部分の周囲に設定した複数の検知領域の前記評価値の特性とを比較する第4のステップと、前記第4のステップで比較した前記評価値の特性が、前記特定部分と類似した前記検知領域の個数を算出する第5のステップと、前記第5のステップで算出した、前記評価値の特性が前記特定部分と類似した前記検知領域の個数が所定の数以下である場合に、前記第3のステップで検出した前記特定部分の大きさに対応した合焦距離に前記レンズ部を合わせる第6のステップと、を備えることを特徴とする。   In the gradation correction method of the present invention, a first step of acquiring a captured image including a subject through the lens unit at a predetermined focusing distance, and a second step of calculating a focus evaluation value from the captured image. A third step of detecting a specific part of the subject from the captured image, characteristics of the evaluation value of the specific part, and characteristics of the evaluation value of a plurality of detection regions set around the specific part A fifth step of calculating the number of the detection regions whose characteristics of the evaluation value compared in the fourth step are similar to the specific part, and the fifth step In the case where the number of the detection areas similar to the specific portion calculated in step S is less than a predetermined number, the focus corresponding to the size of the specific portion detected in the third step Said to the distance Characterized in that it comprises a sixth step of combining the lens unit.

本発明によると、例えば人物の顔を特定部分として検出し、その顔の大きさに基づいて焦点を合わせる撮像装置において、その人物の顔の評価値を顔の周囲の検知領域の評価値と比較して写真か実際の人物かを判断する。そのため、被写体として、人物を含む写真が近くにあり、その人物が小さい場合に、実際の人物が遠方にあるものと誤って推測して焦点合わせ動作が遅くなることを防ぐことができる。   According to the present invention, for example, in an imaging apparatus that detects a person's face as a specific part and focuses based on the size of the face, the evaluation value of the person's face is compared with the evaluation value of the detection area around the face To determine whether it is a photograph or an actual person. Therefore, when a photograph including a person is nearby as a subject and the person is small, it is possible to prevent the focusing operation from being delayed due to an erroneous estimation that the actual person is far away.

〈第1の実施形態〉
本発明の第1の実施の形態について、図面を参照して説明する。尚、以下では、本発明における撮影方法を行うデジタルカメラやデジタルビデオなどの撮像装置を例に挙げて説明する。撮像装置は静止画を撮影できるものであれば、動画撮影が可能なものであっても構わない。
<First Embodiment>
A first embodiment of the present invention will be described with reference to the drawings. In the following description, an imaging apparatus such as a digital camera or a digital video that performs the shooting method of the present invention will be described as an example. The imaging device may be capable of capturing a moving image as long as it can capture a still image.

(撮像装置の構成)
まず、撮像装置の内部構成について、図面を参照して説明する。図1は、第1の実施形態に係る撮像装置の内部構成を示すブロック図である。
(Configuration of imaging device)
First, the internal configuration of the imaging apparatus will be described with reference to the drawings. FIG. 1 is a block diagram illustrating an internal configuration of the imaging apparatus according to the first embodiment.

図1の撮像装置は、入射される光を電気信号に変換するCCD又はCMOSセンサなどの固体撮像素子(イメージセンサ)1と、被写体の光学像をイメージセンサ1に結像させるズームレンズとズームレンズの焦点距離すなわち光学ズーム倍率を変化させるモータとズームレンズの焦点を被写体に合わせるためのモータとを有するレンズ部2と、イメージセンサ1から出力されるアナログ信号である画像信号をデジタル信号に変換するAFE(Analog Front End)3と、外部から入力された音声を電気信号に変換するマイク4と、AFE3からのデジタル信号となる画像信号に対して、ぼかし処理及び階調補正を含む各種画像処理を施す画像処理部5と、画像処理部5から入力された画像信号から焦点合わせ制御に用いられるAF評価値を算出する評価値算出部23と、マイク4からのアナログ信号である音声信号をデジタル信号に変換する音声処理部6と、静止画を撮影する場合は画像処理部5からの画像信号に対してJPEG(Joint Photographic Experts Group)圧縮方式など、動画を撮影する場合は画像処理部5からの画像信号と音声処理部6からの音声信号とに対してMPEG(Moving Picture Experts Group)圧縮方式などの圧縮符号化処理を施す圧縮処理部7と、圧縮処理部7で圧縮符号化された圧縮符号化信号をSDカードなどの外部メモリ22に記録するドライバ部8と、ドライバ部8で外部メモリ22から読み出した圧縮符号化信号を伸長して復号する伸長処理部9と、伸長処理部9で復号されて得られた画像信号をアナログ信号に変換するビデオ出力回路部10と、ビデオ出力回路部10で変換された信号を出力するビデオ出力端子11と、ビデオ出力回路部10からの信号に基づく画像の表示を行うLCD等を有するディスプレイ部12と、伸長処理部9からの音声信号をアナログ信号に変換する音声出力回路部13と、音声出力回路部13で変換された信号を出力する音声出力端子14と、音声出力回路部13からの音声信号に基づいて音声を再生出力するスピーカ部15と、各ブロックの動作タイミングを一致させるためのタイミング制御信号を出力するタイミングジェネレータ(TG)16と、撮像装置内全体の駆動動作を制御するCPU(Central Processing Unit)17と、各動作のための各プログラムを記憶するとともにプログラム実行時のデータの一時保管を行うメモリ18と、静止画撮影用のシャッターボタンを含むユーザからの指示が入力される操作部19と、CPU17と各ブロックとの間でデータのやりとりを行うためのバス回線20と、メモリ18と各ブロックとの間でデータのやりとりを行うためのバス回線21と、を備える。レンズ部2は、画像処理部5で検出した画像信号に応じてCPU17が、モータを駆動して焦点、絞りの制御を行うものである。   The imaging apparatus of FIG. 1 includes a solid-state imaging device (image sensor) 1 such as a CCD or CMOS sensor that converts incident light into an electrical signal, and a zoom lens and a zoom lens that form an optical image of a subject on the image sensor 1. A lens unit 2 having a motor for changing the focal length of the zoom lens, that is, the optical zoom magnification, and a motor for focusing the zoom lens on the subject, and an image signal which is an analog signal output from the image sensor 1 is converted into a digital signal. An AFE (Analog Front End) 3, a microphone 4 that converts externally input sound into an electrical signal, and various image processing including blurring processing and gradation correction on an image signal that is a digital signal from the AFE 3 An AF evaluation value used for focusing control is calculated from the image processing unit 5 to be applied and the image signal input from the image processing unit 5 An evaluation value calculation unit 23, an audio processing unit 6 that converts an audio signal that is an analog signal from the microphone 4 into a digital signal, and a JPEG (Joint) for the image signal from the image processing unit 5 when a still image is taken. When a moving image is shot, such as a Photographic Experts Group (compression) compression method, compression coding processing such as an MPEG (Moving Picture Experts Group) compression method is performed on the image signal from the image processing unit 5 and the audio signal from the audio processing unit 6. A compression processing unit 7 that performs the processing, a driver unit 8 that records the compressed encoded signal compressed by the compression processing unit 7 in an external memory 22 such as an SD card, and a compressed code read from the external memory 22 by the driver unit 8 A decompression processing unit 9 that decompresses and decodes the converted signal, a video output circuit unit 10 that converts an image signal obtained by decoding by the decompression processing unit 9 into an analog signal, and a video output circuit unit 1 The video output terminal 11 for outputting the signal converted in the above, the display unit 12 having an LCD or the like for displaying an image based on the signal from the video output circuit unit 10, and the audio signal from the expansion processing unit 9 as an analog signal An audio output circuit unit 13 for conversion, an audio output terminal 14 for outputting a signal converted by the audio output circuit unit 13, a speaker unit 15 for reproducing and outputting audio based on an audio signal from the audio output circuit unit 13; A timing generator (TG) 16 that outputs a timing control signal for matching the operation timing of each block, a CPU (Central Processing Unit) 17 that controls the drive operation of the entire imaging apparatus, and each program for each operation And a memory 18 for temporarily storing data during program execution, and a shutter button for still image shooting An operation unit 19 to which an instruction from the user is input, a bus line 20 for exchanging data between the CPU 17 and each block, and a bus for exchanging data between the memory 18 and each block. And a line 21. In the lens unit 2, the CPU 17 controls the focus and the diaphragm by driving the motor in accordance with the image signal detected by the image processing unit 5.

(撮像装置の基本動作 静止画撮影時)
次に、この撮像装置の静止画撮影時の基本動作について図2のフローチャートを用いて説明する。まず、ユーザが撮像装置の電源をONにすると(STEP201)、撮像装置の撮影モードつまりイメージセンサ1の駆動モードがプレビューモードに設定される(STEP202)。プレビューモードとは、ディスプレイ部12に撮影対象となる画像を表示するモードであり、撮影対象を定め、構図を決定するために用いることができる。続いて撮影モードの入力待ち状態となり、人物撮影に適したモードや移動物の撮影に適したモード、逆光での撮影に適したモード等、撮像装置の機能に応じたモードが選択される。撮影モードが入力されない場合はプレビューモードが選択されたものとする(STEP203)。プレビューモードでは、イメージセンサ1の光電変換動作によって得られたアナログ信号である画像信号がAFE3においてデジタル信号に変換されて、画像処理部5で画像処理が施され、圧縮処理部7で圧縮された現時点の画像に対する画像信号が外部メモリ22に一時的に記録される。この圧縮信号は、ドライバ部8を経て、伸長処理部9で伸長され、現時点で設定されているレンズ部2のズーム倍率での画角の画像がディスプレイ部12に表示される。
(Basic operation of the imaging device)
Next, the basic operation of the image pickup apparatus at the time of still image shooting will be described with reference to the flowchart of FIG. First, when the user turns on the power of the imaging apparatus (STEP 201), the imaging mode of the imaging apparatus, that is, the driving mode of the image sensor 1 is set to the preview mode (STEP 202). The preview mode is a mode in which an image to be photographed is displayed on the display unit 12, and can be used to determine the photographing object and determine the composition. Subsequently, the camera enters a shooting mode input waiting state, and a mode according to the function of the imaging device, such as a mode suitable for human photographing, a mode suitable for photographing a moving object, a mode suitable for photographing with backlight, and the like are selected. If the shooting mode is not input, the preview mode is selected (STEP 203). In the preview mode, an image signal that is an analog signal obtained by the photoelectric conversion operation of the image sensor 1 is converted into a digital signal by the AFE 3, subjected to image processing by the image processing unit 5, and compressed by the compression processing unit 7. An image signal for the current image is temporarily recorded in the external memory 22. The compressed signal is expanded by the expansion processing unit 9 via the driver unit 8, and an image with an angle of view at the zoom magnification of the lens unit 2 set at the present time is displayed on the display unit 12.

続いてユーザが、撮影の対象とする被写体に対して所望の画角となるように、光学ズームでのズーム倍率を設定する(STEP204)。その際、画像処理部5に入力された画像信号を基にCPU17によってレンズ部2を制御して、最適な露光制御(Automatic Exposure;AE)・焦点合わせ制御(オートフォーカス、Auto Focus;AF)が行われる(STEP205)。ユーザが撮影画角、構図を決定し、操作部19のシャッターボタンを半押しすると(STEP206)、AEの調整を行い(STEP207)、AFの最適化処理を行う(STEP208)。AFの最適化処理については後述する。   Subsequently, the user sets the zoom magnification with the optical zoom so that the desired angle of view is obtained with respect to the subject to be imaged (STEP 204). At this time, the lens unit 2 is controlled by the CPU 17 based on the image signal input to the image processing unit 5, and optimum exposure control (Automatic Exposure; AE) / focusing control (Auto Focus; AF) is performed. It is carried out (STEP 205). When the user determines the shooting angle of view and composition and presses the shutter button of the operation unit 19 halfway (STEP 206), the AE is adjusted (STEP 207) and the AF optimization process is performed (STEP 208). The AF optimization process will be described later.

その後、シャッターボタンが全押しされると(STEP209)、TG16より、イメージセンサ1、AFE3、画像処理部5及び圧縮処理部7それぞれに対してタイミング制御信号が与えられ、各部の動作タイミングを同期させ、イメージセンサ1の駆動モードを静止画撮影モードに設定し(STEP210)、イメージセンサ1から出力されるアナログ信号である画像信号(生データ)をAFE3でデジタル信号に変換して一旦画像処理部5内のフレームメモリに書き込む(STEP211)。このデジタル信号がこのフレームメモリから読み込まれ、画像処理部5において輝度信号及び色差信号の生成を行う信号変換処理などの各種画像処理が施され、画像処理が施された信号が圧縮処理部7においてJPEG(Joint Photographic Experts Group)形式に圧縮された(STEP212)後、外部メモリ22に圧縮画像を書き込み(STEP213)、撮影を完了する。その後、プレビューモードに戻る(STEP202)。   Thereafter, when the shutter button is fully pressed (STEP 209), the TG 16 gives timing control signals to the image sensor 1, the AFE 3, the image processing unit 5 and the compression processing unit 7 to synchronize the operation timing of each unit. Then, the drive mode of the image sensor 1 is set to the still image shooting mode (STEP 210), and the image signal (raw data) that is an analog signal output from the image sensor 1 is converted into a digital signal by the AFE 3, and the image processing unit 5 is temporarily set. Is written in the frame memory (STEP 211). This digital signal is read from the frame memory, and various image processing such as signal conversion processing for generating a luminance signal and a color difference signal is performed in the image processing unit 5, and the signal subjected to the image processing is processed in the compression processing unit 7. After being compressed to JPEG (Joint Photographic Experts Group) format (STEP 212), the compressed image is written in the external memory 22 (STEP 213), and the photographing is completed. Thereafter, the process returns to the preview mode (STEP 202).

(撮像装置の基本動作 動画撮影時)
動画撮影時の動作について説明する。この撮像装置において、撮像動作を行うことが操作部19によって指示されると、イメージセンサ1の光電変換動作によって得られたアナログ信号である画像信号がAFE3に出力される。このとき、イメージセンサ1では、TG16からのタイミング制御信号が与えられることによって、水平走査及び垂直走査が行われて、画素毎のデータとなる画像信号が出力される。そして、AFE3において、アナログ信号である画像信号(生データ)がデジタル信号に変換されて、画像処理部5に入力されると、輝度信号及び色差信号の生成を行う信号変換処理などの各種画像処理が施される。
(Basic operation of the imaging device)
The operation during movie shooting will be described. In this imaging apparatus, when the operation unit 19 instructs to perform an imaging operation, an image signal that is an analog signal obtained by the photoelectric conversion operation of the image sensor 1 is output to the AFE 3. At this time, the image sensor 1 receives the timing control signal from the TG 16 to perform horizontal scanning and vertical scanning, and output an image signal as data for each pixel. In the AFE 3, when an image signal (raw data) that is an analog signal is converted into a digital signal and input to the image processing unit 5, various image processing such as signal conversion processing that generates a luminance signal and a color difference signal. Is given.

そして、画像処理部5で画像処理が施された画像信号が圧縮処理部7に与えられる。このとき、マイク4に音声入力されることで得られたアナログ信号である音声信号が、音声処理部6でデジタル信号に変換されて、圧縮処理部7に与えられる。これにより、圧縮処理部7では、デジタル信号である画像信号及び音声信号に対して、MPEG圧縮符号方式に基づいて、圧縮符号化してドライバ部8に与えて、外部メモリ22に記録させる。又、このとき、外部メモリ22に記録された圧縮信号がドライバ部8によって読み出されて伸長処理部9に与えられて、伸長処理が施されて画像信号が得られる。この画像信号がディスプレイ部12に与えられて、現在、イメージセンサ1を通じて撮影されている被写体画像が表示される。   Then, the image signal subjected to the image processing by the image processing unit 5 is given to the compression processing unit 7. At this time, an audio signal which is an analog signal obtained by inputting the sound into the microphone 4 is converted into a digital signal by the audio processing unit 6 and given to the compression processing unit 7. As a result, the compression processing unit 7 compresses and encodes the image signal and the audio signal, which are digital signals, based on the MPEG compression encoding method, gives the image signal and the audio signal to the driver unit 8, and records them in the external memory 22. At this time, the compressed signal recorded in the external memory 22 is read by the driver unit 8 and applied to the decompression processing unit 9, and decompressed to obtain an image signal. This image signal is given to the display unit 12 to display a subject image currently photographed through the image sensor 1.

このように撮像動作を行うとき、TG16によって、AFE3、画像処理部5、音声処理部6、圧縮処理部7、及び伸長処理部9に対してタイミング制御信号が与えられ、イメージセンサ1による1フレームごとの撮像動作に同期した動作が行われる。   When the imaging operation is performed in this way, a timing control signal is given to the AFE 3, the image processing unit 5, the audio processing unit 6, the compression processing unit 7, and the expansion processing unit 9 by the TG 16, and one frame by the image sensor 1. An operation synchronized with each imaging operation is performed.

又、外部メモリ22に記録された動画を再生することが、操作部19を通じて指示されると、外部メモリ22に記録された圧縮信号は、ドライバ部8によって読み出されて伸長処理部9に与えられる。そして、伸長処理部9において、MPEG圧縮符号方式に基づいて、伸長復号されて、画像信号及び音声信号が取得される。そして、画像信号がディスプレイ部12に与えられて画像が再生されるとともに、音声信号が音声出力回路部13を介してスピーカ部15に与えられて音声が再生される。これにより、外部メモリ22に記録された圧縮信号に基づく動画が音声とともに再生される。   When the operation unit 19 instructs to play back the moving image recorded in the external memory 22, the compressed signal recorded in the external memory 22 is read out by the driver unit 8 and given to the decompression processing unit 9. It is done. Then, the decompression processing unit 9 decompresses and decodes the image signal and the audio signal based on the MPEG compression encoding method. Then, the image signal is given to the display unit 12 to reproduce the image, and the audio signal is given to the speaker unit 15 via the audio output circuit unit 13 to reproduce the audio. Thereby, a moving image based on the compressed signal recorded in the external memory 22 is reproduced together with the sound.

画像を再生することが指示された場合は、外部メモリ22に記録された圧縮信号が伸長処理部9において、JPEG圧縮符号方式に基づいて、伸長復号されて、画像信号が取得される。そして、画像信号がディスプレイ部12に与えられて画像が再生される。   When it is instructed to reproduce an image, the decompression processing unit 9 decompresses and decodes the compressed signal recorded in the external memory 22 based on the JPEG compression encoding method, and acquires an image signal. Then, the image signal is given to the display unit 12 to reproduce the image.

(AFの最適化処理)
次に、AFの最適化処理について説明する。図3は撮影画像エリアを複数の領域に分割した画像の例、図4は本実施形態のAFの最適化処理のフローチャートである。
(AF optimization process)
Next, AF optimization processing will be described. FIG. 3 is an example of an image obtained by dividing a photographed image area into a plurality of regions, and FIG. 4 is a flowchart of AF optimization processing according to the present embodiment.

図4のフローチャートにおいて、最適化処理を開始すると、まず、レンズ部2の合焦距離を無限遠に設定し、CPU17に設けられた距離情報記憶部17aに記憶された距離情報及びAF評価値を消去し、評価値算出部23を初期化するなど、焦点合わせ及び距離検出に関する部分を初期化する(STEP401)。続いてその合焦距離(この場合は初期化直後なので無限遠)での画像を読み込み、その画像を複数の領域、例えば図3に示すように縦16列、横16行の256個の領域に分割し、その分割領域全てのAF評価値を取得する(STEP402)。ここでAF評価値には、輝度信号の高周波成分の強度を利用することができる。   In the flowchart of FIG. 4, when the optimization process is started, first, the focusing distance of the lens unit 2 is set to infinity, and the distance information and the AF evaluation value stored in the distance information storage unit 17 a provided in the CPU 17 are set. Erasing and initializing the evaluation value calculation unit 23, for example, initializes a portion related to focusing and distance detection (STEP 401). Subsequently, an image at the in-focus distance (in this case, infinity because it is immediately after initialization) is read, and the image is read into a plurality of areas, for example, 256 areas of 16 columns and 16 rows as shown in FIG. The AF evaluation values of all the divided areas are acquired (STEP 402). Here, the intensity of the high-frequency component of the luminance signal can be used as the AF evaluation value.

次に、STEP401で読み込んだ画像中に、人物の顔があるかどうかを検出する(STEP403)。人物の顔検出については後述する。顔を検出しなかった場合(STEP403でNo)、評価値算出部23において今回の合焦距離の画像の分割領域全てのAF評価値の合計を前回の合焦距離のものと比較する(STEP411)。今回の画像の合焦距離が無限遠の場合は、最初の画像であることから比較の対象となる前回の合焦距離の画像がないため、STEP411は省略し、合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。分割領域全てのAF評価値の合計を比較した結果が減少していた場合(STEP412でNo)、前回の合焦距離で、AF評価値が極大値であり、被写体に焦点が合うものとしてレンズ部2の合焦距離を前回の合焦距離に戻して(STEP414)、AFの最適化処理を終了する。AF評価値を比較した結果が増加していた場合(STEP412でYes)、次もAF評価値が増加すると予測される方向、即ちレンズ部の合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。その後、CPU17がTG16から垂直同期(以下V sync)信号を受けるとSTEP402に戻り、所定の距離短い合焦距離での画像を読み込み、その分割領域でのAF評価値を取得する(STEP402)。   Next, it is detected whether or not there is a human face in the image read in STEP 401 (STEP 403). The human face detection will be described later. If no face is detected (No in STEP 403), the evaluation value calculation unit 23 compares the sum of the AF evaluation values of all the divided areas of the image at the current focus distance with that at the previous focus distance (STEP 411). . If the focus distance of the current image is infinity, there is no image of the previous focus distance to be compared because it is the first image, so STEP 411 is omitted and the focus distance is shortened. A predetermined distance is moved (STEP 413). If the result of comparing the sum of the AF evaluation values of all the divided areas has decreased (No in STEP 412), the lens unit is assumed to have a maximum AF evaluation value and focus on the subject at the previous focusing distance. 2 is returned to the previous focusing distance (STEP 414), and the AF optimization process is terminated. If the result of comparing the AF evaluation values has increased (Yes in STEP 412), the lens is moved by a predetermined distance in the direction in which the AF evaluation value is predicted to increase again, that is, in the direction in which the focusing distance of the lens unit is shortened ( (STEP413). Thereafter, when the CPU 17 receives a vertical synchronization (hereinafter referred to as V sync) signal from the TG 16, the process returns to STEP 402, an image is read at a short focal distance by a predetermined distance, and an AF evaluation value in the divided area is acquired (STEP 402).

(顔検出処理)
ここで、この撮像装置の顔検出処理について説明する。画像処理部5は顔検出装置40を備え、入力された画像信号から人物の顔を検出することができる。顔検出装置40の構成及び動作について以下に説明する。
(Face detection process)
Here, the face detection process of the imaging apparatus will be described. The image processing unit 5 includes a face detection device 40 and can detect a person's face from the input image signal. The configuration and operation of the face detection device 40 will be described below.

図5は、顔検出装置40の構成を示すブロック図である。顔検出装置40は、AFE3によって得られた画像データに基づいて1又は複数の縮小画像を生成する縮小画像生成手段42、入力画像および縮小画像から構成される各階層画像とメモリ18に記憶された顔検出用の重みテーブルとを用いて入力画像に顔が存在するか否かを判定する顔判定手段45、および顔判定手段45の検出結果を出力する検出結果出力手段46を備えている。検出結果出力手段46は、顔が検出された場合には、検出された顔の入力画像を基準とする大きさと位置及び顔の大きさから推定したその顔までの距離を出力する。   FIG. 5 is a block diagram showing a configuration of the face detection device 40. The face detection device 40 is stored in the memory 18 and reduced image generation means 42 for generating one or a plurality of reduced images based on the image data obtained by the AFE 3, each hierarchical image composed of the input image and the reduced image, and the memory 18. A face determination unit 45 that determines whether or not a face exists in the input image using a face detection weight table, and a detection result output unit 46 that outputs a detection result of the face determination unit 45 are provided. When a face is detected, the detection result output means 46 outputs a distance to the face estimated from the size and position of the detected face input image and the size of the face.

又、メモリ18に記憶された重みテーブルは、大量の教師サンプル(顔および非顔のサンプル画像)から求められたものである。このような重みテーブルは、例えば、Adaboostと呼ばれる公知の学習方法を利用して作成することができる(Yoav Freund, Robert E. Schapire,"A decision-theoretic generalization of on-line learning and an application to boosting", European Conference on Computational Learning Theory, September 20,1995.)。   The weight table stored in the memory 18 is obtained from a large number of teacher samples (face and non-face sample images). Such a weight table can be created using, for example, a known learning method called Adaboost (Yoav Freund, Robert E. Schapire, “A decision-theoretic generalization of on-line learning and an application to boosting” ", European Conference on Computational Learning Theory, September 20, 1995.).

尚、Adaboostは、適応的なブースティング学習方法の1つで、大量の教師サンプルをもとに、複数の弱識別器候補の中から識別に有効な弱識別器を複数個選択し、それらを重み付けして統合することによって高精度な識別器を実現する学習方法である。ここで、弱識別器とは、全くの偶然よりは識別能力は高いが、十分な精度を満たすほど高精度ではない識別器のことをいう。弱識別器の選択時には、既に選択した弱識別器がある場合、選択済の弱識別器によって誤認識してしまう教師サンプルに対して学習を重点化することによ
って、残りの弱識別器候補の中から最も効果の高い弱識別器を選択する。
Adaboost is an adaptive boosting learning method. Based on a large number of teacher samples, Adaboost selects multiple weak classifiers that are effective for identification from among a plurality of weak classifier candidates. This is a learning method for realizing a highly accurate classifier by weighting and integrating. Here, a weak classifier refers to a classifier that has a higher discrimination ability than a coincidence but is not high enough to satisfy sufficient accuracy. When a weak classifier is selected, if there is a weak classifier that has already been selected, the learning is focused on the teacher sample that is misrecognized by the selected weak classifier. To select the most effective weak classifier.

図6は、縮小画像生成手段42によって得られる階層画像の一例を示している。この例では、縮小率を0.8に設定した場合に、生成される複数の階層画像を示している。図6において、50は入力画像を、51〜55は縮小画像を示している。61は判定領域を示している。この例では、判定領域は縦24画素、横24画素の大きさに設定されている。判定領域の大きさは、入力画像および各縮小画像においても同じである。又、この例では、矢印で示すように、階層画像上で判定領域を左から右に移動させる、水平方向走査を、上方から下方に向かって行うことで、判定領域とマッチングする顔画像の検出を行う。ただし、走査順はこれに限られるものではない。入力画像50の他に、複数の縮小画像51〜55を生成しているのは、1種類の重みテーブルを用いて大きさが異なる顔を検出するためである。   FIG. 6 shows an example of a hierarchical image obtained by the reduced image generating means 42. This example shows a plurality of hierarchical images generated when the reduction ratio is set to 0.8. In FIG. 6, 50 indicates an input image, and 51-55 indicate reduced images. Reference numeral 61 denotes a determination area. In this example, the determination area is set to a size of 24 pixels vertically and 24 pixels horizontally. The size of the determination area is the same for the input image and each reduced image. In this example, as indicated by an arrow, a face image matching the determination area is detected by moving the determination area from left to right on the hierarchical image and performing horizontal scanning from the top to the bottom. I do. However, the scanning order is not limited to this. The reason why the plurality of reduced images 51 to 55 are generated in addition to the input image 50 is to detect faces of different sizes using one kind of weight table.

図7は顔検出処理を説明するための図である。顔判定手段45による顔検出処理は、各階層画像毎に行なわれるが、処理方法は同様なので、ここでは入力画像50に対して行なわれる顔検出処理についてのみ説明する。図7には、入力画像50と、入力画像内に設定された判定領域61とを示している。   FIG. 7 is a diagram for explaining the face detection process. The face detection processing by the face determination unit 45 is performed for each hierarchical image, but since the processing method is the same, only the face detection processing performed on the input image 50 will be described here. FIG. 7 shows an input image 50 and a determination area 61 set in the input image.

各階層画像毎に行なわれる顔検出処理は、画像内に設定された判定領域に対応する画像と重みテーブルとを用いて行なわれる。顔検出処理は粗い判定から順次細かい判定に移行する複数の判定ステップからなり、ある判定ステップにおいて、顔が検出されなかった場合には、次の判定ステップには移行せず、当該判定領域には顔は存在しないと判定する。全ての判定ステップにおいて、顔が検出された場合にのみ、当該判定領域に顔が存在すると判定し、判定領域を走査して次の判定領域での判定に移行する。そして、顔が検出されたとき、いずれの階層画像が用いられていたかによって、入力画像を基準とする顔の大きさ及び顔までの距離を推定することができる。このようにして、検出された顔の位置、大きさ及びその顔を有する人物までの距離は検出結果出力手段46によって出力される。尚、このような顔検出処理については、本願出願人による特許出願である特願2006−053304号に詳しく記載されている。   The face detection process performed for each hierarchical image is performed using an image corresponding to the determination region set in the image and a weight table. The face detection process includes a plurality of determination steps that sequentially shift from a rough determination to a fine determination. When a face is not detected in a certain determination step, the process does not proceed to the next determination step, and the determination area includes It is determined that no face exists. In all the determination steps, only when a face is detected, it is determined that a face exists in the determination area, and the determination area is scanned to shift to determination in the next determination area. When a face is detected, the size of the face and the distance to the face can be estimated based on the input image depending on which layer image is used. Thus, the detection result output means 46 outputs the position and size of the detected face and the distance to the person having the face. Such face detection processing is described in detail in Japanese Patent Application No. 2006-053304, which is a patent application filed by the present applicant.

STEP403で人物の顔を検出した場合(STEP403でYes)、前回の合焦距離での画像において顔を検出したかどうかをチェックする(STEP404)。前回の合焦距離での画像において顔を検出しなかった場合(STEP404でNo)、顔領域を設定し、さらにその顔領域の上、下、右、左にその顔領域と同じ大きさの検知領域を設定する。そして、顔領域及び検知領域のAF評価値を取得する。前回の合焦距離での画像における各領域でのAF評価値とを比較する。前回と今回のものとの変化の方向(正か、負か、変化なしか)が、顔領域と異なる検知領域の個数を計数する(STEP406)。本実施形態では、この変化の方向が顔領域と異なる検知領域の個数を信頼度Rと呼ぶ。   If a human face is detected in STEP 403 (YES in STEP 403), it is checked whether or not a face has been detected in the image at the previous focusing distance (STEP 404). When a face is not detected in the image at the previous focusing distance (No in STEP 404), a face area is set, and detection of the same size as the face area is performed above, below, right, and left of the face area. Set the area. Then, AF evaluation values of the face area and the detection area are acquired. The AF evaluation value in each area in the image at the previous focusing distance is compared. The number of detection areas in which the direction of change (positive, negative, or no change) between the previous and current ones is different from the face area is counted (STEP 406). In the present embodiment, the number of detection areas whose direction of change is different from the face area is referred to as reliability R.

信頼度Rが2未満、即ち0又は1の場合(STEP407でNo)、上述のSTEP411に移行する。この場合、AF評価値の変化の方向が顔領域と同じ検知領域が3個又は4個あるということであり、顔と背景とが同じ距離にあるもの、即ち被写体が人物を含むテレビの画面や写真、絵画等であるとして通常の焦点合わせ動作を行うものとする。このような被写体としては、例えば図16に示す壁面上に掛けられた人物を含む写真が挙げられる。図8に、図16の画像を縦16列、横16行の256個の領域に区分してその領域に設定した顔領域と4個の検知領域の、AF評価値と合焦距離との関係を図9に示す。図9では、顔領域のAF評価値と、検知領域のAF評価値は、大きさは異なるものの、極大値の合焦距離はほぼ同じである。   When the reliability R is less than 2, that is, 0 or 1 (No in STEP 407), the process proceeds to the above-described STEP 411. In this case, there are three or four detection areas in which the direction of change of the AF evaluation value is the same as that of the face area, and the face and the background are at the same distance, that is, a TV screen including a person as a subject. It is assumed that a normal focusing operation is performed for a photograph or a picture. Examples of such a subject include a photograph including a person hung on a wall surface shown in FIG. FIG. 8 shows the relationship between the AF evaluation value and the focus distance of the face area and the four detection areas set in the area obtained by dividing the image of FIG. 16 into 256 areas of 16 columns and 16 rows. Is shown in FIG. In FIG. 9, although the AF evaluation value of the face area and the AF evaluation value of the detection area are different in size, the focal distance of the maximum value is almost the same.

信頼度Rが2以上、即ち2、3又は4の場合(STEP407でYes)、ディスプレイ部12上の顔領域に顔検出枠を表示する(STEP408)。顔検出枠を表示することにより、焦点合わせの対象としている被写体を使用者に対して明確なものとすることができる。信頼度Rが2以上の場合、AF評価値の変化の方向が顔領域と異なる検知領域が2〜4個あるということとであり、顔と背景とが異なる距離にあるもの、即ち被写体が実際の人物とその人物から離れた背景とであるものとして焦点合わせ動作を行うものとする。そのため、顔領域の大きさに基づいて人物までの距離を推定し、その距離よりも所定の割合だけ遠い位置へレンズ部2の合焦距離を移動させる(STEP409)。顔領域の大きさに基づいて人物までの距離を推定することは、上述のように顔が検出されたときに用いられていた階層画像の大きさから行うことができる。   When the reliability R is 2 or more, that is, 2, 3 or 4 (Yes in STEP 407), a face detection frame is displayed in the face area on the display unit 12 (STEP 408). By displaying the face detection frame, the subject to be focused can be made clear to the user. When the reliability R is 2 or more, there are 2 to 4 detection areas in which the direction of change of the AF evaluation value differs from the face area, and the face and the background are at different distances, that is, the subject is actually It is assumed that the focusing operation is performed on the assumption that the person is a background and a background away from the person. Therefore, the distance to the person is estimated based on the size of the face area, and the focusing distance of the lens unit 2 is moved to a position farther than the distance by a predetermined ratio (STEP 409). Estimating the distance to the person based on the size of the face area can be performed from the size of the hierarchical image used when the face is detected as described above.

このような被写体としては、例えば図3に示すような、背景である山と、その前に配置された実際の人物とが挙げられる。図3の画像では、顔領域及び4個の検知領域はそれぞれ縦2列、横2行の4個の領域からなる。図3の画像に設定した顔領域と4個の検知領域の、AF評価値と合焦距離との関係を図10に示す。図10では、顔領域のAF評価値と、人物の体に当たる位置の検知領域のAF評価値は、大きさは異なるものの、極大値の位置はほぼ同じである。しかし、背景に当たる位置の検知領域のAF評価値の合焦距離に対する変化の仕方は、顔領域のAF評価値とは異なり、極大値の位置も異なる。   As such a subject, for example, a background mountain as shown in FIG. 3 and an actual person arranged in front of the mountain can be cited. In the image of FIG. 3, the face area and the four detection areas are each composed of four areas in two columns and two rows. FIG. 10 shows the relationship between the AF evaluation value and the in-focus distance for the face area and the four detection areas set in the image of FIG. In FIG. 10, although the AF evaluation value of the face area and the AF evaluation value of the detection area at the position corresponding to the human body are different in size, the position of the maximum value is almost the same. However, the manner in which the AF evaluation value of the detection area at the position corresponding to the background changes with respect to the in-focus distance is different from the AF evaluation value of the face area, and the position of the maximum value is also different.

その後、CPU17がTG16からV sync信号を受けるとSTEP402に戻り、所定の距離短い合焦距離での画像を読み込み、その分割領域でのAF評価値を取得する。   Thereafter, when the CPU 17 receives the V sync signal from the TG 16, the process returns to STEP 402, an image is read at a short focal distance by a predetermined distance, and an AF evaluation value in the divided area is acquired.

STEP403で人物の顔を検出し、かつ前回の合焦距離での画像においても顔を検出していた場合(STEP404でYes)、上述のSTEP411に移行する。これは、既にその顔の大きさから推定した距離に基づく位置に合焦距離を移動させており(STEP409)、再度その距離に合焦距離を移動させる必要はないからである。そして、今回の分割領域全てのAF評価値の合計を前回のものと比較し(STEP411)、その結果が減少していた場合(STEP412でNo)はレンズ部2の合焦距離を前回の合焦距離に戻して(STEP414)、AFの最適化処理を終了する。AF評価値を比較した結果が増加していた場合は、レンズ部2の合焦距離を短くなる方向へ所定の距離移動させ(STEP413)、CPU17がTG16からV sync信号を受ける(STEP410)とSTEP402に戻る。   If a face of a person is detected in STEP 403 and a face is also detected in an image at the previous focusing distance (YES in STEP 404), the process proceeds to the above-described STEP 411. This is because the in-focus distance has already been moved to a position based on the distance estimated from the face size (STEP 409), and it is not necessary to move the in-focus distance to that distance again. Then, the sum of the AF evaluation values of all the divided areas is compared with the previous one (STEP 411). If the result is decreased (No in STEP 412), the in-focus distance of the lens unit 2 is set to the previous focus. The distance is returned (STEP 414), and the AF optimization process is terminated. If the result of comparing the AF evaluation values has increased, the focusing distance of the lens unit 2 is moved by a predetermined distance in the direction of shortening (STEP 413), and the CPU 17 receives a V sync signal from the TG 16 (STEP 410). Return to.

ここで、本実施形態のAFの最適化処理について、分割領域全てのAF評価値の合計及び顔領域のAF評価値と合焦距離との関係を示す図11のグラフを用いて説明する。図11のグラフは分割領域全てのAF評価値の合計の極大値の近傍の拡大図であり、横軸の1目盛りはレンズ部2の合焦距離を移動する1段階分の所定の距離である。図11における無限遠側の1番目の合焦距離から4番目の合焦距離までは、各合焦距離の画像で顔を検出しなかった場合(STEP403でNo)であり、分割領域全てのAF評価値の合計を前回の合焦距離の画像のものと比較した結果が増加していた場合(STEP412でNo)であり、それぞれの合焦距離において、AF評価値が増加する方向即ちレンズ部の合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。5番目の合焦距離では、この合焦距離の画像において顔を検出し、信頼度Rが2以上であるため(STEP407でYes)、顔領域の大きさから推定した距離に基づく合焦距離(図11の場合所定の距離の2段階分短い合焦距離)に移動させる。よって、6番目に相当する合焦距離での画像の読み込みは省略される。その後、7番目の合焦距離から10番目の合焦距離では各合焦距離の画像で顔を検出するものの、連続で検出している。そのため、分割領域全てのAF評価値の合計を各合焦距離において前回の合焦距離(7番目の合焦距離では前回取得した5番目の合焦距離)の画像のものと比較している。7番目の合焦距離から9番目の合焦距離では、その結果が増加しているため(STEP412でNo)レンズ部の合焦距離を短くなる方向へ所定の距離移動させている(STEP413)。10番目の合焦距離では、分割領域全てのAF評価値の合計を9番目の合焦距離の画像のものと比較した結果が減少しており(STEP412でYes)、合焦距離を前回すなわち9番目の合焦距離に戻す(STEP414)。尚、図11のグラフはAFの最適化処理の動作を簡単に示すための模式的なものである。したがって、レンズ部2の合焦距離を移動する1段階分の所定の距離は、実際には焦点合わせの精度を高めるために、図11よりも細かいものとしてもよいし、又、AFの最適化処理をより速くするために粗いものとしてもよい。   Here, the AF optimization processing of the present embodiment will be described with reference to the graph of FIG. 11 that shows the sum of the AF evaluation values of all the divided regions and the relationship between the AF evaluation values of the face regions and the in-focus distance. The graph of FIG. 11 is an enlarged view of the vicinity of the total maximum value of the AF evaluation values of all the divided areas, and one scale on the horizontal axis is a predetermined distance for one step in which the focal distance of the lens unit 2 is moved. . From the first focusing distance on the infinity side to the fourth focusing distance in FIG. 11 is a case where no face is detected in the image at each focusing distance (No in STEP 403), and AF in all the divided areas is performed. This is the case where the result of comparing the sum of the evaluation values with that of the image at the previous focusing distance has increased (No in STEP 412). At each focusing distance, the direction in which the AF evaluation value increases, that is, the lens portion A predetermined distance is moved in a direction to shorten the focusing distance (STEP 413). At the fifth in-focus distance, a face is detected in the image at this in-focus distance, and the reliability R is 2 or more (Yes in STEP 407). Therefore, the in-focus distance based on the distance estimated from the size of the face area ( In the case of FIG. 11, the lens is moved to a focus distance shorter by two steps of a predetermined distance. Therefore, the reading of the image at the focusing distance corresponding to the sixth is omitted. Thereafter, the face is detected from the images at the respective in-focus distances from the seventh in-focus distance to the tenth in-focus distance, but is continuously detected. Therefore, the sum of the AF evaluation values of all the divided areas is compared with the image of the previous focus distance (the fifth focus distance acquired last time for the seventh focus distance) at each focus distance. Since the result increases from the seventh in-focus distance to the ninth in-focus distance (No in STEP 412), the in-focus distance of the lens unit is moved by a predetermined distance (STEP 413). At the 10th in-focus distance, the result of comparing the sum of the AF evaluation values of all the divided areas with that of the image at the 9th in-focus distance is decreased (Yes in STEP 412). Return to the in-focus distance (STEP 414). The graph of FIG. 11 is a schematic diagram for simply showing the operation of the AF optimization process. Therefore, the predetermined distance for one step of moving the focusing distance of the lens unit 2 may actually be finer than that of FIG. 11 in order to increase the focusing accuracy, and the AF may be optimized. It may be rough to make the process faster.

このように、顔領域の大きさから推定した距離に基づいた位置へレンズ部2の合焦距離をさせることにより、無限遠から所定の距離の1段階ずつ合焦距離を変化させる場合に比べて素早く人物に焦点を合わせることができる。さらに、被写体が実際の人物であることを信頼度Rから評価しているため、被写体として人物を含む写真が近くにあり、その人物が小さい場合には、人物が遠方にあるものと誤って推測していまい、焦点合わせに必要な時間が長くなってしまうことを避けることができる。尚、推定した距離よりも所定の割合だけ遠い位置へ合焦距離を移動させるのは、推定した距離が実際の距離よりも近い場合には、推定したそのままの距離に合焦距離を移動させたのでは人物に合焦できなくなるためである。   In this way, by moving the focusing distance of the lens unit 2 to the position based on the distance estimated from the size of the face area, the focusing distance can be changed more quickly than when changing the focusing distance in steps of a predetermined distance from infinity. Focus on a person. Furthermore, since the reliability is evaluated that the subject is an actual person, if the photograph including the person is nearby as the subject and the person is small, the person is mistakenly assumed to be far away. In this way, it is possible to avoid an increase in the time required for focusing. The in-focus distance is moved to a position that is a predetermined percentage away from the estimated distance. If the estimated distance is closer than the actual distance, the in-focus distance is moved to the estimated distance. This is because it becomes impossible to focus on a person.

尚、本実施形態において、AFの最適化処理には、輝度信号の高周波成分をAF評価値とし、全領域のAF評価値を足し合わせて用いてもよいし、特定の領域、例えば図3において中央部の縦8列、横8行の64個の領域を他の領域よりも重みを付けて足し合わせて用いてもよい。又、上記の特定の領域のみのAF評価値を足し合わせて用いてもよい。   In the present embodiment, in the AF optimization process, the high-frequency component of the luminance signal may be used as the AF evaluation value, and the AF evaluation values of the entire area may be added together or used in a specific area, for example, FIG. The 64 regions of 8 columns in the center and 8 rows in the center may be used by adding more weight than other regions. Further, the AF evaluation values for only the specific area may be added together.

(第2の実施形態)
本発明の第2の実施形態について、図を用いて説明する。図12は第2の実施形態に係る撮像装置のAF最適化処理についてのフローチャートである。本実施形態は、AF最適化処理のうち、顔を検出した場合の動作が異なる以外は第1の実施形態と同じであり、実質上同一の部分には同一の符号を付してある。
(Second Embodiment)
A second embodiment of the present invention will be described with reference to the drawings. FIG. 12 is a flowchart for AF optimization processing of the imaging apparatus according to the second embodiment. The present embodiment is the same as the first embodiment except that the operation when a face is detected in the AF optimization process is different, and substantially the same parts are denoted by the same reference numerals.

図12のフローチャートにおいて、最適化処理を開始すると、まず、レンズ部2の合焦距離を無限遠に設定し、CPU17に設けられた距離情報記憶部17aに記憶されたAF評価値を消去するなど、距離検出に関する部分を初期化する(STEP401)。続いてその合焦距離(この場合は初期化直後なので無限遠)での画像を読み込み、その画像を複数の領域に分割し、その分割領域全てのAF評価値を取得する(STEP402)。   In the flowchart of FIG. 12, when the optimization process is started, first, the focusing distance of the lens unit 2 is set to infinity, and the AF evaluation value stored in the distance information storage unit 17a provided in the CPU 17 is deleted. Then, the part related to distance detection is initialized (STEP 401). Subsequently, an image at the in-focus distance (in this case, infinity because it is just after initialization) is read, the image is divided into a plurality of areas, and AF evaluation values of all the divided areas are acquired (STEP 402).

次に、STEP401で読み込んだ画像中に、人物の顔があるかどうかを検出する(STEP403)。顔を検出しなかった場合(STEP403でNo)、今回の分割領域全てのAF評価値の合計を前回のものと比較する(STEP1214)。今回の画像の合焦距離が無限遠の場合は、最初の画像であることから比較の対象となる前回の合焦距離の画像がないため、STEP1214は省略し、合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。分割領域全てのAF評価値の合計を比較した結果が減少していた場合(STEP412でNo)、前回の合焦距離で、AF評価値が極大値であり、被写体に焦点が合うものとしてレンズ部2の合焦距離を前回の合焦距離に戻して(STEP1215)、AFの最適化処理を終了する。AF評価値を比較した結果が増加していた場合(STEP412でYes)、次もAF評価値が増加すると予測される方向、即ちレンズ部の合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。その後、CPU17がTG16からV sync信号を受けるとSTEP402に戻り、所定の距離短い合焦距離での画像を読み込み、その分割領域でのAF評価値を取得する(STEP402)。   Next, it is detected whether or not there is a human face in the image read in STEP 401 (STEP 403). If no face is detected (No in STEP 403), the sum of the AF evaluation values of all of the current divided areas is compared with the previous one (STEP 1214). When the focus distance of the current image is infinite, since it is the first image, there is no previous focus distance image to be compared, so STEP 1214 is omitted and the focus distance is shortened. A predetermined distance is moved (STEP 413). If the result of comparing the sum of the AF evaluation values of all the divided areas has decreased (No in STEP 412), the lens unit is assumed to have a maximum AF evaluation value and focus on the subject at the previous focusing distance. 2 is returned to the previous focusing distance (STEP 1215), and the AF optimization process is terminated. If the result of comparing the AF evaluation values has increased (Yes in STEP 412), the lens is moved by a predetermined distance in the direction in which the AF evaluation value is predicted to increase again, that is, in the direction in which the focusing distance of the lens unit is shortened ( (STEP413). Thereafter, when the CPU 17 receives the V sync signal from the TG 16, the process returns to STEP 402, an image at a predetermined short focal distance is read, and an AF evaluation value in the divided area is acquired (STEP 402).

STEP403で人物の顔を検出した場合、前回の合焦距離での画像において顔を検出したかどうかをチェックする(STEP404)。前回の合焦距離での画像において顔を検出しなかった場合(STEP404でNo)、顔領域を設定し、さらにその顔領域の上、下、右、左にその顔領域と同じ大きさの検知領域を設定する。そして、顔領域及び検知領域のAF評価値を取得して前回の合焦距離のものと比較し(STEP405)、信頼度Rを算出する(STEP406)。   When the face of a person is detected in STEP 403, it is checked whether or not a face has been detected in the image at the previous focusing distance (STEP 404). When a face is not detected in the image at the previous focusing distance (No in STEP 404), a face area is set, and detection of the same size as the face area is performed above, below, right, and left of the face area. Set the area. Then, the AF evaluation values of the face area and the detection area are acquired and compared with those of the previous in-focus distance (STEP 405), and the reliability R is calculated (STEP 406).

信頼度Rが2未満の場合(STEP407でNo)、上述のSTEP1214に移行する。信頼度Rが2以上の場合(STEP407でYes)、ディスプレイ部12上の顔領域に顔検出枠を表示する(STEP408)。そして、顔領域の大きさから人物までの距離を推定し、その距離よりも所定の割合だけ遠い位置へレンズ部2の合焦距離を移動させる(STEP409)。   When the reliability R is less than 2 (No in STEP 407), the process proceeds to the above STEP 1214. When the reliability R is 2 or more (YES in STEP 407), a face detection frame is displayed in the face area on the display unit 12 (STEP 408). Then, the distance to the person is estimated from the size of the face area, and the focusing distance of the lens unit 2 is moved to a position farther than the distance by a predetermined ratio (STEP 409).

その後、CPU17がTG16からV sync信号を受けるとSTEP402に戻り、所定の距離短い合焦距離での画像を読み込み、その分割領域でのAF評価値を取得する。   Thereafter, when the CPU 17 receives the V sync signal from the TG 16, the process returns to STEP 402, an image is read at a short focal distance by a predetermined distance, and an AF evaluation value in the divided area is acquired.

STEP403で人物の顔を検出し(STEP403でYes)、かつ前回の合焦距離での画像においても顔を検出していた場合(STEP404でYes)、今回の顔領域のAF評価値を前回のものと比較する(STEP411)。顔領域のAF評価値の合計を比較した結果が減少していた場合(STEP412でNo)、レンズ部2の合焦距離を前回の合焦距離に戻して(STEP1215)、AFの最適化処理を終了する。AF評価値を比較した結果が増加していた場合(STEP412でYes)、次もAF評価値が増加すると予測される方向、即ちレンズ部の合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。その後、CPU17がTG16からV sync信号を受けるとSTEP402に戻り、所定の距離短い合焦距離での画像を読み込み、その分割領域でのAF評価値を取得する(STEP402)。   If a human face is detected in STEP 403 (Yes in STEP 403) and a face is also detected in the image at the previous focusing distance (Yes in STEP 404), the AF evaluation value of the current face area is the previous one. (STEP411). If the result of comparing the total AF evaluation values of the face area has decreased (No in STEP 412), the focusing distance of the lens unit 2 is returned to the previous focusing distance (STEP 1215), and AF optimization processing is performed. finish. If the result of comparing the AF evaluation values has increased (Yes in STEP 412), the lens is moved by a predetermined distance in the direction in which the AF evaluation value is predicted to increase again, that is, in the direction in which the focusing distance of the lens unit is shortened ( (STEP413). Thereafter, when the CPU 17 receives the V sync signal from the TG 16, the process returns to STEP 402, an image at a predetermined short focal distance is read, and an AF evaluation value in the divided area is acquired (STEP 402).

STEP403で人物の顔を検出した場合のAFの最適化処理について、分割領域全てのAF評価値の合計及び顔領域のAF評価値と合焦距離との関係を示す図13のグラフを用いて説明する。図13のグラフは、図11と同様のグラフである。図13における無限遠側の1番目の合焦距離から7番目の合焦距離までは、各合焦距離の画像で顔を検出しなかった場合(STEP403でNo)であり、分割領域全てのAF評価値の合計を前回の合焦距離の画像のものと比較した結果が増加していた場合(STEP412でNo)であり、それぞれの合焦距離において、AF評価値が増加する方向即ちレンズ部の合焦距離を短くなる方向へ所定の距離移動させる(STEP413)。5番目の合焦距離では、この合焦距離の画像において顔を初めて検出し(STEP403でYes、STEP404でNo)、信頼度Rが2以上であるため(STEP407でYes)、顔領域の大きさから推定した距離に基づく合焦距離(図13の場合所定の距離の2段階分短い合焦距離)に移動させる。その後、7番目の合焦距離から9番目の合焦距離では各合焦距離の画像で顔を検出するものの、連続で検出している(STEP404)。そのため、顔領域のAF評価値の合計を各合焦距離において前回の合焦距離(7番目の合焦距離では前回取得した5番目の合焦距離)の画像のものと比較する(STEP411)。7番目の合焦距離と8番目の合焦距離では、その結果が増加しているため(STEP412でNo)レンズ部の合焦距離を短くなる方向へ所定の距離移動させている(STEP413)。9番目の合焦距離では、その結果が減少しており(STEP412でYes)、合焦距離を前回すなわち8番目の合焦距離に戻す(STEP1215)。   The AF optimization process when a human face is detected in STEP 403 will be described using the graph of FIG. 13 that shows the sum of the AF evaluation values of all the divided areas and the relationship between the AF evaluation values of the face areas and the in-focus distance. To do. The graph of FIG. 13 is the same graph as FIG. From the first focusing distance on the infinity side to the seventh focusing distance in FIG. 13 is a case where no face is detected in the image at each focusing distance (No in STEP 403), and AF in all the divided areas is performed. This is the case where the result of comparing the sum of the evaluation values with that of the image at the previous focusing distance has increased (No in STEP 412). At each focusing distance, the direction in which the AF evaluation value increases, that is, the lens portion A predetermined distance is moved in a direction to shorten the focusing distance (STEP 413). At the fifth in-focus distance, the face is detected for the first time in the image at this in-focus distance (Yes in STEP 403, No in STEP 404), and the reliability R is 2 or more (Yes in STEP 407). Is moved to a focusing distance based on the distance estimated from (a focusing distance shorter by two steps of a predetermined distance in the case of FIG. 13). After that, although the face is detected from the images at the respective in-focus distances from the seventh in-focus distance to the ninth in-focus distance, they are continuously detected (STEP 404). Therefore, the sum of the AF evaluation values of the face area is compared with that of the image at the previous focus distance (the fifth focus distance acquired at the seventh focus distance) at each focus distance (STEP 411). Since the results of the seventh and eighth in-focus distances increase (No in STEP 412), the in-focus distance of the lens unit is moved by a predetermined distance (STEP 413). The result is decreased at the ninth focus distance (Yes in STEP 412), and the focus distance is returned to the previous focus, that is, the eighth focus distance (STEP 1215).

このように、顔領域の大きさから推定した距離に基づいた位置へレンズ部2の合焦距離をさせることにより、素早く人物に焦点を合わせることができ、被写体が実際の人物であることを信頼度Rから評価しているため、被写体として人物を含む写真が近くにある場合などに、焦点合わせに必要な時間が長くなってしまうことを避けることができる。さらに、顔領域のAF評価値を用いて焦点合わせ動作を行うことにより、被写体である人物に正確に焦点を合わせることができる。   In this way, by bringing the focusing distance of the lens unit 2 to a position based on the distance estimated from the size of the face area, it is possible to quickly focus on the person and trust that the subject is an actual person. Since the evaluation is based on the degree R, it is possible to avoid an increase in the time required for focusing when a photograph including a person is nearby as a subject. Further, by performing the focusing operation using the AF evaluation value of the face area, it is possible to accurately focus on the person who is the subject.

尚、本実施形態において、顔が検出されない場合のAFの最適化処理は、輝度信号の高周波成分をAF評価値とし、全領域のAF評価値を足し合わせて用いてもよいし、特定の領域、例えば図3において中央部の縦8列、横8行の64個の領域を他の領域よりも重みを付けて足し合わせて用いてもよい。又、上記の特定の領域のみのAF評価値を足し合わせて用いてもよい。   In the present embodiment, the AF optimization process when a face is not detected may use the high frequency component of the luminance signal as the AF evaluation value and add the AF evaluation values of the entire area, or use a specific area. For example, in FIG. 3, 64 regions of 8 columns in the center and 8 rows in the center may be used by adding more weight than other regions. Further, the AF evaluation values for only the specific area may be added together.

尚、第1の実施形態及び第2の実施形態のAFの最適化処理において、顔を含む人物が二人以上いる場合のように顔が2個以上検出された場合、いずれの人物に焦点を合わせるかは、ディスプレイ部12に表示された顔検出枠を操作部19で選択できるようにしてもよいし、近い方や遠い方など、所定の基準に基づいて自動的に選択されるものとしてもよい。   In the AF optimization process of the first embodiment and the second embodiment, when two or more faces are detected as in the case where there are two or more persons including the face, focus on any person. The face detection frame displayed on the display unit 12 may be selected by the operation unit 19 or may be automatically selected based on a predetermined criterion such as nearer or farther. Good.

又、被写体として、顔を含む人物について注目して焦点合わせ動作を行うものとしたが、特定の部位を有する被写体であれば、注目する被写体は顔を含む人物に限られない。   In addition, the focusing operation is performed by paying attention to a person including a face as a subject, but the subject to be focused is not limited to a person including a face as long as the subject has a specific part.

本発明は、顔検出機能のように被写体の特定部位を検出する機能を有する撮像装置に適用することができる。   The present invention can be applied to an imaging apparatus having a function of detecting a specific part of a subject like a face detection function.

は、第1の実施形態に係る撮像装置の内部構成を示すブロック図である。These are block diagrams which show the internal structure of the imaging device which concerns on 1st Embodiment. は、第1の実施形態に係る撮像装置の基本動作を説明するためのフローチャートである。These are the flowcharts for demonstrating the basic operation | movement of the imaging device which concerns on 1st Embodiment. は、領域に区分し顔領域を検出した、人物と背景からなる撮像画像の一例である。Is an example of a captured image composed of a person and a background, which is divided into regions and detects a face region. は、第1の実施形態に係る撮像装置のAFの最適化処理を説明するためのフローチャートである。These are the flowcharts for demonstrating the optimization process of AF of the imaging device which concerns on 1st Embodiment. は、顔検出装置の構成を示すブロック図である。These are block diagrams which show the structure of a face detection apparatus. は、縮小画像生成手段によって得られる階層画像の一例である。Is an example of a hierarchical image obtained by the reduced image generating means. は、顔検出処理を説明するための図である。FIG. 10 is a diagram for explaining face detection processing; は、領域に区分し顔領域を検出した、壁面上に掛けられた人物を含む写真からなる撮像画像の一例である。Is an example of a captured image made up of a photograph including a person hung on a wall surface, which is divided into regions and detects a face region. は、図8の画像の顔領域と検知領域のAF評価値と合焦距離との関係のグラフである。These are the graphs of the relationship between the AF evaluation value and the focus distance of the face area and detection area of the image of FIG. は、図3の画像の顔領域と検知領域のAF評価値と合焦距離との関係のグラフである。These are the graphs of the relationship between the AF evaluation value and the focus distance of the face area and detection area of the image of FIG. は、第1の実施形態に係るAFの最適化処理を説明するための、顔領域と分割領域全てのAF評価値と合焦距離との関係のグラフである。These are graphs of the relationship between the AF evaluation values and the focus distances of all face areas and divided areas, for explaining the AF optimization processing according to the first embodiment. は、第2の実施形態に係る撮像装置のAFの最適化処理を説明するためのフローチャートである。These are the flowcharts for demonstrating the optimization process of AF of the imaging device which concerns on 2nd Embodiment. は、第2の実施形態に係るAFの最適化処理を説明するための、顔領域と分割領域全てのAF評価値と合焦距離との関係のグラフである。These are graphs of the relationship between AF evaluation values and focus distances of all face areas and divided areas, for explaining AF optimization processing according to the second embodiment. は、人物と背景からなる撮像画像の一例である。Is an example of a captured image composed of a person and a background. は、図14の画像のAF評価値と合焦距離との関係のグラフである。These are graphs of the relationship between the AF evaluation value of the image of FIG. 14 and the in-focus distance. は、壁面上に掛けられた人物を含む写真からなる撮像画像の一例である。Is an example of a captured image composed of a photograph including a person hung on a wall surface. は、図16の画像のAF評価値と合焦距離との関係のグラフである。FIG. 17 is a graph showing the relationship between the AF evaluation value of the image of FIG. 16 and the in-focus distance.

符号の説明Explanation of symbols


1 イメージセンサ
2 レンズ部
3 AFE
4 マイク
5 画像処理部
6 音声処理部
7 圧縮処理部
8 ドライバ部
9 伸長処理部
10 ビデオ出力回路部
11 ビデオ出力端子
12 ディスプレイ部
13 音声出力回路部
14 音声出力端子
15 スピーカ部
16 タイミングジェネレータ
17 CPU
17a 距離情報記憶部
18 メモリ
19 操作部
20 バス回線
21 バス回線
22 外部メモリ
23 評価値算出部
40 顔検出装置
42 縮小画像生成手段
45 顔判定手段
46 検出結果出力手段
50 入力画像
51 縮小画像
52 縮小画像
53 縮小画像
54 縮小画像
55 縮小画像
61 判定領域
1
DESCRIPTION OF SYMBOLS 1 Image sensor 2 Lens part 3 AFE
4 microphone 5 image processing unit 6 audio processing unit 7 compression processing unit 8 driver unit 9 expansion processing unit 10 video output circuit unit 11 video output terminal 12 display unit 13 audio output circuit unit 14 audio output terminal 15 speaker unit 16 timing generator 17 CPU
17a Distance information storage unit 18 Memory 19 Operation unit 20 Bus line 21 Bus line 22 External memory 23 Evaluation value calculation unit 40 Face detection device 42 Reduced image generation means 45 Face determination means 46 Detection result output means 50 Input image 51 Reduced image 52 Reduction Image 53 Reduced image 54 Reduced image 55 Reduced image 61 Determination area

Claims (6)

合焦距離が変化可能であるレンズ部と、
前記レンズ部を通じて被写体が含まれる撮像画像を取得する撮像部と、
前記撮像画像から焦点合わせの評価値を算出する評価値算出部と、
を備え、
前記レンズ部において変化可能な範囲の合焦距離で取得した前記撮像画像の前記評価値が極大値となる位置に前記レンズ部の合焦位置を設定する撮像装置において、
前記撮像画像中から前記被写体の特定部分を検出する特定部分検出部を備え、
前記特定部分検出部で検出された前記特定部分の周囲に複数の検知領域を設定し、
前記被写体の特定部分を検出したとき、前記特定部分検出部における評価値の特性と、前記検知領域における評価値の特性とを比較し、前記特定部分の特性と類似した前記検知領域の数が所定の数以下であると、前記特定部分の大きさに対応した合焦距離に前記レンズ部を移動させてから合焦距離の設定動作を継続することを特徴とする撮像装置。
A lens unit whose focus distance can be changed;
An imaging unit that acquires a captured image including a subject through the lens unit;
An evaluation value calculation unit for calculating an evaluation value for focusing from the captured image;
With
In the imaging apparatus for setting the focusing position of the lens unit at a position where the evaluation value of the captured image acquired at a focusing distance in a range that can be changed in the lens unit is a maximum value,
A specific part detector for detecting a specific part of the subject from the captured image;
Set a plurality of detection areas around the specific part detected by the specific part detection unit,
When the specific part of the subject is detected, the characteristic of the evaluation value in the specific part detection unit is compared with the characteristic of the evaluation value in the detection area, and the number of the detection areas similar to the characteristic of the specific part is predetermined. The imaging apparatus is characterized by continuing the focusing distance setting operation after moving the lens unit to a focusing distance corresponding to the size of the specific portion.
前記特定部分の大きさから算出した合焦距離に前記レンズ部を合わせた後、前記特定部分における前記評価値に基づいて前記合焦距離の設定動作を継続することを特徴とする請求項1に記載の撮像装置。   The focus distance setting operation is continued based on the evaluation value in the specific portion after the lens unit is adjusted to the focus distance calculated from the size of the specific portion. The imaging device described. 前記撮像画像を複数の分割領域に分割する領域分割部を備え、
前記検知領域が、前期分割領域からなるとともに前記特定部分を含む前記分割領域と同じ形状であり、前記特定部分の上下左右の4箇所に設定されていることを特徴とする請求項1又は請求項2に記載の撮像装置。
An area dividing unit that divides the captured image into a plurality of divided areas;
2. The detection area according to claim 1, wherein the detection area is composed of a divided area in the previous period and has the same shape as the divided area including the specific part, and is set at four positions on the specific part. 2. The imaging device according to 2.
前記特定部分が、人物の顔であることを特徴とする請求項1〜3のいずれかに記載の撮像装置。   The imaging device according to claim 1, wherein the specific portion is a human face. 前記合焦距離の設定動作において、前記レンズ部の合焦距離を変化させる方向が、無限遠側から最近接距離側に向けてであることを特徴とする請求項1〜4のいずれかに記載の撮像装置。   5. The direction of changing the focusing distance of the lens unit in the focusing distance setting operation is from the infinity side toward the closest distance side. 6. Imaging device. 所定の合焦距離で前記レンズ部を通じて被写体が含まれる撮像画像を取得する第1のステップと、
前記撮像画像から焦点合わせの評価値を算出する第2のステップと、
前記撮像画像から被写体の特定部分を検出する第3のステップと、
前記特定部分の前記評価値の特性と、前記特定部分の周囲に設定した複数の検知領域の前記評価値の特性とを比較する第4のステップと、
前記第4のステップで比較した前記評価値の特性が、前記特定部分と類似した前記検知領域の個数を算出する第5のステップと、
前記第5のステップで算出した、前記評価値の特性が前記特定部分と類似した前記検知領域の個数が所定の数以下である場合に、前記第3のステップで検出した前記特定部分の大きさに対応した合焦距離に前記レンズ部を合わせる第6のステップと、
を備えることを特徴とする撮像方法。
A first step of acquiring a captured image including a subject through the lens unit at a predetermined focusing distance;
A second step of calculating an evaluation value for focusing from the captured image;
A third step of detecting a specific part of the subject from the captured image;
A fourth step of comparing the characteristic of the evaluation value of the specific part with the characteristic of the evaluation value of a plurality of detection regions set around the specific part;
A fifth step of calculating the number of the detection regions whose characteristics of the evaluation value compared in the fourth step are similar to the specific part;
The size of the specific portion detected in the third step when the number of the detection areas whose characteristics of the evaluation value calculated in the fifth step are similar to the specific portion is equal to or less than a predetermined number. A sixth step of adjusting the lens unit to a focusing distance corresponding to
An imaging method comprising:
JP2007183950A 2007-07-13 2007-07-13 Imaging device and method Withdrawn JP2009021893A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007183950A JP2009021893A (en) 2007-07-13 2007-07-13 Imaging device and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007183950A JP2009021893A (en) 2007-07-13 2007-07-13 Imaging device and method

Publications (1)

Publication Number Publication Date
JP2009021893A true JP2009021893A (en) 2009-01-29

Family

ID=40361109

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007183950A Withdrawn JP2009021893A (en) 2007-07-13 2007-07-13 Imaging device and method

Country Status (1)

Country Link
JP (1) JP2009021893A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100099011A (en) * 2009-03-02 2010-09-10 삼성전자주식회사 Method and apparatus for processing auto-focusing information, and digital photographing apparatus using thereof
WO2022130647A1 (en) * 2020-12-18 2022-06-23 富士通株式会社 Determination method, determination program, and information processing device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100099011A (en) * 2009-03-02 2010-09-10 삼성전자주식회사 Method and apparatus for processing auto-focusing information, and digital photographing apparatus using thereof
KR101581219B1 (en) 2009-03-02 2015-12-30 삼성전자주식회사 Method and apparatus for processing auto-focusing information and digital photographing apparatus using thereof
WO2022130647A1 (en) * 2020-12-18 2022-06-23 富士通株式会社 Determination method, determination program, and information processing device

Similar Documents

Publication Publication Date Title
JP4804398B2 (en) Imaging apparatus and imaging method
JP4674471B2 (en) Digital camera
US7916182B2 (en) Imaging device and method which performs face recognition during a timer delay
US9894280B2 (en) Imaging apparatus for displaying selected face in in-focus state and method for controlling imaging apparatus
US20130016245A1 (en) Imaging apparatus
JP2011166442A (en) Imaging device
JP2008109336A (en) Image processor and imaging apparatus
JP2008129554A (en) Imaging device and automatic focusing control method
TWI459126B (en) Image processing device capable of generating a wide-range image, image processing method and recording medium
US8988545B2 (en) Digital photographing apparatus and method of controlling the same
JP2007215091A (en) Imaging apparatus and program therefor
TW201301866A (en) Image processing device capable of generating wide-range image, image processing method, and recording medium
JP2008139683A (en) Imaging apparatus and autofocus control method
JP2009065573A (en) Imaging apparatus, focus control method, and focus control program
JP2009065587A (en) Voice-recording device and voice-reproducing device
US8189055B2 (en) Digital photographing apparatus and method of controlling the same
JP2009124644A (en) Image processing device, imaging device, and image reproduction device
KR20130031176A (en) Display apparatus and method
KR20120080376A (en) Digital image photographing apparatus and method for controlling the same
KR101630304B1 (en) A digital photographing apparatus, a method for controlling the same, and a computer-readable medium
JP2011066827A (en) Image processing apparatus, image processing method and program
JP4934617B2 (en) Imaging apparatus and imaging method
JP4806470B2 (en) Imaging device
JP2009021893A (en) Imaging device and method
JP4806471B2 (en) Imaging device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100701

A761 Written withdrawal of application

Free format text: JAPANESE INTERMEDIATE CODE: A761

Effective date: 20110706