JP2008053809A - Camera and subject area extracting method - Google Patents

Camera and subject area extracting method Download PDF

Info

Publication number
JP2008053809A
JP2008053809A JP2006225379A JP2006225379A JP2008053809A JP 2008053809 A JP2008053809 A JP 2008053809A JP 2006225379 A JP2006225379 A JP 2006225379A JP 2006225379 A JP2006225379 A JP 2006225379A JP 2008053809 A JP2008053809 A JP 2008053809A
Authority
JP
Japan
Prior art keywords
subject
area
camera
image
extraction
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2006225379A
Other languages
Japanese (ja)
Inventor
Kazuma Hosoi
一磨 細井
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 JP2006225379A priority Critical patent/JP2008053809A/en
Publication of JP2008053809A publication Critical patent/JP2008053809A/en
Pending legal-status Critical Current

Links

Images

Landscapes

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

Abstract

<P>PROBLEM TO BE SOLVED: To extract a subject area including a range-finding point from a photographed image. <P>SOLUTION: A camera determines photographic conditions, based on information regarding a previously set position in a field. The camera includes an imaging means for outputting an image of the field, an extracting means of extracting an area that includes the subject from the image, and a changing means of changing the extraction conditions of the extracting means, according to the number of positions, determining photographic conditions, in the area that includes the subject. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、測距位置や測光位置などの被写界内の所定位置において撮影条件を決定するカメラと、撮像画像の中から被写体領域を抽出する抽出方法に関する。   The present invention relates to a camera that determines shooting conditions at a predetermined position in a subject field such as a distance measurement position and a photometry position, and an extraction method that extracts a subject area from a captured image.

撮影前に被写界の画像を取得し、この画像における輝度分布に基づいて被写体の存在する部分を抽出し、その領域で焦点の検出を行うようにしたカメラが知られている(例えば、特許文献1参照)。   A camera is known in which an image of an object scene is acquired before shooting, a portion where a subject exists is extracted based on a luminance distribution in the image, and a focus is detected in that region (for example, a patent) Reference 1).

この出願の発明に関連する先行技術文献としては次のものがある。
特開2001−100087号公報
Prior art documents related to the invention of this application include the following.
Japanese Patent Laid-Open No. 2001-100087

しかしながら、上述した従来のカメラでは、輝度情報を用いて解析を行った結果、被写体として抽出された領域に測距点が1つも存在していない場合や、測距点が存在していても焦点検出が不能な場合がある。一方、被写体として抽出された領域内に測距点が多数存在した場合には、実際に焦点検出を行う測距点を決定するために別の判断手段を備えなければならないという問題もあった。   However, in the above-described conventional camera, as a result of analysis using luminance information, there is no focus point in the region extracted as the subject, or there is a focus point even if the focus point exists. Detection may not be possible. On the other hand, when there are many distance measuring points in the region extracted as the subject, there is a problem that another determination means must be provided in order to determine the distance measuring point for actual focus detection.

(1) 請求項1の発明は、被写界内の予め設定された位置に関する情報に基づいて撮影条件を決定するカメラであって、被写界の像を撮像して画像を出力する撮像手段と、画像から被写体を含む領域を抽出する抽出手段と、被写体を含む領域内の、撮影条件を決定する位置の数に応じて抽出手段の抽出条件を変更する変更手段とを備える。
(2) 請求項2のカメラは、抽出手段によって、被写体を含む領域と含まない領域とを弁別するようにしたものである。
(3) 請求項3のカメラは、撮影条件を決定する位置は焦点検出を行うための測距点に対応する位置であり、変更手段によって、抽出手段によって抽出される領域内に前記測距点がない場合、もしくは被写体を含む領域内の測距点で焦点検出不能な場合に、被写体を含む領域が拡大するように抽出条件を変更するようにしたものである。
(4) 請求項4のカメラは、撮影条件を決定する位置は焦点検出を行うための測距点に対応する位置であり、変更手段によって、被写体を含む領域内に測距点が所定数以上存在する場合は、抽出手段によって抽出される領域が縮小するように抽出条件を変更するようにしたものである。
(5) 請求項5のカメラは、撮影条件を決定する位置は測光を行うための測光点に対応する位置であり、変更手段によって、被写体を含む領域内に前記測光点がない場合、もしくは被写体を含む領域内の測光点で測光不能な場合に、抽出手段によって抽出される領域が拡大するように抽出条件を変更するようにしたものである。
(6) 請求項6のカメラは、撮影条件を決定する位置は測光を行うための測光点に対応する位置であり、変更手段によって、被写体を含む領域内に測光点が所定数以上存在する場合は、抽出手段によって抽出される領域が縮小するように抽出条件を変更するようにしたものである。
(7) 請求項7のカメラは、抽出手段によって、画像の端部の色相とこれに隣接する部分の色相とを比較し、両者の差がしきい値以上の部分を被写体を含む領域と判別し、変更手段によってしきい値を変更するようにしたものである。
(8) 請求項8のカメラは、抽出手段によって、画像の上端部、左端部および右端部それぞれの色相とこれらに隣接する部分の色相とを順次比較し、それらの差がしきい値以上の部分を被写体を含む領域と判別するようにしたものである。
(1) The invention of claim 1 is a camera that determines a shooting condition based on information relating to a preset position in the object scene, and that captures an image of the object scene and outputs the image. And an extracting means for extracting an area including the subject from the image, and a changing means for changing the extraction condition of the extracting means in accordance with the number of positions in the area including the subject for determining the photographing condition.
(2) The camera according to claim 2 is configured such that the area including the subject is distinguished from the area not including the subject by the extraction unit.
(3) In the camera according to claim 3, the position for determining the photographing condition is a position corresponding to the distance measuring point for performing focus detection, and the distance measuring point is within the region extracted by the extracting means by the changing means. If there is no focus, or if focus detection is impossible at a distance measuring point in the area including the subject, the extraction condition is changed so that the area including the subject is enlarged.
(4) In the camera according to claim 4, the position for determining the photographing condition is a position corresponding to a distance measuring point for performing focus detection, and the changing means includes a predetermined number or more of distance measuring points in the area including the subject. If it exists, the extraction condition is changed so that the area extracted by the extraction means is reduced.
(5) In the camera according to claim 5, the position for determining the photographing condition is a position corresponding to the photometric point for performing photometry, and when the photometric point is not present in the area including the subject by the changing means, or the subject The extraction condition is changed so that the area extracted by the extraction means is enlarged when the photometry is not possible at the photometry point in the area including.
(6) In the camera according to claim 6, the position for determining the photographing condition is a position corresponding to the photometric point for performing photometry, and the changing means has a predetermined number or more of photometric points in the area including the subject. Is to change the extraction condition so that the area extracted by the extraction means is reduced.
(7) The camera according to claim 7 compares the hue of the edge portion of the image with the hue of the adjacent portion by the extracting means, and determines that the difference between the two is equal to or greater than the threshold value as the region including the subject. The threshold value is changed by changing means.
(8) The camera according to claim 8 sequentially compares the hues of the upper end portion, the left end portion and the right end portion of the image with the hues of the adjacent portions by the extraction means, and the difference between them is equal to or greater than a threshold value. The portion is determined as an area including the subject.

