JP5308386B2 - Imaging apparatus and control method thereof - Google Patents

Imaging apparatus and control method thereof Download PDF

Info

Publication number
JP5308386B2
JP5308386B2 JP2010066746A JP2010066746A JP5308386B2 JP 5308386 B2 JP5308386 B2 JP 5308386B2 JP 2010066746 A JP2010066746 A JP 2010066746A JP 2010066746 A JP2010066746 A JP 2010066746A JP 5308386 B2 JP5308386 B2 JP 5308386B2
Authority
JP
Japan
Prior art keywords
difference image
image data
difference
frame
region
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2010066746A
Other languages
Japanese (ja)
Other versions
JP2011199765A (en
Inventor
克俊 井澤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujifilm Corp
Original Assignee
Fujifilm 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 Fujifilm Corp filed Critical Fujifilm Corp
Priority to JP2010066746A priority Critical patent/JP5308386B2/en
Publication of JP2011199765A publication Critical patent/JP2011199765A/en
Application granted granted Critical
Publication of JP5308386B2 publication Critical patent/JP5308386B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

この発明は撮像装置およびその制御方法に関する。   The present invention relates to an imaging apparatus and a control method thereof.

画像データを用いた動体検出(抽出)処理として,連続するフレーム画像の差分を抽出して対象物(移動体)の輪郭線を生成するもの(特許文献1),輝度分布に基づいて顔向き角度を算出するもの(特許文献2)等が提案されている。   As moving object detection (extraction) processing using image data, a difference between successive frame images is extracted to generate an outline of an object (moving object) (Patent Document 1), and a face orientation angle based on a luminance distribution Has been proposed (Patent Document 2) and the like.

フレーム画像を用いて動体が動いた領域を検出する場合,その動体が低いコントラストのものであると,動体に動きがあったとしても差分が得られずに,動きがある領域であるにも関わらずその動きの検出できないことがある。   When a moving object is detected using a frame image, if the moving object has a low contrast, even if the moving object has a motion, a difference is not obtained. The movement may not be detected.

特開2008−203927号公報JP 2008-203927 A 特開2009−25894号公報JP 2009-25894 A

この発明は,低いコントラストの動体であっても,正確に動体領域を検出できるようにすることを目的とする。   An object of the present invention is to enable accurate detection of a moving object region even with a low contrast moving object.

この発明による撮像装置は,特定の撮像対象範囲を連続して撮像し,上記撮像対象範囲内の画像を表すフレーム画像データを順次出力する撮像手段,上記撮像手段から出力された複数のフレーム画像データのうち,先に出力された2つのフレーム画像データ間の差分を算出し,かつそれよりも後に出力された2つのフレーム画像データの差分を算出することによって,第1差分画像データおよび第2差分画像データを生成する差分画像データ生成手段,ならびに上記第1の差分画像データによって表される第1差分画像および第2の差分画像データによって表される第2差分画像に差異画像部分が含まれる場合に,上記第1差分画像に含まれる第1差異画像部分と,上記第2差分画像に含まれる第2差異画像部分とに包含される領域を検出する包含領域検出手段とを備え,前記包含領域を動体領域として検出することを特徴とする。   An imaging apparatus according to the present invention continuously captures a specific imaging target range, sequentially outputs frame image data representing an image within the imaging target range, and a plurality of frame image data output from the imaging unit. The first difference image data and the second difference are calculated by calculating a difference between the two previously output frame image data and calculating a difference between the two frame image data output after that. Difference image data generating means for generating image data, and a difference image portion included in the first difference image represented by the first difference image data and the second difference image represented by the second difference image data In addition, a region included in the first difference image portion included in the first difference image and the second difference image portion included in the second difference image is detected. A inclusion area detecting means, and detects the inclusion area as the moving object region.

この発明は上述の撮像装置の制御に適する方法の発明も提供する。この方法は,撮像手段が,あらかじめ定められた撮像対象範囲を連続して撮像し,上記撮像対象範囲内の画像を表すフレーム画像データを順次出力し,差分画像データ生成手段が,上記撮像手段から出力された複数のフレーム画像データのうち,先に出力された2つのフレーム画像データ間の差分を算出し,かつそれよりも後に出力された2つのフレーム画像データの差分を算出することによって,第1差分画像データおよび第2差分画像データを生成し,包含領域検出手段が,上記第1の差分画像データによって表される第1差分画像および第2の差分画像データによって表される第2差分画像に差異画像部分が含まれる場合に,上記第1差分画像に含まれる第1差異画像部分と上記第2差分画像に含まれる第2差異画像部分とに包含される領域を動体領域として検出するように撮像装置を制御する。   The present invention also provides a method invention suitable for controlling the above-described imaging apparatus. In this method, the imaging unit continuously captures a predetermined imaging target range, sequentially outputs frame image data representing an image within the imaging target range, and the difference image data generation unit receives the image from the imaging unit. By calculating a difference between two previously output frame image data out of a plurality of output frame image data and calculating a difference between two frame image data output after that, 1st difference image data and 2nd difference image data are produced | generated, and the inclusion area detection means represents the 1st difference image represented by the said 1st difference image data, and the 2nd difference image represented by 2nd difference image data Are included in the first difference image portion included in the first difference image and the second difference image portion included in the second difference image. Controlling the imaging device to detect the region as the moving object region.

この発明によると,第1差分画像および第2差分画像の2つの差分画像を表すデータが生成される。第1差分画像データの生成に用いられる2つのフレーム画像データは,連続して順次出力されるフレーム画像データのうち,先に(時間的に早いタイミングで)出力された2つのフレーム画像データであり,第2差分画像データの生成に用いられる2つのフレーム画像データは,それもよりも後に(時間的に遅いタイミングで)出力されたフレーム画像データであるから,動きのある被写体(動体)が撮像されると,第1差分画像および第2差分画像には,動き前(動きの途中を含む)および動き後(動きの途中を含む)の動体を表す画像,すなわち第1差異画像部分および第2差異画像部分がそれぞれに含まれる。   According to the present invention, data representing two difference images of the first difference image and the second difference image is generated. The two frame image data used for the generation of the first difference image data are the two frame image data output earlier (at an earlier timing) among the frame image data output sequentially and sequentially. The two frame image data used for generating the second difference image data is frame image data output later (at a later timing in time) than that, so that a moving subject (moving object) is imaged. Then, the first difference image and the second difference image include images representing moving bodies before movement (including the middle of movement) and after movement (including the middle of movement), that is, the first difference image portion and the second difference image. Each difference image portion is included.

第1差異画像部分および第2差異画像部分に包含される領域が動体領域として検出される。包含領域とは第1差異画像部分および第2差異画像部分自体のみならず,第1差異画像部分および第2差異画像部分の少なくとも一方に囲まれている領域,および第1差異画像部分と第2差異画像部分の間に挟まされている領域を含む。   A region included in the first difference image portion and the second difference image portion is detected as a moving object region. The inclusion region is not only the first difference image portion and the second difference image portion itself, but also an area surrounded by at least one of the first difference image portion and the second difference image portion, and the first difference image portion and the second difference image portion. An area sandwiched between the difference image portions is included.

この発明によると,第1差異画像部分および第2差異画像部分に包含される領域,すなわち,第1差異画像部分自体,第2差異画像部分自体,第1差異画像部分および第2差異画像部分の少なくとも一方に囲まれている領域,ならびに第1差異画像部分と第2大画像部分の間に挟まされている領域が動体領域として検出される。このため,動体のコントラストが低いために単純に差分をとるだけでは差(差分)を得ることができない領域があってもその領域も動体領域に含ませることができる。動体領域を正確に検出することができる。   According to the present invention, regions included in the first difference image portion and the second difference image portion, that is, the first difference image portion itself, the second difference image portion itself, the first difference image portion, and the second difference image portion. A region surrounded by at least one and a region sandwiched between the first difference image portion and the second large image portion are detected as moving object regions. For this reason, even if there is a region where a difference (difference) cannot be obtained simply by taking a difference because the contrast of the moving object is low, the region can be included in the moving object region. The moving object region can be accurately detected.

一実施態様では,上記差分画像データ生成手段は,連続する2つのフレーム画像データを用いて,上記第1差分画像データおよび第2差分画像データをそれぞれ生成するものである。動きの速い動体であっても動体領域を正確に検出することができる。   In one embodiment, the difference image data generation means generates the first difference image data and the second difference image data using two consecutive frame image data. A moving object region can be accurately detected even with a moving object that moves quickly.

好ましくは,上記撮像手段は上記撮像対象範囲を一定周期で撮像するものである。動体領域の検出を安定して行うことができる。   Preferably, the imaging means images the imaging target range at a constant period. The moving object region can be detected stably.

一実施態様では,上記包含領域検出手段は,上記第1差分画像および第2差分画像を重ね合わせた重ね合わせ差分画像を構成する複数の画素のそれぞれを起点にして,水平方向および垂直方向を含む複数の方向のそれぞれの方向をサーチすることによって,上記複数の画素のそれぞれが,第1差異画像部分および第2差異画像部分に包含されるかどうかを判断する。上記第1差異画像部分および第2差異画像部分によって包含される領域に含まれる画素は,水平方向および垂直方向を含む複数方向のサーチにおいて第1差異画像部分および第2差異画像部分が検出される。これに基づいて,上記第1差異画像自体および第2差異画像自体を構成する画素でなくても,第1差異画像部分および第2差異画像部分のいずれかによって囲まれている領域,ならびに第1差異画像部分および第2差異画像部分によって挟まれている画素も,包含領域を構成する画素として検出することができる。   In one embodiment, the inclusion area detection means includes a horizontal direction and a vertical direction starting from each of a plurality of pixels constituting a superimposed difference image obtained by superimposing the first difference image and the second difference image. By searching each direction of the plurality of directions, it is determined whether or not each of the plurality of pixels is included in the first difference image portion and the second difference image portion. For the pixels included in the region included by the first difference image portion and the second difference image portion, the first difference image portion and the second difference image portion are detected in a search in a plurality of directions including the horizontal direction and the vertical direction. . Based on this, even if it is not a pixel constituting the first difference image itself and the second difference image itself, the region surrounded by either the first difference image portion or the second difference image portion, and the first difference image portion Pixels sandwiched between the difference image portion and the second difference image portion can also be detected as pixels constituting the inclusion region.

好ましくは,上記包含領域検出手段は,上記第1差分画像および第2差分画像を重ね合わせた重ね合わせ差分画像において,上記第1差異画像部分の重心位置,および第2差異画像の重心位置をそれぞれ算出し,上記第1差異画像部分の重心位置を通る直線と上記第1差異画像部分の境界とが交わる2つの交点と,上記第2差異画像部分の重心位置を通る直線と上記第2差異画像部分の境界とが交わる2つの交点との位置関係に応じて,上記第1差異画像部分が第2差異画像部分に内包されていること,または第2差異画像部分が第1差異画像部分に内包されていることを判断する。動体が撮像装置に近づいている,または遠ざかっているときも,動体のコントラストが低いために単純に差分をとるだけでは差(差分)を得ることができない領域が生じる。この場合でも,上記第1差異画像部分が第2差異画像部分に内包されていること,または第2差異画像部分が第1差異画像部分に内包されていることを判断することによって,その領域を動体領域として検出することができる。   Preferably, the inclusion area detecting means determines the center of gravity position of the first difference image portion and the center of gravity of the second difference image in the superimposed difference image obtained by superimposing the first difference image and the second difference image, respectively. Two intersection points where the straight line passing through the center of gravity of the first difference image portion and the boundary of the first difference image portion intersect, the straight line passing through the center of gravity of the second difference image portion, and the second difference image are calculated. The first difference image portion is included in the second difference image portion or the second difference image portion is included in the first difference image portion according to the positional relationship with the two intersections where the boundary of the portion intersects. Judge that it has been. Even when the moving object is approaching or moving away from the imaging device, there is a region where the difference (difference) cannot be obtained simply by taking the difference because the contrast of the moving object is low. Even in this case, by determining that the first difference image portion is included in the second difference image portion or that the second difference image portion is included in the first difference image portion, the region is determined. It can be detected as a moving object region.

好ましくは,上記第1差分画像の生成に用いられた2つのフレーム画像データのうちの一方のフレーム画像データのみによって構成される第1差異画像部分中の第1領域の重心位置と,上記第1差分画像の生成に用いられた2つのフレーム画像データのうちの他方のフレーム画像データのみによって構成される第1差異画像部分中の第2領域の重心位置と,上記第2差分画像の生成に用いられた2つのフレーム画像データのうちの一方のフレーム画像データのみによって構成される第2差異画像部分中の第3領域の重心位置と,上記第2差分画像の生成に用いられた2つのフレーム画像データのうちの他方のフレーム画像データのみによって構成される第2差異画像部分中の第4領域の重心位置をそれぞれ算出し,第1領域の重心位置と第2領域の重心位置を結ぶ第1ベクトルの方向,および第3領域の重心位置と第4領域の重心位置を結ぶ第2ベクトルの方向に基づいて,動体の動きが直線的であるかどうかを判定する動体動き判定手段をさらに備えている。動体の動きが直線的でない場合には,4つのフレーム画像データから得られる2つの差分画像データを用いた動体領域の検出の精度が低下することがある。動体の動きが直線的ではないと判断された場合には,たとえば,4つのフレーム画像データ以上の多数のフレーム画像データのOR(論理和)領域をとることによって動体領域を検出することによって,動体領域の検出精度を高めることができる。   Preferably, the barycentric position of the first region in the first difference image portion constituted by only one frame image data of the two frame image data used for the generation of the first difference image, and the first difference image The centroid position of the second region in the first difference image portion constituted only by the other frame image data of the two frame image data used for generating the difference image, and used for generating the second difference image. The position of the center of gravity of the third region in the second difference image portion constituted by only one of the two frame image data obtained and the two frame images used for generating the second difference image The centroid position of the fourth area in the second difference image portion constituted only by the other frame image data of the data is calculated, and the centroid position of the first area and the second Whether the motion of the moving object is linear is determined based on the direction of the first vector connecting the center of gravity of the region and the direction of the second vector connecting the center of gravity of the third region and the center of gravity of the fourth region. A moving body motion determination means is further provided. If the motion of the moving object is not linear, the accuracy of detection of the moving object region using the two difference image data obtained from the four frame image data may be reduced. When it is determined that the motion of the moving object is not linear, for example, the moving object region is detected by taking an OR (logical sum) region of a large number of frame image data more than four frame image data. The detection accuracy of the area can be increased.

ディジタル・スチル・カメラの電気的構成を示すブロック図である。It is a block diagram which shows the electric constitution of a digital still camera. 第1実施例の動体領域検出処理の手順を示すフローチャートである。It is a flowchart which shows the procedure of the moving body area | region detection process of 1st Example. 動体領域検出処理の流れを画像によって示すものである。The flow of a moving body area | region detection process is shown with an image. 2つの差分画像の合成画像を示す。A composite image of two difference images is shown. 第2実施例の動体領域検出処理の手順を示すフローチャートである。It is a flowchart which shows the procedure of the moving body area | region detection process of 2nd Example. 第2実施例の動体領域検出処理の手順を画像によって示すものである。The procedure of the moving body area | region detection process of 2nd Example is shown with an image. 2つの差分画像の合成画像を示す。A composite image of two difference images is shown. 第3実施例の動体領域検出処理の手順を示すフローチャートである。It is a flowchart which shows the procedure of the moving body area | region detection process of 3rd Example. (A),(B)および(C)は第3実施例の動体領域検出処理の一部の手順を画像によって示すものである。(A), (B), and (C) show images of a part of the procedure of the moving object region detection process of the third embodiment.

図1は,この発明の実施例を示すもので,ディジタル・スチル・カメラ(撮像装置)の電気的構成を示すブロック図である。   FIG. 1 shows an embodiment of the present invention and is a block diagram showing an electrical configuration of a digital still camera (imaging device).

ディジタル・スチル・カメラの全体の動作はCPU31によって統括される。   The overall operation of the digital still camera is controlled by the CPU 31.

ディジタル・スチル・カメラには,ユーザからの操作に応じた制御を行う操作系制御装置も含まれている。ディジタル・スチル・カメラには,撮像モード,再生モードなどの動作モードを設定する動作モードスイッチ21,メニュー/OKボタン22,ズーム量等を設定する上下ボタン23,メニュー選択等のための左右ボタン24,BACKボタン25,表示装置55の表示を切り替える表示切替ボタン26,レリーズボタン27および電源スイッチ28が含まれている。これらのスイッチ等からの操作信号は,操作系制御装置30に入力する。   The digital still camera also includes an operation system control device that performs control in accordance with an operation from a user. The digital still camera has an operation mode switch 21 for setting an operation mode such as an imaging mode and a playback mode, a menu / OK button 22, an up / down button 23 for setting a zoom amount, and a left / right button 24 for menu selection. , BACK button 25, display switching button 26 for switching the display of display device 55, release button 27, and power switch 28. Operation signals from these switches and the like are input to the operation system control device 30.

ディジタル・スチル・カメラは,ストロボ撮像が可能であり,ストロボ撮像のためにストロボ(フラッシュライト)装置12およびストロボ制御装置13が含まれている。   The digital still camera can perform strobe imaging, and includes a strobe (flashlight) device 12 and a strobe control device 13 for strobe imaging.

また,ディジタル・スチル・カメラには,フォーカスレンズ駆動装置11によってレンズ位置が制御されるフォーカスレンズ1,ズームレンズ駆動装置10によってレンズ位置が制御されるズームレンズ2,絞り駆動装置9によって開口が制御される絞り3,およびシャッタ駆動装置8によって開閉制御されるシャッタ4も含まれている。シャッタ駆動装置8は,タイミング・ジェネレータ7から出力されるタイミング・パルスにもとづいて動作する。   The digital still camera has a focus lens 1 whose lens position is controlled by a focus lens driving device 11, a zoom lens 2 whose lens position is controlled by a zoom lens driving device 10, and an aperture controlled by a diaphragm driving device 9. A diaphragm 3 that is controlled to open and close by a shutter driving device 8 is also included. The shutter driving device 8 operates based on the timing pulse output from the timing generator 7.

動作モードスイッチ21によって撮像モードが設定されると,被写体像を表す光線束は,フォーカス・レンズ1,ズームレンズ2,絞り3およびシャッタ4を介してCCD5の受光面に入射する。CCD制御装置6によって制御されるCCD5から一定周期で被写体像を表す映像信号が出力される。CCD制御装置6は,タイミング・ジェネレータ7から出力されるタイミング・パルスにもとづいて動作する。   When the imaging mode is set by the operation mode switch 21, the light beam representing the subject image is incident on the light receiving surface of the CCD 5 through the focus lens 1, the zoom lens 2, the diaphragm 3 and the shutter 4. A video signal representing a subject image is output from the CCD 5 controlled by the CCD controller 6 at a constant period. The CCD controller 6 operates based on the timing pulse output from the timing generator 7.

CCD5から出力した映像信号は,タイミング・ジェネレータ7から出力されるタイミング・パルスにもとづいて動作するアナログ信号処理装置14に入力する。アナログ信号処理装置14においてガンマ補正,アナログ/ディジタル変換などの所定のアナログ信号処理が行われる。アナログ信号処理装置14から出力された画像データは,画像入力コントローラ15を介して表示制御装置54に入力する。表示制御装置54によって表示装置(モニタ)55が制御されることにより,撮像により得られた被写体像が表示装置55の表示画面に表示される。   The video signal output from the CCD 5 is input to the analog signal processing device 14 that operates based on the timing pulse output from the timing generator 7. The analog signal processing device 14 performs predetermined analog signal processing such as gamma correction and analog / digital conversion. The image data output from the analog signal processing device 14 is input to the display control device 54 via the image input controller 15. By controlling the display device (monitor) 55 by the display control device 54, a subject image obtained by imaging is displayed on the display screen of the display device 55.

画像入力コントローラ15から出力された画像データは,AF(自動合焦)処理装置42およびAE(自動露出)処理装置44にも入力する。AF処理装置42において,入力した画像データのコントラストにもとづいてフォーカス・レンズ1のレンズ位置が算出される。算出されたレンズ位置となるように,フォーカス・レンズ駆動装置11によってフォーカス・レンズ1が制御される。また,AF処理装置42において,算出されたレンズ位置にもとづいて被写体までの距離も算出される(測距手段)。もっとも被写体までの距離を測定する測距装置を設けてもよい。AE処理装置44において,入力した画像データにもとづいて被写体輝度が算出される(輝度測定手段)。算出された輝度にもとづいて,絞り3の絞り値およびシャッタ4のシャッタ速度が算出される。算出された絞り値となるように絞り駆動装置9によって絞り3が制御され,かつ算出されたシャッタ速度となるようにシャッタ駆動装置8によってシャッタ4が制御される。   The image data output from the image input controller 15 is also input to an AF (automatic focus) processing device 42 and an AE (automatic exposure) processing device 44. In the AF processing device 42, the lens position of the focus lens 1 is calculated based on the contrast of the input image data. The focus lens 1 is controlled by the focus lens driving device 11 so that the calculated lens position is obtained. In the AF processing device 42, the distance to the subject is also calculated based on the calculated lens position (ranging means). However, a distance measuring device that measures the distance to the subject may be provided. In the AE processing unit 44, the subject luminance is calculated based on the input image data (luminance measuring means). Based on the calculated luminance, the aperture value of the aperture 3 and the shutter speed of the shutter 4 are calculated. The diaphragm 3 is controlled by the diaphragm driving device 9 so as to obtain the calculated diaphragm value, and the shutter 4 is controlled by the shutter driving device 8 so as to obtain the calculated shutter speed.

画像入力コントローラ15から出力された画像データは,特定被写体検出装置56にも入力する。特定被写体検出装置56において,入力した画像データによって表される被写体像にたとえば顔画像が含まれているかどうかが検出される。顔画像等の特定被写体の検出は,たとえば,特定被写体を表す画像(たとえば顔画像)のサンプルを多数記憶しておき,記憶されている特定被写体画像と被写体像とのマッチング処理にもとづいて行われる。また,検出された特定被写体画像に枠を表示する枠表示装置49もディジタル・スチル・カメラに含まれている。   The image data output from the image input controller 15 is also input to the specific subject detection device 56. In the specific subject detection device 56, it is detected whether the subject image represented by the input image data includes, for example, a face image. Detection of a specific subject such as a face image is performed, for example, by storing a large number of samples of an image representing the specific subject (for example, a face image) and matching processing between the stored specific subject image and the subject image. . The digital still camera also includes a frame display device 49 that displays a frame on the detected specific subject image.

また,ディジタル・スチル・カメラには,特定の人物などの被写体像を表す画像データを登録しておく特定被写体登録装置46も含まれている。特定被写体登録装置46に登録されている被写体像が特定被写体認証装置47において認証されると,特定の被写体が撮像されたことが認証されることとなる。また,特定の被写体を追跡して撮像するための特定被写体追跡装置48も含まれている。   The digital still camera also includes a specific subject registration device 46 for registering image data representing a subject image of a specific person or the like. When the subject image registered in the specific subject registration device 46 is authenticated by the specific subject authentication device 47, it is authenticated that the specific subject has been captured. A specific subject tracking device 48 for tracking and capturing a specific subject is also included.

さらに,ディジタル・スチル・カメラには,撮像モード設定装置57が含まれている。この撮像モード設定装置57により設定された撮像モードにしたがって撮像制御装置41においてディジタル・スチル・カメラが制御される。   Further, the digital still camera includes an imaging mode setting device 57. In accordance with the imaging mode set by the imaging mode setting device 57, the digital still camera is controlled in the imaging control device 41.

撮像モードが設定されている場合に,レリーズ・ボタン27が押されると,上述のように,被写体が撮像されて被写体像を表す画像データがアナログ信号処理装置14から出力される。画像データは,画像入力コントローラ15を介して画像処理装置45において所定の画像処理が行われる。画像処理装置45から出力された画像データは,AWB(自動白バランス)処理装置43に入力し,白バランス調整が行われる。白バランス調整された画像データは,フレーム・メモリ51に与えられ,一時的に記憶される。画像データは,フレーム・メモリ51から読み出されて圧縮/伸長処理装置50に入力する。圧縮/伸長処理装置50において画像データが圧縮される。圧縮された画像データがメディア制御装置52によってメモリ・カードなどの外部記録メディア53に記録される。   If the release button 27 is pressed when the imaging mode is set, the subject is imaged and image data representing the subject image is output from the analog signal processing device 14 as described above. The image data is subjected to predetermined image processing in the image processing device 45 via the image input controller 15. The image data output from the image processing device 45 is input to an AWB (automatic white balance) processing device 43, and white balance adjustment is performed. The white balance adjusted image data is given to the frame memory 51 and temporarily stored. Image data is read from the frame memory 51 and input to the compression / decompression processor 50. The compression / decompression processing device 50 compresses the image data. The compressed image data is recorded on the external recording medium 53 such as a memory card by the media control device 52.

この実施例によるディジタル・スチル・カメラは,再生機能も有している。再生機能では,外部記録メディア53に記録されている圧縮画像データが圧縮/伸張処理装置50において伸張され,それが表示制御装置54に与えられることで画像表示される。   The digital still camera according to this embodiment also has a reproduction function. In the reproduction function, the compressed image data recorded on the external recording medium 53 is decompressed by the compression / expansion processing device 50, and is given to the display control device 54 to display an image.

図2は第1実施例の動体領域検出処理についてのディジタル・スチル・カメラの処理手順を示すフローチャートである。図3は図2に示す動体領域検出処理を具体的な画像によって説明するものである。   FIG. 2 is a flowchart showing the processing procedure of the digital still camera for the moving object region detection processing of the first embodiment. FIG. 3 explains the moving object region detection processing shown in FIG. 2 with a specific image.

レリーズボタン27が押下されることによって動体領域検出処理がスタートする(ステップ61でNO,ステップ61でYES )。   When the release button 27 is pressed, the moving object region detection process starts (NO in step 61, YES in step 61).

レリーズボタン27が押下されると,同一時間間隔で,Nフレーム(駒)の画像を表す画像データ,たとえば8フレーム分の画像データが連続して得られる(ステップ62)。得られた複数フレームの画像データはフレーム・メモリ51に一時的に記憶される。   When the release button 27 is pressed, image data representing an image of N frames (frames), for example, image data for 8 frames is continuously obtained at the same time interval (step 62). The obtained image data of a plurality of frames is temporarily stored in the frame memory 51.

以下の処理は,画像処理装置45において行われる,   The following processing is performed in the image processing device 45.

はじめに,フレームメモリ51に記憶されたNフレームの画像データのうち,最初の2フレーム分の画像データ(フレーム1とフレーム2),および最後の2フレーム分の画像データ(フレームN−1とフレームN)のそれぞれにおいて,差分(画素ごとの輝度データの差)が抽出(算出)され,2つのフレーム間差分画像データが生成される(ステップ63,64)。   First, among the N frames of image data stored in the frame memory 51, the first two frames of image data (frame 1 and frame 2) and the last two frames of image data (frame N-1 and frame N). ) Are extracted (calculated), and two inter-frame difference image data is generated (steps 63 and 64).

図3を参照して,たとえば,右向きに移動している動体Mを含む被写体を撮像することによって8つのフレーム画像(フレーム1〜フレーム8)が得られた場合,フレーム1とフレーム2との差分抽出によってフレーム間差分画像Sが得られ,かつフレーム7とフレーム8との差分抽出によってフレーム間差分画像Sが得られる。 Referring to FIG. 3, for example, when eight frame images (frame 1 to frame 8) are obtained by imaging a subject including moving object M moving rightward, the difference between frame 1 and frame 2 is obtained. An inter-frame difference image SF is obtained by the extraction, and an inter-frame difference image SL is obtained by extracting the difference between the frame 7 and the frame 8.

フレーム1とフレーム2から得られるフレーム間差分画像Sには動体Mを表す画像領域が含まれている。ここで,動体Mが全体的にコントラスト差がない(低コントラスト)ものである場合,フレーム1とフレーム2から得られるフレーム間差分画像Sは,次の四つの画像部分を含む。 The inter-frame difference image S F obtained from frames 1 and 2 includes an image region representing a moving object M. Here, when the moving body M is not likely overall contrast difference (low contrast), the inter-frame difference image S F obtained from frames 1 and 2, including the following four image portions.

第1の差異画像部分SF1:フレーム1にのみに存在する動体Mを表す画像部分である。 First difference image portion S F1 : An image portion representing the moving object M present only in the frame 1.