本発明によれば、撮影画像の中から測距点を包含する被写体領域を抽出することができ、確実に焦点検出を行うことができる。   According to the present invention, a subject area including a distance measuring point can be extracted from a captured image, and focus detection can be reliably performed.

《発明の第1の実施の形態》
本発明を一眼レフレックスカメラに適用した一実施の形態を説明する。なお、本発明は一眼レフレックスカメラに限定されず、あらゆる種類のカメラに適用することができる。また、本発明はディジタルカメラはもちろんのこと、フィルムカメラにも適用できる。
<< First Embodiment of the Invention >>
An embodiment in which the present invention is applied to a single-lens reflex camera will be described. The present invention is not limited to a single-lens reflex camera, and can be applied to all types of cameras. The present invention can be applied not only to a digital camera but also to a film camera.

図1は第1の実施形態の構成を示すカメラの断面図である。図において、被写体からの光束は撮像レンズ101を透過した後、クイックリターンミラー102によって反射されてカメラの上方に導かれる。また、光束の1部はクイックリターンミラー102のハーフミラー部を透過し、サブミラー103によりカメラ下方へ反射される。   FIG. 1 is a cross-sectional view of a camera showing the configuration of the first embodiment. In the figure, a light beam from a subject passes through an imaging lens 101, is reflected by a quick return mirror 102, and is guided upward of the camera. Further, a part of the light beam passes through the half mirror part of the quick return mirror 102 and is reflected downward by the sub mirror 103.

クイックリターンミラー102でカメラの上方に反射された光束は、ファインダースクリーン104に結像する。結像した被写体像はペンタダハプリズム105を通り、その内の一部がエリアセンサ用再結像光学系106に導かれ、エリアセンサ107上に再結像される。エリアセンサ107は被写体からの光束を測定し、画像信号を演算装置108へ出力する。この画像信号については図2により詳細を後述する。演算装置108は不図示のマイクロコンピューターを備え、後述する方法により入力画像から被写体領域の抽出を行う。   The light beam reflected above the camera by the quick return mirror 102 forms an image on the finder screen 104. The formed subject image passes through the penta roof prism 105, and a part of the subject image is guided to the area sensor re-imaging optical system 106 and re-imaged on the area sensor 107. The area sensor 107 measures the light flux from the subject and outputs an image signal to the arithmetic device 108. Details of this image signal will be described later with reference to FIG. The arithmetic unit 108 includes a microcomputer (not shown), and extracts a subject area from an input image by a method described later.

サブミラー103によりカメラの下方へ反射された光束は、焦点検出装置109へ導かれる。焦点検出装置109は公知の方法を用いて撮影画面の複数の測距点で撮影レンズ101の焦点調節状態の検出を行い、焦点検出結果を演算装置108へ出力する。演算装置108は焦点検出結果に基づいて撮像レンズ101の焦点調節を行う。   The light beam reflected downward of the camera by the sub mirror 103 is guided to the focus detection device 109. The focus detection device 109 detects the focus adjustment state of the shooting lens 101 at a plurality of distance measuring points on the shooting screen using a known method, and outputs the focus detection result to the calculation device 108. The arithmetic unit 108 adjusts the focus of the imaging lens 101 based on the focus detection result.

なお、エリアセンサ107の位置はペンタダハプリズム105の上後部に限定されず、撮影が開始される以前に被写界からの光束を結像可能な場所であればどこでもよい。また、ディジタルカメラの場合には、エリアセンサ107の代わりに被写体像の撮像に用いる撮像素子を撮影前から動作させて画像を取得し、演算装置108へ出力するようにしてもよい。さらに、ディジタルカメラの場合は、撮像素子出力に基づいて演算装置により焦点検出が可能ならば、必ずしも焦点検出装置109を設ける必要はない。   Note that the position of the area sensor 107 is not limited to the upper rear part of the penta roof prism 105, and may be any place where a light beam from the object field can be imaged before shooting is started. In the case of a digital camera, instead of the area sensor 107, an image sensor used for capturing a subject image may be operated before photographing to obtain an image and output it to the arithmetic device 108. Further, in the case of a digital camera, the focus detection device 109 is not necessarily provided if the focus detection can be performed by the arithmetic device based on the output of the image sensor.