第2の差異画像部分SF2:フレーム2にのみ存在する動体Mを表す画像部分である。 Second difference image portion S F2 : An image portion representing the moving object M existing only in the frame 2.

差異非検出画像部分SF3:実際には動体Mが移動している画像部分であるが,動体Mが全体的にコントラスト差がないために差分を得ることができない画像部分である。 Difference non-detection image portion S F3 : An image portion in which the moving object M is actually moving, but an image portion in which the difference cannot be obtained because the moving object M has no overall contrast difference.

静止画像部分SF4:フレーム1にも,フレーム2にも,動体Mを表す画像部分が存在しない領域である。 Still image portion S F4 : This is a region where neither the frame 1 nor the frame 2 has an image portion representing the moving object M.

フレーム1とフレーム2との差分を単に算出するだけでは,差異非検出画像部分SF3に差分が現れないので,動体Mの動き領域の正確な抽出に失敗するおそれがある。 If the difference between the frame 1 and the frame 2 is simply calculated, the difference does not appear in the difference non-detected image portion SF3 , so that there is a possibility that accurate extraction of the motion region of the moving object M may fail.

フレーム7とフレーム8から得られるフレーム間差分画像Sについても,上述と同様に,第1の差異画像部分SL1,第2の差異画像部分SL2,差異非検出画像部分SL3および静止画像部分SL4を含む。フレーム7とフレーム8との差分を単に算出しても,差異非検出画像部分SL3に差分が現れず,したがって動体Mの動き領域の正確な抽出に失敗するおそれがある。 As for the inter-frame difference image S L obtained from the frames 7 and 8, the first difference image portion S L1 , the second difference image portion S L2 , the difference non-detection image portion S L3 and the still image are the same as described above. Includes portion SL4 . Even if the difference between the frame 7 and the frame 8 is simply calculated, the difference does not appear in the difference non-detected image portion S L3 , so that there is a possibility that the accurate extraction of the motion region of the moving object M may fail.

そこで,フレーム1とフレーム2から得られるフレーム間差分画像Sと,フレーム7とフレーム8から得られるフレーム間差分画像Sが用いられて,その両方に包含される領域(以下,包含領域という)を求める処理が行われる(ステップ65)。 Therefore, the inter-frame difference image S F obtained from the frame 1 and frame 2, are used inter-frame difference image S L obtained from the frame 7 and the frame 8, a region (hereinafter encompassed by both, that inclusion area ) Is performed (step 65).

図4を参照して,包含領域を求めるための処理(ステップ65)を説明する。図4は上述した2つのフレーム間差分画像SおよびSを重ね合わせた重ね合わせ画像である。重ね合わせ画像は,フレーム・メモリ51において2つのフレーム間差分画像SおよびSを位置合わせした画像である。もちろん,2つのフレーム間差分画像SおよびSを合成した画像を重ね合わせ画像として用いてもよい。 With reference to FIG. 4, the process (step 65) for obtaining the inclusion area will be described. Figure 4 is a superimposed image obtained by superimposing the difference image S F and S L between two frames as described above. Superimposed image is an image obtained by aligning the differential image S F and S L between two frames in the frame memory 51. Of course, it may be used as an image superimposing two inter-frame difference image S F and the image obtained by combining the S L.