図2は撮像画像から被写体領域を抽出する画像処理方法を説明する図である。また、図3は第1の実施の形態のカメラの撮影動作を示すフローチャートである。図2を参照して第1の実施の形態の撮影動作を説明する。演算装置108のマイクロコンピューターはカメラの電源がオンされると、ステップ301から撮影動作を開始する。ステップ302で撮影者がカメラのレリーズスイッチ110を半押ししたか否かを確認し、半押ししたらステップ303へ進む。ステップ303ではエリアセンサ107から被写界の画像を取得する。   FIG. 2 is a diagram illustrating an image processing method for extracting a subject area from a captured image. FIG. 3 is a flowchart showing the photographing operation of the camera of the first embodiment. The photographing operation of the first embodiment will be described with reference to FIG. When the camera is turned on, the microcomputer of the arithmetic unit 108 starts the photographing operation from step 301. In step 302, it is confirmed whether or not the photographer has half-pressed the release switch 110 of the camera. In step 303, an image of the object scene is acquired from the area sensor 107.

図2(a)はエリアセンサ107が取得した画像の一例を示す。この実施形態では、エリアセンサ107の画素構成を横22画素、縦15画素とする。ステップ304において、エリアセンサ107により取得した画像から被写体領域を抽出するための演算を行う。   FIG. 2A shows an example of an image acquired by the area sensor 107. In this embodiment, the pixel configuration of the area sensor 107 is 22 horizontal pixels and 15 vertical pixels. In step 304, a calculation for extracting a subject area from an image acquired by the area sensor 107 is performed.

エリアセンサ107から取得した画像の横方向の座標をi、縦方向の座標をjとする。ここで、iのとる範囲は0〜21であり、jのとる範囲は0〜14である。また、エリアセンサ107の出力は画素ごとにRGBの3色の出力で構成されている。演算装置108はエリアセンサ107の各画素の色相を算出する。この一実施の形態では、算出した色相をHue[i][j]とする。   The horizontal coordinate of the image acquired from the area sensor 107 is i, and the vertical coordinate is j. Here, the range taken by i is 0-21, and the range taken by j is 0-14. The output of the area sensor 107 is composed of RGB three-color outputs for each pixel. The arithmetic unit 108 calculates the hue of each pixel of the area sensor 107. In this embodiment, the calculated hue is Hue [i] [j].

次に、ステップ305で演算装置108は画像の各列に対し次の条件式(1)を用いて背景マスクM1[i][j]の作成を行う。この演算は、画像を縦方向にスキャンして最外周画素と同様の画素に対して背景マスクを設定するものである。
ABS(Hue[i][j]−Hue[i][0])<ThHue ・・・(1)
(1)式において、ABSは入力された色相の差の絶対値を返す関数であり、ThHueは実験的に決定済みである判定用のしきい値である。条件式(1)を満たす場合には、さらに次に示す条件式(2)を用いて再度判定を行う。
M1[i][j−1]≠0 ・・・(2)
なお、上記演算はjの値が小さい方から大きい方へ向かう順、すなわち画像の上から下へ向かう順に行う。条件式(2)を満たす場合には、演算装置108はM1[i][j]をインクリメントする。なお、M1[i][j]の初期値は0である。ただし、画像の最外周にあたる画素については、背景マスクM1[i][j]の初期値を1とし、条件式(1)と(2)による判定を行わない。
Next, in step 305, the arithmetic unit 108 creates a background mask M1 [i] [j] for each column of the image using the following conditional expression (1). In this calculation, an image is scanned in the vertical direction, and a background mask is set for pixels similar to the outermost peripheral pixels.
ABS (Hue [i] [j] −Hue [i] [0]) <ThHue (1)
In equation (1), ABS is a function that returns the absolute value of the input hue difference, and ThHue is a threshold value for determination that has been experimentally determined. When the conditional expression (1) is satisfied, the determination is performed again using the following conditional expression (2).
M1 [i] [j-1] ≠ 0 (2)
The above calculation is performed in the order from the smallest j value to the largest value, that is, from the top to the bottom of the image. When the conditional expression (2) is satisfied, the arithmetic unit 108 increments M1 [i] [j]. Note that the initial value of M1 [i] [j] is zero. However, for the pixel corresponding to the outermost periphery of the image, the initial value of the background mask M1 [i] [j] is set to 1, and the determination based on the conditional expressions (1) and (2) is not performed.

図2(b)に上から下へ画像をスキャンして背景マスクの作成を行った後の画像を示す。図2(b)において、網掛け模様になっている画素は背景マスクM1[i][j]が0以外の画素、つまり背景としてマスクされた画素である。   FIG. 2B shows the image after the background mask is created by scanning the image from top to bottom. In FIG. 2 (b), pixels with a shaded pattern are pixels whose background mask M1 [i] [j] is other than 0, that is, pixels masked as the background.

次に、ステップ306と307でも同様の演算を行い、左右方向からの背景マスクを設定する。左方向からの背景マスクを作成する場合には、次の条件式(3)と(4)を用いる。
ABS(Hue[i][j]−Hue[0][j])<ThHue ・・・(3)
M2[i−1][j]≠0 ・・・(4)
左方向から画像をスキャンして背景マスクを作成する場合、iの値が小さい方から大きい方へ向かう順、すなわち画像の左から右に向かう順に演算を行う。左方向からの背景マスクM2[i][j]についても、上からのマスク同様に最外周を除いて初期値は0である。
Next, the same calculation is performed in steps 306 and 307 to set a background mask from the left and right directions. When creating a background mask from the left direction, the following conditional expressions (3) and (4) are used.
ABS (Hue [i] [j] −Hue [0] [j]) <ThHue (3)
M2 [i-1] [j] ≠ 0 (4)
When a background mask is created by scanning an image from the left direction, the calculation is performed in the order from the smallest i value to the largest, that is, from the left to the right of the image. For the background mask M2 [i] [j] from the left direction, the initial value is 0 except for the outermost periphery as in the mask from above.

右方向からの背景マスクについても同様に、次の条件式(5)と(6)を用いて背景マスクを作成する。
ABS(Hue[i][j]−Hue[22][j])<ThHue ・・・(5)
M3[i+1][j]≠0 ・・・(6)
右方向からスキャンして背景マスクを作成する場合、iの値が大きい方から小さい方へ向かう順、すなわち画像の右から左へ向かう順に演算を行う。この実施形態ではiの最大値は21である。右方向からの背景マスクM3[i][j]についても、上からのマスク作成時と同様に最外周を除いて初期値は0である。
Similarly, the background mask from the right direction is created using the following conditional expressions (5) and (6).
ABS (Hue [i] [j] −Hue [22] [j]) <ThHue (5)
M3 [i + 1] [j] ≠ 0 (6)
When the background mask is created by scanning from the right direction, the calculation is performed in the order from the larger i value to the smaller value, that is, from the right to the left of the image. In this embodiment, the maximum value of i is 21. Also for the background mask M3 [i] [j] from the right direction, the initial value is 0 except for the outermost periphery as in the mask creation from above.

図2(c)は左方向から背景マスクを作成した後の画像を、図2(d)は右方向から背景マスクを作成した後の画像を示す。図中に網掛け模様になっている画素は背景マスクM2[i][j]、M3[i][j]が0以外の画素、すなわち背景としてマスクされた画素である。   FIG. 2C shows an image after the background mask is created from the left direction, and FIG. 2D shows an image after the background mask is created from the right direction. In the figure, pixels in a shaded pattern are pixels whose background masks M2 [i] [j] and M3 [i] [j] are other than 0, that is, pixels masked as the background.

背景マスクの作成演算が終了した後のステップ308において、次式により最終的なマスクの厚さMask[i][j]を算出する。
Mask[i][j]=M1[i][j]+M2[i][j]+M3[i][j] ・・・(7)
図2(e)はマスクの厚さMask[i][j]を算出した後の画像の一例である。なお、この図では被写体(人物と自動車)の図示を省略する。図中に網掛け模様になっている画素は、マスクの厚さMask[i][j]が0以外の画素、すなわち背景としてマスクされた画素である。一方、マスク厚さMask[i][j]が0の画素は被写体が存在する領域(以下、被写体領域という)の画素である。
In step 308 after the background mask creation calculation is completed, the final mask thickness Mask [i] [j] is calculated by the following equation.
Mask [i] [j] = M1 [i] [j] + M2 [i] [j] + M3 [i] [j] (7)
FIG. 2E is an example of an image after the mask thickness Mask [i] [j] is calculated. In this figure, the illustration of the subject (person and car) is omitted. In the figure, the pixels in the shaded pattern are pixels whose mask thickness Mask [i] [j] is other than 0, that is, pixels masked as a background. On the other hand, a pixel having a mask thickness Mask [i] [j] of 0 is a pixel in an area where an object exists (hereinafter referred to as an object area).

次に、Mask[i][j]が0値をとる領域、すなわち被写体領域にある測距点において、焦点検出装置109により撮影レンズ101の焦点検出を行う。図2(f)に、これまでの演算で作成された背景マスク上に測距点を示した画像例を示す。図中の太い十字は撮影画面内に予め設定された測距点の位置を示す。この例では背景マスク以外の領域、すなわち被写体領域に測距点が存在する。   Next, the focus detection device 109 detects the focus of the photographing lens 101 in a region where Mask [i] [j] has a zero value, that is, a distance measuring point in the subject region. FIG. 2 (f) shows an example of an image showing distance measuring points on the background mask created by the above calculation. A thick cross in the figure indicates the position of a distance measuring point set in advance in the shooting screen. In this example, a distance measuring point exists in an area other than the background mask, that is, a subject area.

ステップ309で、マスクの厚さMask[i][j]=0の被写体領域に測距点が存在するかどうかを判別する。被写体領域に測距点が存在しない場合はステップ310へ進み、上記条件式(1)、(3)および(5)で用いたしきい値ThHueを再設定する。ここで、それまで設定されていた値よりも小さい値をしきい値ThHueに設定する。その後、ステップ305へ戻り、しきい値ThHueを変更した条件式(1)〜(6)によりふたたび背景マスクの作成を行う。   In step 309, it is determined whether or not there is a distance measuring point in the subject area of the mask thickness Mask [i] [j] = 0. If there is no distance measuring point in the subject area, the process proceeds to step 310 to reset the threshold ThHue used in the conditional expressions (1), (3) and (5). Here, a value smaller than the value set so far is set as the threshold value ThHue. Thereafter, the process returns to step 305, and a background mask is created again by the conditional expressions (1) to (6) in which the threshold value ThHue is changed.

ステップ309でマスクの厚さMask[i][j]=0の被写体領域に測距点が存在すると判別された場合にはステップ311へ進む。ステップ311では被写体領域における測距点において焦点検出装置109により撮影レンズ101の焦点検出を行い、焦点検出結果に基づいて撮影レンズ101の焦点調節を行った後、ステップ312でレリーズスイッチ110の全押し操作にしたがって撮影を行う。   If it is determined in step 309 that a distance measuring point is present in the subject area with the mask thickness Mask [i] [j] = 0, the process proceeds to step 311. In step 311, the focus detection device 109 detects the focus of the photographic lens 101 at a distance measuring point in the subject area, and after the focus of the photographic lens 101 is adjusted based on the focus detection result, the release switch 110 is fully pressed in step 312. Take pictures according to the operation.