包含領域算出処理では,2つのフレーム間差分画像S,Sに含まれる差異画像部分SF1,SF2,SL1,SL2に囲まれている画像部分が,包含領域として扱われる。図4を参照して,たとえば,画素Aを起点にして水平方向(左右方向),垂直方向(上下方向),斜め45度方向(右上方向および左下方向),ならびに斜め135度方向(左上方向および右下方向)に向けてスキャン(検索)が行われる。画素Aについては水平方向(左右方向),垂直方向(上下方向),2つの斜め方向のいずれについても,スキャンによって動体領域SF1,SF2,SL1,SL2を構成する画素が検出される(見つけられる)。画素Aは差異画像部分SF1,SF2,SL1,SL2に囲まれているので,包含領域を構成する画素と判断される。 In the inclusion area calculation process, the image part surrounded by the difference image parts S F1 , S F2 , S L1 , and S L2 included in the two inter-frame difference images S F and S L is treated as the inclusion area. Referring to FIG. 4, for example, starting from pixel A, the horizontal direction (left-right direction), the vertical direction (up-down direction), the diagonal 45 degree direction (upper right direction and lower left direction), and the oblique 135 degree direction (upper left direction and A scan (search) is performed toward the lower right). With respect to the pixel A, the pixels constituting the moving body regions S F1 , S F2 , S L1 , and S L2 are detected by scanning in any of the horizontal direction (left and right direction), vertical direction (up and down direction), and two oblique directions. (can be found). Since the pixel A is surrounded by the difference image portions S F1 , S F2 , S L1 , and S L2 , it is determined as a pixel constituting the inclusion region.

図4に示す画素Bを起点にして水平方向(左右方向),垂直方向(上下方向),2つの斜め方向に向けてスキャン(検索)が行われると,水平方向(左右方向),垂直方向(上下方向),2つの斜め方向のいずれのスキャンについても,動体領域SF1,SF2,SL1,SL2のいずれかを構成する画素が検出される(見つけられる)。画素Bも差異画像部分SF1,SF2,SL1,SL2に囲まれているので,包含領域を構成する画素と判断される。 When scanning (search) is performed in the horizontal direction (left-right direction), vertical direction (up-down direction), and two oblique directions starting from the pixel B shown in FIG. 4, the horizontal direction (left-right direction), vertical direction ( For both scans in the vertical direction and the two diagonal directions, pixels constituting any of the moving object regions S F1 , S F2 , S L1 , and S L2 are detected (found). Since the pixel B is also surrounded by the difference image portions S F1 , S F2 , S L1 , and S L2 , it is determined as a pixel constituting the inclusion region.

他方,画素Cについては,水平方向(左右方向)のスキャンにおいて動体領域SF1,SF2,SL1,SL2を構成する画素は全く検出されない。下方向,右下方向,右上方向および左下方向のスキャンにおいて,動体領域SF1,SF2,SL1,SL2を構成する画素は全く検出されない。画素Cについては差異画像部分SF1,SF2,SL1,SL2に囲まれていない,すなわち包含領域に含まれない画素と判断される。 On the other hand, for the pixel C, the pixels constituting the moving object regions S F1 , S F2 , S L1 , S L2 are not detected at all in the horizontal (left-right) scan. In the scans in the downward direction, the lower right direction, the upper right direction, and the lower left direction, the pixels constituting the moving object regions S F1 , S F2 , S L1 , and S L2 are not detected at all. The pixel C is determined not to be surrounded by the difference image portions S F1 , S F2 , S L1 , and S L2 , that is, not included in the inclusion region.

動体Mが直線的な動きをしている場合,包含領域を構成する画素(たとえば,画素A,画素B)は,水平方向(左右方向),垂直方向(上下方向),2つの斜め方向のいずれかのスキャンにおいて,動体領域SF1,SF2,SL1,SL2を構成する画素が検出される。他方,包含領域を構成しない画素は,水平方向(左右方向),垂直方向(上下方向),2つの斜め方向のいずれかのスキャンにおいて,動体領域SF1,SF2,SL1,SL2を構成する画素が検出されず,検出される方向があってもその反対方向のスキャンにおいて動体領域SF1,SF2,SL1,SL2を構成する画素が検出されない。たとえば,上述のように画素Cは水平方向(左右方向)のスキャンにおいて動体領域SF1,SF2,SL1,SL2を構成する画素が検出されず,また,上方向のスキャンにおいて動体領域SL2の画素が検出されるが,その反対方向(下方向)のスキャンにおいて動体領域SF1,SF2,SL1,SL2を構成する画素が検出されない。重ね合わせ画像を構成する画素のそれぞれについて上記のスキャンを行うことによって,各画素が包含領域を構成する画素であるかどうかを判断することができる。 When the moving body M is moving linearly, the pixels (for example, the pixel A and the pixel B) constituting the inclusion region are any one of the horizontal direction (left and right direction), the vertical direction (up and down direction), and two oblique directions. In such a scan, pixels constituting the moving object regions S F1 , S F2 , S L1 , S L2 are detected. On the other hand, pixels that do not constitute an inclusion area constitute moving object areas S F1 , S F2 , S L1 , and S L2 in one of scans in the horizontal direction (left and right direction), vertical direction (up and down direction), and two diagonal directions. Even if there is a direction to be detected, pixels constituting the moving object regions S F1 , S F2 , S L1 , and S L2 are not detected in the scan in the opposite direction. For example, as described above, in the pixel C, the pixels constituting the moving object areas S F1 , S F2 , S L1 , and S L2 are not detected in the horizontal (left and right) scan, and the moving object area S is detected in the upward scan. Although the pixel of L2 is detected, the pixels constituting the moving object regions S F1 , S F2 , S L1 , and S L2 are not detected in the scan in the opposite direction (downward). By performing the above scan for each of the pixels constituting the superimposed image, it is possible to determine whether each pixel is a pixel constituting the inclusion region.

図4に示す画素Aは,フレーム間差分画像SおよびSの両方において,実際には動体Mが移動している領域であるが,動体Mが全体的にコントラスト差がないために差分を得ることができない領域を構成する画素である。この領域(図3においてHで示す)も,包含領域を構成する画素として扱われることになる。画素Aが位置する領域Hは動体Mのエッジが全く通過していない領域であり,一般的な差分処理では差分画像として抽出されず,したがって動体が存在しない(静止領域)と判定されてしまう。しかしながら,上述のようにして包含領域を求めることによって,動体Mのエッジが全く通過していない領域Hも動体領域として扱うことができ,動体領域を正確に検出することができる。 Pixel A is shown in FIG. 4, in both the differential image S F and S L between frames, is a region that is actually moving body M is the difference to the moving body M is no overall contrast difference It is a pixel constituting an area that cannot be obtained. This region (indicated by H in FIG. 3) is also treated as a pixel constituting the inclusion region. The region H in which the pixel A is located is a region where the edge of the moving object M does not pass through at all, and is not extracted as a difference image in general difference processing, and therefore, it is determined that there is no moving object (still region). However, by obtaining the inclusion region as described above, the region H in which the edge of the moving object M does not pass at all can be handled as the moving object region, and the moving object region can be accurately detected.

包含領域の位置(画素位置)を特定するデータが,動体領域を表すデータとして出力される(ステップ66)。これにより,差異画像部分SF1,SF2,SL1,SL2を構成する画素のみならず,差異画像部分SF1,SF2,SL1,SL2に包含された画素(図4の画素A,画素B)も,動体領域を表すデータに含ませられる。 Data specifying the position (pixel position) of the inclusion area is output as data representing the moving object area (step 66). Thus, the difference image section S F1, S F2, S L1 , S L2 not only pixels constituting the difference image portion S F1, S F2, S L1 , S L2 pixels included in (the pixel of FIG. 4 A , Pixels B) are also included in the data representing the moving object region.

撮像によって得られたフレーム画像上において,たとえば,上記動体領域を表すデータによって特定される領域に枠を表示することによって,動体領域の位置を分かりやすく示すことができる。枠で囲まれた領域の画像データのみを記録(保存)すれば記憶装置の有効利用を図ることができる。防犯システム等において記憶装置を長期間にわたって使用することができるようになる。   On the frame image obtained by imaging, for example, by displaying a frame in an area specified by the data representing the moving object area, the position of the moving object area can be shown in an easily understandable manner. If only the image data in the area surrounded by the frame is recorded (saved), the storage device can be used effectively. The storage device can be used for a long time in a security system or the like.

図5は第2実施例の動体領域検出処理についてのディジタル・スチル・カメラの処理手順を示すフローチャートで,動体Mがディジタル・スチル・カメラに近づく方向に動いているときの処理を示している。図6は図5に示す動体領域検出処理を具体的な画像によって説明するものである。図5に示すフローチャートにおいて図2のフローチャートと同一処理には同一符号を付し,詳細な重複説明を省略する。   FIG. 5 is a flowchart showing the processing procedure of the digital still camera for the moving object region detection processing of the second embodiment, and shows processing when the moving object M is moving in the direction approaching the digital still camera. FIG. 6 explains the moving object region detection processing shown in FIG. 5 with a specific image. In the flowchart shown in FIG. 5, the same processes as those in the flowchart of FIG.

動体Mがディジタル・スチル・カメラの方向に近づいている場合も,最初の2フレーム分の画像データ(フレーム1とフレーム2),および最後の2フレーム分の画像データ(フレームN−1とフレームN)のそれぞれにおいて,差分(画素ごとの輝度データの差)が算出され,2つの差分画像データが生成される(ステップ63,64)。図6には,ディジタル・スチル・カメラに向かって近づく方向に移動している動体Mを含む被写体を撮像することによって5つのフレーム画像(フレーム1〜フレーム5)が得られた場合の画像例が示されている。フレーム1とフレーム2からフレーム間差分画像Sが得られ,かつフレーム4とフレーム5からフレーム間差分画像Sが得られる。 Even when the moving object M is approaching the direction of the digital still camera, the first two frames of image data (frames 1 and 2) and the last two frames of image data (frames N-1 and N) ), The difference (difference in luminance data for each pixel) is calculated, and two difference image data are generated (steps 63 and 64). FIG. 6 shows an example of an image when five frame images (frame 1 to frame 5) are obtained by capturing an object including a moving object M moving in a direction approaching the digital still camera. It is shown. Frame difference image S F from the frame 1 and frame 2 can be obtained, and the inter-frame difference image S L is obtained from the frame 4 and the frame 5.