なお、撮影者がカメラを縦位置に構えて撮影を行う場合には、図1に示す姿勢センサ111を用いてカメラの縦位置状態を検出し、エリアセンサ107による撮像画像の天地左右を正しく把握し、画像の下側からのスキャンを行わないように上述した制御内容を変更する。   When the photographer holds the camera in the vertical position and shoots, the vertical position of the camera is detected using the attitude sensor 111 shown in FIG. Then, the above-described control content is changed so as not to scan from the lower side of the image.

この第1の実施の形態によれば、抽出した被写体領域内に測距点がない場合には、被写体領域が拡大するように被写体領域の抽出条件を変更するようにしたので、撮影画像の中から測距点を包含する被写体領域を抽出することができ、確実に焦点検出を行うことができる。   According to the first embodiment, when there is no distance measuring point in the extracted subject area, the subject area extraction condition is changed so that the subject area is enlarged. The object region including the distance measuring point can be extracted from the image, and the focus detection can be reliably performed.

《発明の第2の実施の形態》
この第2の実施形態は、マスクの厚さMask[i][j]=0の被写体領域に測距点が存在する場合でも、被写体が低コントラストなどの理由で焦点検出不能とされた場合に、上記条件式(1)、(3)および(5)のしきい値ThHueを小さい値に変更し、背景マスクの設定領域を縮小する、つまり、被写体領域を拡大するものである。なお、この第2の実施の形態の構成は図1に示す構成と同様であり、図示と説明を省略する。
<< Second Embodiment of the Invention >>
In the second embodiment, even when a distance measuring point exists in the subject area with the mask thickness Mask [i] [j] = 0, the focus of the subject cannot be detected due to low contrast or the like. The threshold value ThHue in the conditional expressions (1), (3) and (5) is changed to a small value to reduce the background mask setting area, that is, to enlarge the subject area. The configuration of the second embodiment is the same as that shown in FIG. 1, and illustration and description thereof are omitted.

図4は第2の実施の形態のカメラの撮影動作を示すフローチャートである。なお、図3に示す処理と同様な処理を行うステップに対しては同一のステップ番号を付して相違点を中心に説明する。ステップ309で被写体領域に測距点が存在すると判別された場合に、ステップ401で被写体領域の測距点において焦点検出が不可能な否かを確認する。被写体領域の測距点において焦点検出が不可能な場合はステップ310へ進み、それまで設定されていた値よりも小さい値をしきい値ThHueに再設定し、ステップ305へ戻って上述した処理を繰り返す。   FIG. 4 is a flowchart showing the photographing operation of the camera of the second embodiment. Note that steps that perform the same processing as the processing shown in FIG. 3 are given the same step numbers, and differences will be mainly described. If it is determined in step 309 that a distance measuring point exists in the subject area, it is confirmed in step 401 whether or not focus detection is possible at the distance measuring point in the subject area. If focus detection is not possible at the distance measurement point in the subject area, the process proceeds to step 310, a value smaller than the value set so far is reset to the threshold value ThHue, and the process returns to step 305 to perform the above-described processing. repeat.

この第2の実施の形態によれば、抽出した被写体領域内の測距点で焦点検出不能な場合は、被写体領域が拡大するように被写体領域の抽出条件を変更するようにしたので、被写体領域内の測距点の数が増加し、これらのいずれかの測距点で焦点検出結果が得られる確率が高くなる。   According to the second embodiment, the subject area extraction condition is changed so that the subject area is enlarged when focus detection is impossible at the distance measuring point in the extracted subject area. The number of distance measuring points increases, and the probability of obtaining a focus detection result at any one of these distance measuring points increases.

《発明の第3の実施の形態》
この第3の実施形態は、被写体領域に測距点が多数存在する場合に、どの測距点で焦点検出を行うかを決定する操作または処理を省略するために、背景領域を拡大する、つまり被写体領域を縮小するものである。なお、この第3の実施の形態の構成は図1に示す構成と同様であり、図示と説明を省略する。
<< Third Embodiment of the Invention >>
In the third embodiment, when there are many distance measuring points in the subject area, the background area is enlarged in order to omit the operation or processing for determining the focus detection point at which distance detecting point. The object area is reduced. The configuration of the third embodiment is the same as that shown in FIG. 1, and illustration and description thereof are omitted.

図5は第3の実施の形態のカメラの撮影動作を示すフローチャートである。なお、図3に示す処理と同様な処理を行うステップに対しては同一のステップ番号を付して相違点を中心に説明する。ステップ501において、マスクの厚さMask[i][j]=0の被写体領域内に測距点が所定数よりも多く存在するか否かを判別する。被写体領域内の測距点が所定数よりも多い場合はステップ502へ進み、それまで設定されていた値よりも大きい値をしきい値ThHueに再設定し、ステップ305へ戻って上述した処理を繰り返す。   FIG. 5 is a flowchart showing the photographing operation of the camera of the third embodiment. Note that steps that perform the same processing as the processing shown in FIG. 3 are given the same step numbers, and differences will be mainly described. In step 501, it is determined whether or not there are more than a predetermined number of distance measuring points in the subject area having the mask thickness Mask [i] [j] = 0. If the number of distance measuring points in the subject area is greater than the predetermined number, the process proceeds to step 502, a value larger than the value set so far is reset to the threshold value ThHue, and the process returns to step 305 to perform the above-described processing. repeat.

この第3の実施の形態によれば、抽出した被写体領域内の測距点の数が所定数よりも多い場合は、被写体領域が縮小するように被写体領域の抽出条件を変更するようにしたので、被写体領域内の測距点の数を必要最小限の数とすることができ、多くの測距点の中から実際に焦点検出を行う測距点を決定する操作または処理を省くことができる。   According to the third embodiment, when the number of distance measuring points in the extracted subject area is larger than the predetermined number, the subject area extraction condition is changed so that the subject area is reduced. The number of distance measuring points in the subject area can be set to the minimum necessary number, and the operation or processing for determining the distance measuring points for actual focus detection from many distance measuring points can be omitted. .