フレーム1とフレーム2から得られるフレーム間差分画像Sと,フレーム4とフレーム5から得られるフレーム間差分画像Sとが用いられて,一方のフレーム間差分画像中の差異画像部分が,他方のフレーム間差分画像中の差異画像部分に包含(内包)されている領域を求める処理が行われる(図5のステップ67)。 And inter-frame difference image S F obtained from the frame 1 and the frame 2, the frame 4 and the inter-frame obtained from the frame 5 and the differential image S L is used, the difference image portion in the interframe difference images one frame, while A process for obtaining a region included (included) in the difference image portion in the inter-frame difference image is performed (step 67 in FIG. 5).

図7を参照して,第2実施例の包含領域算出処理(ステップ67)を説明する。図6に示す2つのフレーム間差分画像SおよびSを重ね合わせた重ね合わせ画像である。フレーム間差分画像Sにおける差異画像部分SF1の重心gから水平方向に伸ばした直線と差異画像部分SF1の境界の交点L,Rの座標が求められ,かつフレーム間差分画像Sにおける差異画像部分SL1の重心gから水平方向に伸ばした直線と差異画像部分SL1の境界の交点L,Rの座標が求められる。L座標およびR座標が,L座標およびR座標よりも内側領域の座標を表すものであれば,動体Mは近づく方向に移動しておりかつフレーム間差分画像Sにおける差異画像部分SF1がフレーム差分画像Sにおける差異画像部分SL1に包含(内包)されていると判断される。差異画像部分SF1によって包囲されている領域H(図6参照)は,動体Mのエッジが全く通過していない領域であり,一般的な差分処理では差分画像として抽出されず,したがって動体が存在しない(静止画像部分)と判定されてしまうが,この領域Hも包含領域と判断することができる。L座標およびR座標が,L座標およびR座標よりも内側領域の座標を表すものであれば,動体Mは遠ざかる方向に移動しており,フレーム間差分画像Sにおける差異画像部分SL1がフレーム差分画像Sにおける差異画像部分SF1に内包されていると判断される。 With reference to FIG. 7, the inclusion area calculation process (step 67) of the second embodiment will be described. It is two inter-frame difference image S F and superimposed image obtained by superimposing the S L shown in FIG. Frame difference image S difference image portion in the F S intersection from the center of gravity g 1 boundary lines and the difference image section S F1 which extended in the horizontal direction of F1 L 1, the R 1 coordinate is determined, and the inter-frame difference image S line and the difference image section S intersection L 2 boundary of L1 which extended from the center of gravity g 2 in the horizontal direction of the difference image portion S L1 in L, the coordinates of R 2 is determined. L 1 coordinates and R 1 coordinates, L 2 coordinate and as long as it represents the coordinates of the inner region than R 2 coordinate, the moving body M is the difference image portion in the difference image S F between and frame have been moved toward It is determined that S F1 is included (included) in the difference image portion S L1 in the frame difference image S L. The difference image portion S region is surrounded by F1 H (see FIG. 6), a region where an edge of the moving body M is not at all passed through, a general difference process is not extracted as a differential image, thus there are elements Although it is determined not to be performed (still image portion), this region H can also be determined as an inclusion region. L 2 coordinate and R 2 coordinates, as long as it than L 1 coordinates and R 1 coordinates representing the coordinates of the inner region, the moving body M is moved away, the difference image portion in the difference image S L between frames S L1 is determined to be included in the difference image section S F1 of frame difference image S F.

2つの動体領域SF1,SL1の重心g,gから水平方向に伸ばした直線ではなく,垂直方向に伸ばした直線を用いて,差異画像部分SF1,SL1の境界との交点座標を求めてもよい。動体Mがディジタル・スチル・カメラに近づく方向,または遠ざかる方向に動くものであることはあらかじめ分かっている場合には,2つの差異画像部分SF1,SL1の面積を単純に比較して,包含(内包)関係を判断してもよい。 Two moving object region S F1, rather than the straight line extended from the center of gravity g 1, g 2 of S L1 in the horizontal direction, with a straight line extending in the vertical direction, the difference image section S F1, the intersection coordinates of the boundary of S L1 You may ask for. If it is known in advance that the moving object M moves in a direction toward or away from the digital still camera, the areas of the two difference image portions S F1 and S L1 are simply compared and included. (Inclusive) relationship may be determined.

図8は撮影モードにおいて行われる第3実施例の動体領域検出処理についてのディジタル・スチル・カメラの処理手順を示すフローチャートである。図9(A)〜(C)は図8に示す動体領域検出処理におけるステップ69(動体が直線的な動きであるかどうかの判断)を具体的な画像によって説明するものである。図8に示すフローチャートにおいて図2のフローチャートと同一処理には同一符号を付し,詳細な重複説明を省略する。   FIG. 8 is a flowchart showing the processing procedure of the digital still camera for the moving object region detection processing of the third embodiment performed in the photographing mode. FIGS. 9A to 9C illustrate step 69 (determination as to whether or not the moving body is a linear motion) in the moving body region detection process shown in FIG. 8 with a specific image. In the flowchart shown in FIG. 8, the same processes as those in the flowchart of FIG.

動体Mが直線的な動きをするものであれば,図2に示す第1実施例の動体領域検出処理によって正確に動体領域を検出することができる。しかしながら,図9(A)に示すように(図9(A)ではフレーム画像1〜6が重ね合わされて示されている),動体Mが直線的な動きをしていず,一旦ある方向に動いて再び元の場所に戻ってくるような動きである場合,包含領域の検出が不正確になるおそれがある。図8に示す動体領域検出処理では,動体が直線的な動きであるかどうかが判断され,直線的な動きであると判断された場合には第1実施例(図2)の動体領域検出処理によって最初の2つのフレーム,および最後の2つのフレームを用いて動体領域を検出し,直線的な動きでないと判断された場合はすべてのフレーム画像のOR(論理和)領域を取ることによって動体領域を検出する。   If the moving object M moves linearly, the moving object region can be accurately detected by the moving object region detection process of the first embodiment shown in FIG. However, as shown in FIG. 9A (in FIG. 9A, the frame images 1 to 6 are overlapped), the moving object M does not move linearly and moves once in a certain direction. If the movement returns to the original location again, the detection of the inclusion area may be inaccurate. In the moving object region detection process shown in FIG. 8, it is determined whether or not the moving object has a linear motion, and if it is determined that the moving object has a linear motion, the moving object region detection process of the first embodiment (FIG. 2). Detects the moving object region using the first two frames and the last two frames, and if it is determined that the movement is not linear, takes the OR (logical sum) region of all the frame images. Is detected.