《発明の第4の実施の形態》
上述した第1から第3の実施の形態では、撮影画面の上から下へ、左から右へ、さらに右から左へそれぞれスキャンして背景マスクM1、M2、M3を求め、さらにそれらの背景マスクM1〜M3を加算して被写体領域と背景領域を分別するようにした。この第4の実施の形態では、上述した実施の形態により被写体領域内に測距点が存在しないと判定された場合に、まず上から下へのスキャンによる背景マスクM1の作成を省き、左右方向の背景マスクM2とM3を加算して被写体領域と背景領域を分別する。上から下へのスキャンによる背景マスクM1が含まれない分だけ背景領域が縮小し、逆に被写体領域が拡大するので、被写体領域内に測距点が存在する確率が高くなる。
<< Fourth Embodiment of the Invention >>
In the first to third embodiments described above, the background masks M1, M2, and M3 are obtained by scanning from the top to the bottom of the shooting screen, from left to right, and further from right to left, respectively, and then the background masks. M1 to M3 are added to separate the subject area from the background area. In the fourth embodiment, when it is determined that there is no distance measuring point in the subject area according to the above-described embodiment, first, the creation of the background mask M1 by scanning from top to bottom is omitted, and the horizontal direction The background masks M2 and M3 are added to separate the subject area from the background area. Since the background area is reduced by the amount not including the background mask M1 from the top-to-bottom scan, and the subject area is enlarged, the probability that a distance measuring point exists in the subject area increases.

左右方向の背景マスクM2とM3により分別された被写体領域内に測距点が存在しない場合は、右から左へのスキャンによる背景マスクM3のみを用いて背景領域と被写体領域とを分別する。これにより、さらに被写体領域が拡大し、被写体領域内に測距点が存在する確率が高くなる。この第4の実施の形態では、背景マスクM1〜M3に基づいてマスクの厚さMask[i][j]を算出した回数をカウントするDepthという変数を用いる。   When there is no distance measuring point in the subject area sorted by the left and right background masks M2 and M3, the background area and the subject area are sorted using only the background mask M3 obtained by scanning from right to left. As a result, the subject area is further enlarged, and the probability that a distance measuring point exists in the subject area increases. In the fourth embodiment, a variable called Depth that counts the number of times the mask thickness Mask [i] [j] is calculated based on the background masks M1 to M3 is used.

この第4の実施の形態の構成は図1に示す構成と同様であり、図示と説明を省略する。図6は第4の実施の形態のカメラの撮影動作を示すフローチャートである。なお、図3に示す処理と同様な処理を行うステップに対しては同一のステップ番号を付して相違点を中心に説明する。ステップ601において変数Depthに初期値1を設定する。ステップ602で被写体領域に測距点が存在しないと判別された場合はステップ603〜605へ進み、背景マスクM1〜M3を0に初期化する。そして、ステップ606で変数Depthをインクリメントし、現在の変数Depthに応じて分岐する。   The configuration of the fourth embodiment is the same as the configuration shown in FIG. 1, and illustration and description thereof are omitted. FIG. 6 is a flowchart showing the photographing operation of the camera of the fourth embodiment. Note that steps that perform the same processing as the processing shown in FIG. 3 are given the same step numbers, and differences will be mainly described. In step 601, an initial value 1 is set to the variable Depth. If it is determined in step 602 that there is no distance measuring point in the subject area, the process proceeds to steps 603 to 605 to initialize the background masks M1 to M3 to zero. In step 606, the variable Depth is incremented, and the process branches according to the current variable Depth.

背景マスクM1〜M3に基づくマスクの厚さMask[i][j]を算出した回数Depthが2回の場合はステップ306へ戻り、画面の上から下へのスキャンによる背景マスクM1の作成を省略して左右方向のスキャンによる背景マスクM2とM3を作成し、それらの背景マスクM2とM3を加算してマスクの厚さMask[i][j]を求め、背景領域と被写体領域とを分別する。変数Depth=2の被写体領域にも測距点がない場合はふたたびステップ603〜605で背景マスクM1〜M3を初期化し、ステップ606で変数Depthをインクリメントする。今回は変数Depthが3になるのでステップ307へ戻り、右から左へのスキャンによる背景マスクM3のみを作成し、背景マスクM3により背景領域と被写体領域とを分別する。   If the number of times Depth for calculating the mask thickness Mask [i] [j] based on the background masks M1 to M3 is 2, the process returns to step 306, and the creation of the background mask M1 by scanning from the top to the bottom of the screen is omitted. Then, background masks M2 and M3 are created by scanning in the left-right direction, and the background masks M2 and M3 are added to obtain the mask thickness Mask [i] [j], and the background region and the subject region are separated. . If there is no distance measuring point in the subject area with the variable Dep = 2, the background masks M1 to M3 are initialized again at steps 603 to 605, and the variable Depth is incremented at step 606. Since the variable Depth is 3 this time, the process returns to step 307, where only the background mask M3 is created by scanning from right to left, and the background area and the subject area are separated by the background mask M3.

変数Depth=3の被写体領域にも測距点がない場合はふたたびステップ603〜605で背景マスクM1〜M3を初期化し、ステップ606で変数Depthをインクリメントする。今回は変数Depthが3を超えるのでステップ308へ戻る。ステップ308において、0に初期化された背景マスクM1〜M3を加算してマスクの厚さMask[i][j]を求めるが、この場合はもちろんマスクの厚さMask[i][j]は0であり、画面全範囲の画素のマスクの厚さMask[i][j]はすべて0になる。したがって、Mask[i][j]=0の被写体領域は撮影画面の全範囲とされる。ステップ602において、撮影画面の全範囲内にはもちろん測距点が存在するのでステップ311へ進み、上述したように測距と撮影を行う。   If there is no distance measuring point in the subject area of the variable Depth = 3, the background masks M1 to M3 are initialized again in steps 603 to 605, and the variable Depth is incremented in step 606. Since the variable Depth exceeds 3 this time, the process returns to Step 308. In step 308, the background masks M1 to M3 initialized to 0 are added to obtain the mask thickness Mask [i] [j]. In this case, of course, the mask thickness Mask [i] [j] is 0, and all mask thickness Mask [i] [j] of the pixels in the entire screen range are 0. Therefore, the subject area of Mask [i] [j] = 0 is the entire range of the shooting screen. In step 602, there are of course distance measuring points within the entire range of the photographing screen, so the process proceeds to step 311 to perform distance measuring and photographing as described above.

この第4の実施の形態によれば、複数の背景マスクを重ね合わせて分別した被写体領域内に測距点が存在しない場合には、重ね合わせる背景マスクの数を減らして被写体領域を分別し直し、背景領域を縮小し被写体領域を拡大していくようにしたので、被写体領域内に測距点が存在する確率が増し、確実に焦点検出を実行することができる。   According to the fourth embodiment, when there are no distance measuring points in the subject area obtained by superimposing a plurality of background masks, the subject areas are re-sorted by reducing the number of background masks to be superimposed. Since the background area is reduced and the subject area is enlarged, the probability that a distance measuring point exists in the subject area increases, so that focus detection can be reliably performed.

なお、上述した一実施の形態では被写界内の予め設定された焦点検出を行うための測距点を例に上げて説明したが、被写界内の予め設定された撮影条件を決定する位置は測距点に限定されず、測光を行うための測光点など、種々の撮影条件を決定する位置に適用することができる。   In the above-described embodiment, the range-finding point for detecting the focus set in advance in the object field has been described as an example. However, the image capturing condition set in the object field is determined. The position is not limited to a distance measuring point, and can be applied to a position where various shooting conditions are determined, such as a light measuring point for performing light metering.

第1の実施の形態の構成を示す図The figure which shows the structure of 1st Embodiment. 撮像画像から被写体領域を抽出する画像処理方法を説明する図The figure explaining the image processing method which extracts a to-be-photographed object area | region from a captured image 第1の実施の形態の撮影動作を示すフローチャートThe flowchart which shows the imaging | photography operation | movement of 1st Embodiment. 第2の実施の形態の撮影動作を示すフローチャートThe flowchart which shows the imaging | photography operation | movement of 2nd Embodiment. 第3の実施の形態の撮影動作を示すフローチャートFlowchart showing the photographing operation of the third embodiment 第4の実施の形態の撮影動作を示すフローチャートFlowchart showing the photographing operation of the fourth embodiment

符号の説明Explanation of symbols

107 エリアセンサ
108 演算装置
109 焦点検出装置
107 area sensor 108 arithmetic unit 109 focus detection unit

Claims (9)