動体が直線的な動きをしているかどうかの判断(ステップ69)を,図9(A)〜(C)を参照して説明する。   The determination of whether or not the moving body is moving linearly (step 69) will be described with reference to FIGS.

最初の2フレームを用いてフレーム間差分画像Sを得,さらに最後の2フレームを用いてフレーム間差分画像Sを得るのは上述した第1実施例と同じである(ステップ63,64)。図9(A)〜(C)では6つのフレーム1〜6がフレームメモリ51記憶され,フレーム1および2を用いてフレーム間差分画像Sが得られ,フレーム5およびフレーム6が用いられてフレーム間差分画像Sが得られている。 The resulting difference image S F between the frames using the first two frames, further obtain a subtraction image S L between frames using the last two frames are the same as in the first embodiment described above (step 63, 64) . 9A to 9C, six frames 1 to 6 are stored in the frame memory 51, an inter-frame difference image SF is obtained using frames 1 and 2, and frames 5 and 6 are used to form a frame. A difference image SL is obtained.

上述したように,フレーム間差分画像Sは,フレーム1にのみ動体Mを表す画像部分が存在する第1の差異画像部分SF1と,フレーム2にのみに動体Mを表す画像部分が存在する第2の差異画像部分SF2を含む。この第1の差異画像部分SF1および第2の差異画像部分SF2のそれぞれの重心P,Pが算出され,重心Pから重心Pに向かうベクトル81が把握される(図9(B))。ベクトル81の向きは,先に撮像されて得られたフレーム1における重心P1から後に撮像されて得られたフレーム2における重心Pに向かう向きとされる。 As described above, the inter-frame difference image SF includes the first difference image portion SF1 in which the image portion representing the moving object M exists only in the frame 1 and the image portion representing the moving object M only in the frame 2. A second difference image portion SF2 is included. The centroids P 1 and P 2 of the first difference image portion S F1 and the second difference image portion S F2 are calculated, and a vector 81 from the centroid P 1 toward the centroid P 2 is grasped (FIG. 9 ( B)). Direction of the vector 81 is the direction toward the center of gravity P 2 in the frame 2 obtained being imaged after from the center of gravity P1 of the frame 1 obtained being imaged first.

同様にして,フレーム5およびフレーム6を用いて得られるフレーム間差分画像Sについても,第1の差異画像部分SL1および第2の差異画像部分SL2の重心Q,Qがそれぞれ算出され,QからQに向かうベクトル82が把握される(図9(C))。ベクトル向きは先に撮像されて得られたフレーム5における重心Qから,後に撮像されて得られたフレーム6おける重心Qに向かう向きとされる。 Similarly, for the inter-frame difference image S L obtained using the frame 5 and the frame 6, the centroids Q 5 and Q 6 of the first difference image portion S L1 and the second difference image portion S L2 are respectively calculated. Then, a vector 82 from Q 5 to Q 6 is grasped (FIG. 9C). Vector direction is the direction toward the center of gravity Q 6 from the center of gravity Q 5, after the definitive frame 6 obtained by imaging the frame 5 obtained by imaging first.

フレーム1およびフレーム2から得られたベクトル81と,フレーム5およびフレーム6から得られたベクトル82のなす角度θが所定の閾値θthを超えている場合,動体Mは直線的な動きをしていないと判断される(ステップ69でNO)。この場合には,すべてのフレーム1〜6のOR(論理和)演算を行うことによって動体領域が検出される(ステップ70)。OR演算によって得られる差異画像に囲まれる領域(包含領域)があれば,その包含領域も動体領域とされるのは第1実施例(図2)と同じである。   When the angle θ formed by the vector 81 obtained from the frames 1 and 2 and the vector 82 obtained from the frames 5 and 6 exceeds the predetermined threshold θth, the moving object M does not move linearly. (NO in step 69). In this case, the moving object region is detected by performing an OR (logical sum) operation on all the frames 1 to 6 (step 70). If there is an area (inclusion area) surrounded by the difference image obtained by the OR operation, the inclusion area is also set as a moving object area, as in the first embodiment (FIG. 2).

フレーム1およびフレーム2から得られたベクトル81と,フレーム5およびフレーム6から得られたベクトル82のなす角度θが所定の閾値θth以下である場合に,動体Mの動きは直線的な動きとして扱われる(ステップ69でYES )。この場合には第1実施例と同じ処理になる。   When the angle θ formed by the vector 81 obtained from the frames 1 and 2 and the vector 82 obtained from the frames 5 and 6 is equal to or smaller than a predetermined threshold θth, the motion of the moving object M is treated as a linear motion. (YES in step 69). In this case, the processing is the same as in the first embodiment.

5 CCD
27 レリーズボタン
45 画像処理装置
51 フレームメモリ
5 CCD
27 Release button
45 Image processing device
51 frame memory

Claims (8)