被写界内の予め設定された位置に関する情報に基づいて撮影条件を決定するカメラであって、
前記被写界の像を撮像して画像を出力する撮像手段と、
前記画像から被写体を含む領域を抽出する抽出手段と、
前記被写体を含む領域内の、前記撮影条件を決定する位置の数に応じて前記抽出手段の抽出条件を変更する変更手段とを備えることを特徴とするカメラ。
A camera that determines shooting conditions based on information relating to a preset position in the scene,
Imaging means for capturing an image of the object scene and outputting the image;
Extraction means for extracting a region including a subject from the image;
A camera comprising: changing means for changing an extraction condition of the extraction means in accordance with the number of positions for determining the photographing condition in an area including the subject.
請求項1に記載のカメラにおいて、
前記抽出手段は、前記被写体を含む領域と含まない領域とを弁別することを特徴とするカメラ。
The camera of claim 1,
The camera according to claim 1, wherein the extracting means discriminates a region including the subject from a region not including the subject.
請求項1または請求項2に記載のカメラにおいて、
前記撮影条件を決定する位置は焦点検出を行うための測距点に対応する位置であり、
前記変更手段は、前記被写体を含む領域内に前記測距点がない場合、もしくは前記被写体を含む領域内の前記測距点で焦点検出不能な場合に、前記抽出手段によって抽出される領域が拡大するように前記抽出条件を変更することを特徴とするカメラ。
The camera according to claim 1 or 2,
The position for determining the photographing condition is a position corresponding to a distance measuring point for performing focus detection,
The changing means enlarges the area extracted by the extracting means when there is no ranging point in the area including the subject, or when focus detection is impossible at the ranging point in the area including the subject. The camera is characterized in that the extraction condition is changed.
請求項1〜3のいずれか1項に記載のカメラにおいて、
前記撮影条件を決定する位置は焦点検出を行うための測距点に対応する位置であり、
前記変更手段は、前記被写体を含む領域内に前記測距点が所定数以上存在する場合は、前記抽出手段によって抽出される領域が縮小するように前記抽出条件を変更することを特徴とするカメラ。
The camera according to any one of claims 1 to 3,
The position for determining the photographing condition is a position corresponding to a distance measuring point for performing focus detection,
The change means changes the extraction condition so that an area extracted by the extraction means is reduced when a predetermined number or more of distance measuring points exist in the area including the subject. .
請求項1または請求項2に記載のカメラにおいて、
前記撮影条件を決定する位置は測光を行うための測光点に対応する位置であり、
前記変更手段は、前記被写体を含む領域内に前記測光点がない場合、もしくは前記被写体を含む領域内の前記測光点で測光不能な場合に、前記抽出手段によって抽出される領域が拡大するように前記抽出条件を変更することを特徴とするカメラ。
The camera according to claim 1 or 2,
The position for determining the photographing condition is a position corresponding to a photometric point for performing photometry,
The changing means expands the area extracted by the extracting means when there is no photometric point in the area including the subject, or when photometry is not possible at the photometric point in the area including the subject. A camera characterized in that the extraction condition is changed.
請求項1、2、5のいずれか1項に記載のカメラにおいて、
前記撮影条件を決定する位置は測光を行うための測光点に対応する位置であり、
前記変更手段は、前記被写体を含む領域内に前記測光点が所定数以上存在する場合は、前記抽出手段によって抽出される領域が縮小するように前記抽出条件を変更することを特徴とするカメラ。
The camera according to any one of claims 1, 2, and 5,
The position for determining the photographing condition is a position corresponding to a photometric point for performing photometry,
The change means changes the extraction condition so that the area extracted by the extraction means is reduced when there are a predetermined number or more of photometry points in the area including the subject.
請求項1〜6のいずれか1項に記載のカメラにおいて、
前記抽出手段は、前記画像の端部の色相とこれに隣接する部分の色相とを比較し、両者の差がしきい値以上の部分を前記被写体を含む領域と判別し、
前記変更手段は、前記しきい値を変更することを特徴とするカメラ。
The camera according to any one of claims 1 to 6,
The extraction means compares the hue of the edge portion of the image with the hue of a portion adjacent thereto, and determines a portion where the difference between the two is a threshold value or more as a region including the subject,
The camera characterized in that the changing means changes the threshold value.
請求項7に記載のカメラにおいて、
前記抽出手段は、前記画像の上端部、左端部および右端部それぞれの色相とこれらに隣接する部分の色相とを順次比較し、それらの差がしきい値以上の部分を前記被写体を含む領域と判別することを特徴とするカメラ。
The camera according to claim 7, wherein
The extraction means sequentially compares the hues of the upper end portion, the left end portion and the right end portion of the image with the hues of portions adjacent thereto, and a portion where the difference is a threshold value or more is determined as an area including the subject. A camera characterized by discrimination.
被写界内の予め設定された位置に関する情報に基づいて撮影条件を決定するカメラの被写体領域抽出方法であって、
前記被写界の像を撮像した画像から抽出した被写体を含む領域内の、前記撮影条件を決定する位置の数に応じて前記抽出手段によって抽出する条件を変更することを特徴とする被写体領域抽出方法。
A method for extracting a subject area of a camera that determines a shooting condition based on information about a preset position in a scene,
Subject area extraction characterized by changing a condition to be extracted by the extraction means in accordance with the number of positions for determining the photographing condition in an area including a subject extracted from an image obtained by capturing an image of the object scene Method.
JP2006225379A 2006-08-22 2006-08-22 Camera and subject area extracting method Pending JP2008053809A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006225379A JP2008053809A (en) 2006-08-22 2006-08-22 Camera and subject area extracting method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006225379A JP2008053809A (en) 2006-08-22 2006-08-22 Camera and subject area extracting method

Publications (1)

Publication Number Publication Date
JP2008053809A true JP2008053809A (en) 2008-03-06

Family

ID=39237465

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006225379A Pending JP2008053809A (en) 2006-08-22 2006-08-22 Camera and subject area extracting method

Country Status (1)

Country Link
JP (1) JP2008053809A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101411215B1 (en) * 2012-09-04 2014-06-24 임석주 implant fixture manufacturing method
JP2020134538A (en) * 2019-02-12 2020-08-31 浜松ホトニクス株式会社 Image acquisition device and image acquisition method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101411215B1 (en) * 2012-09-04 2014-06-24 임석주 implant fixture manufacturing method
JP2020134538A (en) * 2019-02-12 2020-08-31 浜松ホトニクス株式会社 Image acquisition device and image acquisition method
JP7209557B2 (en) 2019-02-12 2023-01-20 浜松ホトニクス株式会社 Image acquisition device and image acquisition method

Similar Documents

Publication Publication Date Title
JP5167750B2 (en) TRACKING DEVICE, IMAGING DEVICE, AND TRACKING METHOD
EP2199978B1 (en) Image capturing apparatus having subject cut-out function
JP4894661B2 (en) Imaging device
JP2006211139A (en) Imaging apparatus
JP2009017155A (en) Image recognizing device, focus adjusting device and imaging apparatus
CN107959841B (en) Image processing method, image processing apparatus, storage medium, and electronic device
JP2010091669A (en) Imaging device
US6963376B2 (en) Distance measuring device and a camera provided with the distance measuring device
JP2019117395A (en) Imaging device
CN107547789B (en) Image acquisition device and method for photographing composition thereof
CN108289170B (en) Photographing apparatus, method and computer readable medium capable of detecting measurement area
WO2012147368A1 (en) Image capturing apparatus
JP2008053809A (en) Camera and subject area extracting method
JP5023750B2 (en) Ranging device and imaging device
JP2008042227A (en) Imaging apparatus
JP4670635B2 (en) Imaging device
CN114143421B (en) Dual-sensor camera system and calibration method thereof
JP5359150B2 (en) Imaging device
JP2009152725A (en) Automatic tracing apparatus and method
JP5018932B2 (en) Imaging device
JP2010016546A (en) Imaging device
KR101599434B1 (en) Space detecting apparatus for image pickup apparatus using auto focusing and the method thereof
JP4978129B2 (en) Exposure calculation device and camera
JP2008187332A (en) Image tracking device and image pickup device
JP2008187677A (en) Digital camera