特定の撮像対象範囲を連続して撮像し,上記撮像対象範囲内の画像を表すフレーム画像データを順次出力する撮像手段,
上記撮像手段から出力された複数のフレーム画像データのうち,先に出力された2つのフレーム画像データ間の差分を算出し,かつそれよりも後に出力された2つのフレーム画像データの差分を算出することによって,第1差分画像データおよび第2差分画像データを生成する差分画像データ生成手段,ならびに
上記第1の差分画像データによって表される第1差分画像および第2の差分画像データによって表される第2差分画像に差異画像部分が含まれる場合に,第1差分画像に含まれる第1差異画像部分と上記第2差分画像に含まれる第2差異画像部分に包含される領域を検出する包含領域検出手段とを備え,
前記包含領域を動体領域として検出することを特徴とする
撮像装置。
Imaging means for continuously capturing a specific imaging target range and sequentially outputting frame image data representing an image in the imaging target range;
Of the plurality of frame image data output from the imaging means, the difference between the two previously output frame image data is calculated, and the difference between the two frame image data output after that is calculated. Thus, the difference image data generation means for generating the first difference image data and the second difference image data, and the first difference image and the second difference image data represented by the first difference image data. Inclusion region for detecting a region included in the first difference image portion included in the first difference image and a region included in the second difference image portion included in the second difference image when the difference image portion is included in the second difference image. Detecting means,
An imaging apparatus, wherein the inclusion area is detected as a moving object area.
上記差分画像データ生成手段は,連続する2つのフレーム画像データを用いて上記第1差分画像データおよび第2差分画像データをそれぞれ生成する,
請求項1に記載の撮像装置。
The difference image data generation means generates the first difference image data and the second difference image data using two consecutive frame image data,
The imaging device according to claim 1.
上記撮像手段は上記撮像対象範囲を一定周期で撮像する,
請求項1に記載の撮像装置。
The imaging means images the imaging target range at a constant period;
The imaging device according to claim 1.
上記差分画像データ生成手段は,上記レリーズボタンが押下された後に上記撮像手段から出力される複数のフレーム画像データのうちの,最初に出力された2つのフレーム画像データの差分を算出することによって第1差分画像データを作成し,かつ最後に出力された2つのフレーム画像データの差分を算出することによって第2差分画像データを作成する,
請求項1に記載の撮像装置。
The difference image data generation means calculates a difference between two frame image data output first among a plurality of frame image data output from the imaging means after the release button is pressed. Creating first difference image data and calculating second difference image data by calculating a difference between the two last output frame image data;
The imaging device according to claim 1.
上記包含領域検出手段は,上記第1差分画像および第2差分画像を重ね合わせた重ね合わせ画像を構成する複数の画素のそれぞれを起点にして,水平方向および垂直方向を含む複数の方向のそれぞれの方向をサーチすることによって,上記複数の画素のそれぞれについて,第1差異画像部分と第2差異画像部分に包含されるかどうかを判断する,
請求項1に記載の撮像装置。
The inclusion area detecting means starts from each of a plurality of pixels constituting a superimposed image obtained by superimposing the first difference image and the second difference image, and includes each of a plurality of directions including a horizontal direction and a vertical direction. By searching the direction, it is determined whether each of the plurality of pixels is included in the first difference image portion and the second difference image portion.
The imaging device according to claim 1.
上記包含領域検出手段は,上記第1差分画像および第2差分画像を重ね合わせた重ね合わせ差分画像において,上記第1差異画像部分の重心位置,および第2差異画像部分の重心位置をそれぞれ算出し,上記第1差異画像部分の重心位置を通る直線と上記第1差異画像部分の境界とが交わる2つの交点と,上記第2差異画像部分の重心位置を通る直線と上記第2差異画像部分の境界とが交わる2つの交点との位置関係に応じて,上記第1差異画像部分が第2差異画像部分に内包されていること,または第2差異画像部分が第1差異画像部分に内包されていることを判断する,
請求項1に記載の撮像装置。
The inclusion area detecting means calculates a center-of-gravity position of the first difference image part and a center-of-gravity position of the second difference image part in the superimposed difference image obtained by superimposing the first difference image and the second difference image, respectively. , Two intersection points where a straight line passing through the center of gravity of the first difference image portion and the boundary of the first difference image portion intersect, a straight line passing through the center of gravity of the second difference image portion, and the second difference image portion. The first difference image portion is included in the second difference image portion or the second difference image portion is included in the first difference image portion according to the positional relationship with the two intersections where the boundary intersects. To determine,
The imaging device according to claim 1.
上記第1差分画像の生成に用いられた2つのフレーム画像データのうちの一方のフレーム画像データのみによって構成される第1差異画像部分中の第1領域の重心位置と,上記第1差分画像の生成に用いられた2つのフレーム画像データのうちの他方のフレーム画像データのみによって構成される第1差異画像部分中の第2領域の重心位置と,上記第2差分画像の生成に用いられた2つのフレーム画像データのうちの一方のフレーム画像データのみによって構成される第2差異画像部分中の第3領域の重心位置と,上記第2差分画像の生成に用いられた2つのフレーム画像データのうちの他方のフレーム画像データのみによって構成される第2差異画像部分中の第4領域の重心位置をそれぞれ算出し,第1領域の重心位置と第2領域の重心位置を結ぶ第1ベクトルの方向,および第3領域の重心位置と第4領域の重心位置を結ぶ第2ベクトルの方向がなす角度に応じて,動体の動きが直線的であるかどうかを判定する動体動き判定手段をさらに備えた,
請求項6に記載の撮像装置。
The barycentric position of the first region in the first difference image portion constituted by only one of the two frame image data used for generating the first difference image, and the first difference image The centroid position of the second region in the first difference image portion constituted only by the other frame image data of the two frame image data used for generation, and 2 used for generation of the second difference image. The center of gravity position of the third region in the second difference image portion constituted by only one frame image data of the two frame image data, and the two frame image data used for generating the second difference image Centroid position of the fourth area in the second difference image portion constituted only by the other frame image data of the first area, respectively, and the centroid position of the first area and the centroid position of the second area A moving body that determines whether the movement of the moving body is linear according to the direction of the first vector that connects and the angle formed by the direction of the second vector that connects the center of gravity of the third region and the center of gravity of the fourth region Further comprising a motion determination means,
The imaging device according to claim 6.
撮像手段が,特定の撮像対象範囲を連続して撮像し,上記撮像対象範囲内の画像を表すフレーム画像データを順次出力し,
差分画像データ生成手段が,上記撮像手段から出力された複数のフレーム画像データのうち,先に出力された2つのフレーム画像データ間の差分を算出し,かつそれよりも後に出力された2つのフレーム画像データの差分を算出することによって,第1差分画像データおよび第2差分画像データを生成し,
包含領域検出手段が,上記第1の差分画像データによって表される第1差分画像および第2の差分画像データによって表される第2差分画像に差異画像部分が含まれる場合に,上記第1差分画像に含まれる第1差異画像部分と上記第2差分画像に含まれる第2差異画像部分に包含される領域を動体領域として検出する,
撮像装置の制御方法。
The imaging means continuously captures a specific imaging target range, sequentially outputs frame image data representing images within the imaging target range,
The difference image data generation means calculates a difference between two frame image data output earlier from among the plurality of frame image data output from the imaging means, and two frames output after that By calculating the difference between the image data, the first difference image data and the second difference image data are generated,
When the inclusion area detection means includes a difference image portion in the first difference image represented by the first difference image data and the second difference image represented by the second difference image data, the first difference A region included in the first difference image portion included in the image and the second difference image portion included in the second difference image is detected as a moving object region;
Control method of imaging apparatus.
JP2010066746A 2010-03-23 2010-03-23 Imaging apparatus and control method thereof Active JP5308386B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010066746A JP5308386B2 (en) 2010-03-23 2010-03-23 Imaging apparatus and control method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010066746A JP5308386B2 (en) 2010-03-23 2010-03-23 Imaging apparatus and control method thereof

Publications (2)

Publication Number Publication Date
JP2011199765A JP2011199765A (en) 2011-10-06
JP5308386B2 true JP5308386B2 (en) 2013-10-09

Family

ID=44877362

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010066746A Active JP5308386B2 (en) 2010-03-23 2010-03-23 Imaging apparatus and control method thereof

Country Status (1)

Country Link
JP (1) JP5308386B2 (en)

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3930504B2 (en) * 1998-01-07 2007-06-13 株式会社東芝 Object extraction device
JP3456972B2 (en) * 2001-01-18 2003-10-14 川崎重工業株式会社 MONITOR MONITORING METHOD AND DEVICE
JP5300433B2 (en) * 2007-11-22 2013-09-25 株式会社半導体エネルギー研究所 Image processing method and display device

Also Published As

Publication number Publication date
JP2011199765A (en) 2011-10-06

Similar Documents

Publication Publication Date Title
JP4478093B2 (en) Object image retrieval apparatus, digital camera, and control method thereof
JP6532217B2 (en) IMAGE PROCESSING APPARATUS, IMAGE PROCESSING METHOD, AND IMAGE PROCESSING SYSTEM
US9542754B2 (en) Device and method for detecting moving objects
EP2330812B1 (en) Apparatus for generating a panoramic image, method for generating a panoramic image, and computer-readable medium
KR102111935B1 (en) Display control apparatus, display control method, and program
KR101964861B1 (en) Cameara apparatus and method for tracking object of the camera apparatus
CN102959943A (en) Stereoscopic panoramic image synthesis device, image capturing device, stereoscopic panoramic image synthesis method, recording medium, and computer program
JP6577852B2 (en) Motion vector detection device and control method thereof
US10275917B2 (en) Image processing apparatus, image processing method, and computer-readable recording medium
US9774782B2 (en) Image pickup apparatus and image pickup method
JP5750551B2 (en) Apparatus and method for measuring distance of multiple subjects
JP5477777B2 (en) Image acquisition device
JP2007134845A (en) Camera controller and control program
US9420161B2 (en) Image-capturing apparatus
WO2005088962A1 (en) Tracking device and motion capture device
JP5308386B2 (en) Imaging apparatus and control method thereof
US20130076868A1 (en) Stereoscopic imaging apparatus, face detection apparatus and methods of controlling operation of same
JPH09145368A (en) Moving and tracing method for object by stereoscopic image
JP4877186B2 (en) Image processing apparatus, image processing method, and program
JP2018185576A (en) Image processing device and image processing method
JPH10126766A (en) Monitoring camera equipment
JP2009027437A (en) Image processor, image processing method and imaging device
JP6592881B2 (en) Surface detection method, surface detection device, and imaging device
JPH07324932A (en) Detection system of subject position and track
JP2017220834A (en) Imaging apparatus, imaging method and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20120606

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130605

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20130612

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130628

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 5308386

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250