JP2013157725A - Tracking device and tracking method - Google Patents
Tracking device and tracking method Download PDFInfo
- Publication number
- JP2013157725A JP2013157725A JP2012015486A JP2012015486A JP2013157725A JP 2013157725 A JP2013157725 A JP 2013157725A JP 2012015486 A JP2012015486 A JP 2012015486A JP 2012015486 A JP2012015486 A JP 2012015486A JP 2013157725 A JP2013157725 A JP 2013157725A
- Authority
- JP
- Japan
- Prior art keywords
- tracking
- area
- color
- comparison
- image
- 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.)
- Granted
Links
Images
Landscapes
- Exposure Control For Cameras (AREA)
- Studio Devices (AREA)
Abstract
Description
本発明は、被写体を追尾する追尾装置及び追尾方法に関する。 The present invention relates to a tracking device and a tracking method for tracking a subject.
一般に、動体を撮影する際や動画像を撮影する際に、特定の被写体に追従するように自動合焦制御(AF)や自動露光制御(AE)を行う技術が知られている。このような特定の被写体に追従するために追尾処理が用いられている。追尾処理には、輝度情報を利用するもの、色情報を利用するもの、顔検出を利用するもの等、種々のものがある。例えば特許文献1には、被写体の色情報に基づいて、被写体を追尾する技術が開示されている。例えば色情報に基づいて被写体を追尾する場合、追尾対象として設定された領域の色と類似する色が画像の中で探索される。 In general, a technique for performing automatic focusing control (AF) or automatic exposure control (AE) so as to follow a specific subject when shooting a moving body or shooting a moving image is known. Tracking processing is used to follow such a specific subject. There are various types of tracking processes, such as those using luminance information, those using color information, and those using face detection. For example, Patent Document 1 discloses a technique for tracking a subject based on the color information of the subject. For example, when tracking a subject based on color information, a color similar to the color of an area set as a tracking target is searched for in the image.
追尾対象である追尾被写体を色情報に基づいて追尾する際に、追尾被写体の周辺に追尾被写体と類似する色を有する非追尾被写体が出現すると、追尾対象が追尾被写体から非追尾被写体に移行し、非追尾被写体の追尾が開始され、追尾被写体が見失われる恐れがある。 When tracking a tracking subject that is a tracking target based on color information, if a non-tracking subject having a color similar to the tracking subject appears around the tracking subject, the tracking target shifts from the tracking subject to a non-tracking subject, Tracking of a non-tracking subject is started, and the tracking subject may be lost.
そこで本発明は、追尾被写体の周辺に追尾被写体の色と類似の色を有する被写体が存在しても、追尾被写体の追尾を継続できる追尾装置及び追尾方法を提供することを目的とする。 Accordingly, an object of the present invention is to provide a tracking device and a tracking method capable of continuing tracking of a tracking subject even when a subject having a color similar to the color of the tracking subject exists around the tracking subject.
前記目的を果たすため、本発明の一態様によれば、追尾装置は、画像を取得する画像取得部と、前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定する追尾領域設定部と、前記画像において所定の位置関係を有する少なくとも3つの領域を比較領域に設定する比較領域設定部と、前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択する類似色検出部と、前記更新領域に基づいて前記追尾領域を再設定する追尾領域更新を前記追尾領域設定部に実行させる追尾領域更新部と、を具備することを特徴とする。 In order to achieve the object, according to one aspect of the present invention, a tracking device sets an image acquisition unit that acquires an image, a partial area of the image as a tracking area, and tracks the color of the tracking area. A tracking region setting unit for setting a color, a comparison region setting unit for setting at least three regions having a predetermined positional relationship in the image as comparison regions, and a color most similar to the tracking color among the comparison regions A similar color detection unit that selects the comparison region as an update region, and a tracking region update unit that causes the tracking region setting unit to perform tracking region update that resets the tracking region based on the update region. It is characterized by.
前記目的を果たすため、本発明の別の一態様によれば、追尾装置は、画像を取得する画像取得部と、少なくも3つの比較領域の所定の位置関係をポイントテンプレートとして記憶するテンプレート記憶部と、前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定する追尾領域設定部と、前記画像において前記追尾領域の位置に基づいて前記ポイントテンプレートの位置を設定するテンプレート設定部と、設定された前記ポイントテンプレートの前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択する類似色検出部と、前記更新領域に基づいて前記追尾領域を再設定する追尾領域更新を前記追尾領域設定部に実行させる追尾領域更新部と、を具備することを特徴とする。 To achieve the above object, according to another aspect of the present invention, the tracking device includes an image acquisition unit that acquires an image, and a template storage unit that stores a predetermined positional relationship of at least three comparison regions as a point template. A tracking area setting unit that sets a part of the image as a tracking area and sets a color of the tracking area as a tracking color, and the position of the point template based on the position of the tracking area in the image. Based on the update region, a similar color detection unit that selects, as an update region, the comparison region having the color most similar to the tracking color among the comparison regions of the set point template And a tracking area updating unit that causes the tracking area setting unit to execute tracking area updating for resetting the tracking area.
前記目的を果たすため、本発明の一態様によれば、追尾方法は、画像を取得することと、前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定することと、前記画像において所定の位置関係を有する少なくとも3つの領域を比較領域に設定することと、前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択することと、前記更新領域に基づいて前記追尾領域を再設定することと、を具備することを特徴とする。 In order to achieve the above object, according to one aspect of the present invention, a tracking method includes acquiring an image, setting a partial area of the image as a tracking area, and setting the color of the tracking area to a tracking color. Setting, setting at least three regions having a predetermined positional relationship in the image as comparison regions, and selecting the comparison region having the color most similar to the tracking color as the update region among the comparison regions And resetting the tracking area based on the update area.
前記目的を果たすため、本発明の別の一態様によれば、追尾方法は、画像を取得することと、前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定することと、前記画像において前記追尾領域の位置に基づいて、少なくも3つの比較領域の所定の位置関係を有するポイントテンプレートの位置を設定することと、前記ポイントテンプレートの前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択することと、前記更新領域に基づいて前記追尾領域を再設定することと、を具備することを特徴とする。 To achieve the above object, according to another aspect of the present invention, a tracking method includes acquiring an image, setting a part of the image as a tracking region, and tracking the color of the tracking region. Setting a color, setting a position of a point template having a predetermined positional relationship among at least three comparison areas based on the position of the tracking area in the image, and setting the position of the comparison area of the point template. The comparison area having the color most similar to the tracking color is selected as an update area, and the tracking area is reset based on the update area.
本発明によれば、追尾被写体の周辺に追尾被写体の色と類似の色を有する被写体が存在しても、追尾被写体の追尾を継続できる追尾装置及び追尾方法を提供できる。 According to the present invention, it is possible to provide a tracking device and a tracking method capable of continuing tracking of a tracking subject even if a subject having a color similar to the color of the tracking subject exists around the tracking subject.
[第1の実施形態]
本発明の第1の実施形態について図面を参照して説明する。図1は、本実施形態に係る追尾装置を備えた撮像装置の構成の一例を示す図である。図1に示す撮像装置100は、撮影光学系102と、焦点調整機構104と、絞り106と、絞り駆動機構108と、シャッタ110と、シャッタ駆動機構112と、撮像素子114と、撮像素子インターフェイス(IF)回路116と、RAM118と、表示素子120と、表示素子駆動回路122と、タッチパネル124と、タッチパネル駆動回路126と、記録メディア128と、システムコントローラ130と、操作部132と、ROM134とを有している。
[First Embodiment]
A first embodiment of the present invention will be described with reference to the drawings. FIG. 1 is a diagram illustrating an example of a configuration of an imaging apparatus including a tracking device according to the present embodiment. An
撮影光学系102は、図示しない被写体からの光束Fを、撮像素子114の受光面上に集光するための光学系である。この撮影光学系102は、フォーカスレンズ等の複数のレンズを有している。また、撮影光学系102は、ズーム機構を有していてもよい。焦点調整機構104は、モータ及びその駆動回路等を有している。この焦点調整機構104は、システムコントローラ130内のCPU1301の制御に従って、撮影光学系102内のフォーカスレンズをその光軸方向(図示一点鎖線方向)に駆動させる。
The photographing
絞り106は、開閉自在に構成され、撮影光学系102を介して撮像素子114に入射する光束Fの量を調整する。絞り駆動機構108は、絞り106を駆動するための駆動機構を有している。この絞り駆動機構108は、システムコントローラ130内のCPU1301の制御に従って、絞り106を駆動させる。
The
シャッタ110は、撮像素子114の受光面を遮光状態又は露光状態とするように構成されている。このシャッタ110により、撮像素子114の露光時間が調整される。シャッタ駆動機構112は、シャッタ110を駆動させるための駆動機構を有し、システムコントローラ130内のCPU1301の制御に従って、シャッタ110を駆動させる。
The
撮像素子114は、撮影光学系102を介して集光された被写体からの光束Fが結像される受光面を有している。撮像素子114の受光面は、複数の画素が2次元状に配置されて構成されており、また、受光面の光入射側には、カラーフィルタが設けられている。このような撮像素子114は、受光面に結像された光束Fに対応した像(被写体像)を、その光量に応じた電気信号(以下、画像信号という)に変換する。ここで、撮像素子114としては、CCD方式やCMOS方式等の種々の構成の撮像素子が知られている。また、カラーフィルタの色配列としては、ベイヤ配列等の種々の配列が知られている。本実施形態は、撮像素子114の構成が特定の構成に限定されるものではない。したがって、種々の構成の撮像素子が用いられ得る。
The
撮像素子IF回路116は、システムコントローラ130内のCPU1301の制御に従って、撮像素子114を駆動させる。また、撮像素子IF回路116は、システムコントローラ130内のCPU1301の制御に従って、撮像素子114で得られた画像信号を読み出し、読み出した画像信号に対してCDS(相関二重サンプリング)処理やAGC(自動利得制御)処理等のアナログ処理を施す。さらに、撮像素子IF回路116は、アナログ処理した画像信号をデジタル信号(以下、画像データという)に変換する。
The image
表示素子120は、例えば液晶ディスプレイ(LCD)であり、ライブビュー用の画像及び記録メディア128に記録された画像等の各種の画像を表示する。表示素子駆動回路122は、システムコントローラ130のCPU1301から入力された画像データに基づいて表示素子120を駆動させ、表示素子120に画像を表示させる。
The
タッチパネル124は、表示素子120の表示画面上に一体的に形成されており、表示画面上へのユーザの指等の接触位置等を検出する。タッチパネル駆動回路126は、タッチパネル124を駆動するとともに、タッチパネル124からの接触検出信号をシステムコントローラ130のCPU1301に出力する。CPU1301は、接触検出信号から、ユーザの表示画面上への接触操作を検出し、その接触操作に応じた処理を実行する。
The
記録メディア128は、例えばメモリカードであり、撮影動作によって得られた画像ファイルが記録される。画像ファイルは、画像データに所定のヘッダを付与して構成されるファイルである。ヘッダには、撮影条件を示すデータ及び追尾位置を示すデータ等が、タグデータとして記録される。
The
システムコントローラ130は、撮像装置100の動作を制御するための制御回路として、CPU1301と、AF制御回路1302と、AE制御回路1303と、画像処理回路1304と、焦点距離取得回路1305と、追尾処理回路1306と、顔検出回路1307と、メモリ制御回路1308とを有している。
The
CPU1301は、焦点調整機構104、絞り駆動機構108、シャッタ駆動機構112、表示素子駆動回路122、タッチパネル駆動回路126等のシステムコントローラ130の外部の各ブロック、及びシステムコントローラ130の内部の各制御回路の動作を制御する。
The
AF制御回路1302は、コントラストAF処理を制御する。具体的には、AF制御回路1302は、撮像素子IF回路116で得られた画像データの高周波成分を抽出し、この抽出した高周波成分を積算することにより、AF用の合焦評価値を取得する。CPU1301は、この合焦評価値に従って画像データのコントラストを評価しつつ、焦点調整機構104を制御してフォーカスレンズを合焦状態とする。
The
AE制御回路1303は、AE動作を制御する。具体的には、AE制御回路1303は、撮像素子IF回路116で得られた画像データを用いて被写体輝度を算出する。CPU1301は、この被写体輝度に従って、露光時の絞り106の開口量(絞り値)、シャッタ110の開放時間(シャッタ速度値)、撮像素子感度やISO感度等を算出する。
The
画像処理回路1304は、画像データに対する各種の画像処理を行う。この画像処理としては、色補正処理、ガンマ(γ)補正処理、圧縮処理等が含まれる。また、画像処理回路1304は、圧縮されている画像データに対する伸張処理も施す。
The
焦点距離取得回路1305は、撮影光学系102がズーム機構を有する場合に設けられる。焦点距離取得回路1305は、撮影光学系102からその焦点距離を取得する。追尾処理回路1306は、後に詳述する本実施形態に係る追尾処理を実行する。追尾処理回路1306は、画像取得部13061と、追尾領域設定部13062と、色取得位置決定部13063と、類似色検出部13064と、追尾領域更新部13065と、信頼性判定部13066と、追尾色重心検索部13067とを有する。画像取得部13061は、例えば後述のRAM118から追尾対象である追尾被写体を含む画像を、追尾処理回路1306に取り込む。追尾領域設定部13062は、(N−1)フレーム目の画像において追尾被写体に追尾領域を設定する。色取得位置決定部13063は、追尾領域の位置を基準として複数の色取得位置を決定する。類似色検出部13064は、(N−1)フレーム目の画像における追尾領域の色である追尾色と、Nフレーム目の画像における色取得位置の各色とを比較し、最も色が類似している色取得位置を最類似色位置として選択する。追尾領域更新部13065は、追尾領域設定部13062に、最類似色位置に基づく位置をNフレーム目の画像における追尾領域に再設定させる。信頼性判定部13066は、追尾領域更新部13065による追尾領域の更新についての信頼性を判定する。これが繰り返されて追尾被写体の追尾が行われる。また、追尾色重心検索部13067は、従来の色追尾技術である追尾色重心検索を行う。すなわち、追尾色重心検索部13067は、例えば前のフレームの追尾領域の位置に基づいて決定されたサーチエリア内をラスタースキャンし、追尾色と同じ色情報を有する領域を検索し、その重心位置を決定する。
The focal
顔検出回路1307は、画像データにおける被写体(人物)の顔を検出する。ここで、顔検出処理について簡単に説明する。顔検出処理においては、各フレームで得られる画像データと、図2(a)に示すような顔パーツ402、404、406との相関量を求める。顔パーツ402は、人物の鼻部周辺の陰影のパターンに対応した画像データであり、顔パーツ404は、人物の目部周辺の陰影のパターンに対応した画像データであり、顔パーツ406は、人物の口部周辺の陰影のパターンに対応した画像データである。画像データと顔パーツ402、404、406との相関量は、図2(b)に示すような、人物の顔を示す所定の配置となったときに最大となる。このとき、顔パーツ402、404、406を含む領域408に顔が存在しているとする。なお、顔パーツ402、404、406は予め設定した検索顔の大きさに応じて、大きさを変えても良い。ここで、図2(b)では、顔領域を矩形領域としているが、円形領域としても良い。メモリ制御回路1308は、CPU1301等が、RAM118、記録メディア128、ROM134にアクセスするための制御を行うインターフェイスである。
The
操作部132は、ユーザによって操作される各種の操作部材である。操作部132としては、例えば、レリーズボタン、動画ボタン、モードダイヤル、選択キー、電源ボタン等が含まれる。レリーズボタンは、1stレリーズスイッチと、2ndレリーズスイッチとを有している。1stレリーズスイッチは、ユーザがレリーズボタンを半押しするとオンするスイッチである。1stレリーズスイッチがオンすることにより、AF処理等の撮影準備動作が行われる。また、2ndレリーズスイッチは、ユーザがレリーズボタンを全押しするとオンするスイッチである。2ndレリーズスイッチがオンすることにより、静止画撮影用の露光動作が行われる。動画ボタンは、動画撮影の開始又は終了を指示するための操作部材である。ユーザによって動画ボタンが押されると動画撮影処理が開始される。また、動画撮影処理の実行中に動画ボタンが押されると、動画撮影処理が終了される。
The
モードダイヤルは、撮像装置の撮影設定を選択するための操作部材である。本実施形態では、撮像装置の撮影設定として、例えば、静止画撮影モードと動画撮影モードを選択できる。静止画撮影モードは、静止画像を撮影するための撮影設定である。また、動画撮影モードは、動画像を撮影するための撮影設定である。選択キーは、例えばメニュー画面上での項目の選択や決定をするための操作部材である。ユーザによって選択キーが操作されるとメニュー画面上での項目の選択や決定が行われる。電源ボタンは、撮像装置の電源をオン又はオフするための操作部材である。ユーザによって電源ボタンが操作されると、撮像装置100が起動して動作可能な状態となる。撮像装置が起動している間に電源ボタンが操作されると、撮像装置100が省電力待機状態となる。
The mode dial is an operation member for selecting shooting settings of the imaging apparatus. In the present embodiment, for example, a still image shooting mode and a moving image shooting mode can be selected as shooting settings of the imaging apparatus. The still image shooting mode is a shooting setting for shooting a still image. The moving image shooting mode is a shooting setting for shooting a moving image. The selection key is an operation member for selecting or determining an item on the menu screen, for example. When the selection key is operated by the user, an item is selected or determined on the menu screen. The power button is an operation member for turning on or off the power of the imaging apparatus. When the power button is operated by the user, the
ROM134は、CPU1301が種々の処理を実行するためのプログラムコードを記憶している。また、ROM134は、撮影光学系102、絞り106、及び撮像素子114等の動作に必要な制御パラメータ、並びに画像処理回路1304での画像処理に必要な制御パラメータ等の、各種の制御パラメータを記憶している。さらに、ROM134は、顔検出回路1307における顔検出に用いられる顔パーツのデータや追尾枠を表示するためのデータ等も記憶している。
The
RAM118は、例えばSDRAMであり、ワークエリア、追尾画像エリア、追尾色ログエリア及び追尾データログエリアを記憶エリアとして有している。ワークエリアは、撮像素子IF回路116で得られた画像データ等の、撮像装置100の各部で発生したデータを一時記憶しておくためにRAM118に設けられた記憶エリアである。追尾画像エリアは、追尾画像データを一時記憶しておくためにRAM118に設けられた記憶エリアである。追尾画像データは、追尾処理における追尾被写体を含む画像のデータである。追尾処理においては、この追尾画像データが用いられる。追尾色ログエリアは、追尾処理において、追尾領域の色情報である追尾色を一時記憶しておくためにRAM118に設けられた記憶エリアである。追尾処理においては、追尾色ログエリアに記憶された追尾色と、色取得位置の色とが比較されて最類似色位置が選定される。追尾データログエリアは、追尾データログを一時記憶しておくためにRAM118に設けられた記憶エリアである。追尾データログは、追尾処理の結果として得られた追尾位置を記録したログである。
The
次に、本実施形態に係る撮像装置の動作について説明する。撮像装置100の撮影動作を示すフローチャートを図3に示す。CPU1301は、ROM134から必要なプログラムコードを読み込んで図3の動作を制御する。
Next, the operation of the imaging apparatus according to the present embodiment will be described. A flowchart showing the photographing operation of the
CPU1301は、ステップS100において現在の撮像装置100の撮影設定が静止画撮影モードであるか否かを判定する。前述のとおり、撮影設定は、モードダイヤルによって設定される。ステップS100において撮影設定が静止画撮影モードであると判定された場合、CPU1301は、ステップS102においてライブビュー動作を開始させる。このライブビュー動作において、CPU1301は、シャッタ駆動機構112を制御してシャッタ110を開放した後、撮像素子IF回路116を制御して撮像素子114に撮像を開始させる。その後、CPU1301は、撮像素子114による撮像の結果としてRAM118のワークエリアに記憶された画像データを画像処理回路1304に入力する。画像処理回路1304は、入力された画像データに対してライブビュー表示用の画像処理を施す。続いて、CPU1301は、ライブビュー表示用の画像処理が施された画像データを表示素子駆動回路122に入力し、表示素子120に画像を表示させる。このような表示動作が繰り返し実行されることで、表示素子120に被写体の画像が動画表示される。ユーザは、この動画表示によって被写体を観察することが可能である。
In step S100, the
CPU1301は、ステップS104において1stレリーズスイッチがオンされたか否かを判定する。ステップS104において1stレリーズスイッチがオンされたと判定されるまで、CPU1301は、ライブビュー動作を継続する。
The
ステップS104において1stレリーズスイッチがオンされたと判定された場合、CPU1301は、ステップS106においてレリーズAF処理を行う。レリーズAF処理において、CPU1301は、スキャン駆動によってフォーカスレンズを合焦位置まで駆動させる。スキャン駆動において、CPU1301は、焦点調整機構104を制御してフォーカスレンズを所定のスキャン範囲内で一方向に駆動させつつ、AF制御回路1302に合焦評価値を順次算出させる。CPU1301は、合焦評価値に基づいて合焦を評価する。CPU1301は、合焦評価値が最大となるレンズ位置において、フォーカスレンズの駆動を停止させる。このようなスキャン駆動は、AF前のフォーカスレンズの位置と合焦位置との差が大きい場合に行われる。
If it is determined in step S104 that the first release switch has been turned on, the
CPU1301は、ステップS108において追尾領域を設定し、表示素子駆動回路122を制御して表示素子120に追尾枠を表示させる。ここで、例えば、レリーズAFで合焦した被写体が追尾被写体として設定され得る。また、顔検出回路1307によって顔が検出された場合、その顔が追尾被写体として設定され得る。さらに、タッチパネル124により表示素子120の画面上に表示された被写体が指定された場合、その被写体が追尾被写体として設定され得る。追尾被写体のうちこれら設定された追尾する領域を追尾領域と称することにする。この追尾領域は1画素でもよいし、複数画素でもよい。追尾領域を1画素など比較的狭い領域とする場合に、本実施形態は特に効果を奏する。また、CPU1301は、追尾領域を含み、追尾領域の色情報との差異が所定の閾値以下である色情報を有する矩形領域を探索し、この領域を同色領域として設定する。
In step S108, the
CPU1301は、表示素子駆動回路122を制御して表示素子120に追尾領域を表す追尾枠を表示させる。追尾枠は、追尾領域を重心とする四角形の枠でもよいし、同色領域を表す枠でもよい。すなわち、追尾枠は表示素子120の画面上の追尾対象の位置に表示される。なお、追尾領域及び同色領域は、RAM118の追尾データログエリアに記録される。また、追尾領域の色情報は追尾色ログエリアに記録される。
The
ステップS110において、追尾処理が実行される。この追尾処理は、主に追尾処理回路1306によって実行される。この追尾処理の詳細については後述する。CPU1301は、ステップS112において追尾位置の被写体に合焦するようにAF処理を行うとともに、追尾位置の被写体の露光が適正となるようにAE処理を行う。追尾処理後のAF処理においてCPU1301は、スキャン駆動又はウォブリング駆動によって、フォーカスレンズを合焦位置まで駆動させる。ウォブリング駆動において、CPU1301は、フォーカスレンズを駆動したときにAF制御回路1302で算出された合焦評価値が、前回のレンズ位置での合焦評価値に対して増加したか否かを判定する。CPU1301は、合焦評価値が増加したと判定された場合には前回と同方向にフォーカスレンズを微小駆動させ、合焦評価値が減少した場合には前回と逆方向にフォーカスレンズを微小駆動させる。このような動作を高速で繰り返してフォーカスレンズを徐々に合焦位置まで駆動させる。AE処理においてCPU1301は、AE制御回路1303で算出された追尾位置の被写体の輝度を予め定められた適正な量(適正露光量)とする、本露光時の絞り106の開口量(絞り値)、シャッタ110の開放時間(シャッタ速度値)を算出する。
In step S110, a tracking process is executed. This tracking process is mainly executed by the
CPU1301は、ステップS114において2ndレリーズスイッチがオンされたか否かを判定する。2ndレリーズスイッチがオンされていないと判定された場合、処理はステップS110に戻る。このように、2ndレリーズスイッチがオンされるまで、追尾処理とAF・AE処理とが継続される。
In step S114, the
ステップS114において2ndレリーズスイッチがオンされたと判定された場合、CPU1301は、ステップS116において表示素子駆動回路122を制御して、追尾枠を非表示とする。CPU1301は、ステップS118において静止画像データを記録メディア128に記録する処理を行う。すなわち、CPU1301は、シャッタ駆動機構112を制御してシャッタ110を閉じさせ、絞り駆動機構108を制御して絞り106を先に算出した絞り値まで絞り込ませる。続いて、CPU1301は、シャッタ駆動機構112を制御してシャッタ110を先に算出した開放時間だけ開放させつつ、撮像素子114に撮像(露光)を行わせる。その後、CPU1301は、撮像素子114を介して得られた静止画像データを画像処理回路1304に処理させる。CPU1301は、画像処理回路1304において処理された静止画像データにヘッダを付与して静止画像ファイルを生成し、生成した静止画像ファイルを記録メディア128に記録する。CPU1301は、ステップS120においてステップS110の追尾処理の結果として得られた追尾位置を示すデータを、先に記録メディア128に記録した静止画像ファイルに追記する。その後に、CPU1301は、図3に示す動作を終了させる。
If it is determined in step S114 that the 2nd release switch is turned on, the
ステップS100において撮影設定が動画撮影モードであると判定された場合、CPU1301は、ステップS122において、ライブビュー動作を開始させる。CPU1301は、ステップS124において動画ボタンがオンされたか否かを判定する。ステップS124において、動画ボタンがオンされたと判定されるまで、CPU1301はライブビュー動作を継続する。
When it is determined in step S100 that the shooting setting is the moving image shooting mode, the
ステップS124において動画ボタンがオンされたと判定された場合、CPU1301は、ステップS126において追尾領域を設定し、表示素子駆動回路122を制御して表示素子120に追尾枠を表示させる。ステップS128において後に詳述する追尾処理が実行される。CPU1301は、ステップS130において、追尾位置の被写体に合焦するようにAF処理を行うともに、追尾位置の被写体の露光が適正となるようにAE処理を行う。ステップS130におけるAF処理おいて、フォーカスレンズは、ウォブリング駆動によって合焦位置まで駆動される。
If it is determined in step S124 that the moving image button has been turned on, the
CPU1301は、ステップS132において動画像データを記録メディア128に記録する処理を行う。すなわち、CPU1301は、絞り駆動機構108を制御して絞り106をAE処理において算出した絞り値まで絞り込ませ、AE処理において算出したシャッタ速度値に対応した時間だけ撮像素子114に撮像(露光)を実行させる。露光の終了後、CPU1301は、動画像ファイルを生成して記録メディア128に記録する。また、CPU1301は、撮像素子114を介して得られた動画像データを画像処理回路1304において処理し、画像処理回路1304において処理された動画像データを動画像ファイルに記録する。
In step S132, the
CPU1301は、ステップS134においてステップS128の追尾処理の結果として得られた追尾位置を示すデータを、先に記録メディア128に記録した動画像ファイルに同時記録する。CPU1301は、ステップS136において動画ボタンがオフにされたか否かを判定する。動画ボタンがオフにされていないと判定された場合、処理はステップS128に戻る。このように、動画撮影モード時では、動画ボタンがオフされるまで追尾処理と動画像データの記録が継続される。
In step S134, the
ステップS136において動画ボタンがオフされたと判定された場合、CPU1301は、ステップS138において表示素子駆動回路122を制御して、追尾枠を非表示とする。その後、CPU1301は、図3に示す動作を終了させる。
If it is determined in step S136 that the moving image button has been turned off, the
本実施形態に係る追尾処理について図4を参照して説明する。CPU1301は、ステップS200において撮像素子IF回路116を制御して撮像素子114に撮像を実行させる。CPU1301は、ステップS202において、撮像素子114によって撮像された画像のデータを、撮像素子IF回路116を介してRAM118に取り込む。RAM118に取り込まれた画像のデータは、追尾処理回路1306内の画像取得部13061により、必要に応じて追尾処理回路1306に取り込まれる。
The tracking process according to the present embodiment will be described with reference to FIG. In step S200, the
追尾処理回路1306内の色取得位置決定部13063は、ステップS204において色情報取得位置判断処理を実行する。この色情報取得位置判断処理について図5に示すフローチャートを参照して説明する。本実施形態では、色情報取得位置判断処理において、5つの色取得位置が設定される。
In step S204, the color acquisition
追尾領域設定部13062は、ステップS300においてX方向の補正倍率(補正倍率(X方向))を決定する。補正倍率(X方向)は、下記式(1)により算出される。
補正倍率(X方向)=同色領域幅(X方向)/第1の定数 (1)
ここで、同色領域幅(X方向)は、同色領域のX方向の長さを表す。同色領域とは、ステップS108の説明において述べたとおり、追尾領域と同じ色情報を有する領域を探索した結果得られる矩形領域である。また、第1の定数は所定の定数である。
The tracking
Correction magnification (X direction) = same color area width (X direction) / first constant (1)
Here, the same color region width (X direction) represents the length of the same color region in the X direction. The same color area is a rectangular area obtained as a result of searching for an area having the same color information as the tracking area, as described in the description of step S108. The first constant is a predetermined constant.
色取得位置決定部13063は、ステップS302において、Y方向の補正倍率(補正倍率(Y方向))を決定する。補正倍率(Y方向)は、下記式(2)により算出される。
補正倍率(Y方向)=同色領域幅(Y方向)/第2の定数 (2)
ここで、同色領域幅(Y方向)は、同色領域のY方向の長さを表す。また、第2の定数は所定の定数である。第2の定数は、第1の定数と同じ値でもよいし、異なる値でもよい。
In step S302, the color acquisition
Correction magnification (Y direction) = same color area width (Y direction) / second constant (2)
Here, the same color region width (Y direction) represents the length of the same color region in the Y direction. The second constant is a predetermined constant. The second constant may be the same value as the first constant or a different value.
色取得位置決定部13063は、ステップS304において、複数設定する追尾位置のX方向の間隔(間隔(X方向))を決定する。ここで、間隔(X方向)は、下記式(3)により算出される。
間隔(X方向)=第1の基準間隔×補正倍率(X方向) (3)
ここで、第1の基準間隔は所定の間隔である。
In step S304, the color acquisition
Interval (X direction) = first reference interval × correction magnification (X direction) (3)
Here, the first reference interval is a predetermined interval.
色取得位置決定部13063は、ステップS306において、複数設定する追尾位置のY方向の間隔(間隔(Y方向))を決定する。ここで、間隔(Y方向)は、下記式(4)により算出される。
間隔(Y方向)=第2の基準間隔×補正倍率(Y方向) (4)
ここで、第2の基準間隔は所定の間隔であり、第1の基準間隔と同じ値でもよいし、異なる値でもよい。
In step S306, the color acquisition
Interval (Y direction) = second reference interval × correction magnification (Y direction) (4)
Here, the second reference interval is a predetermined interval, and may be the same value as the first reference interval or a different value.
色取得位置決定部13063は、ステップS308において、色取得位置(中央)を決定する。ここで、色取得位置(中央)のX座標x及びY座標yは、下記式(5)及び(6)により得られる。
x=追尾位置(X方向) (5)
y=追尾位置(Y方向) (6)
ここで、追尾位置(X方向)は、現在の追尾領域の重心の位置である追尾位置のX座標である。また、追尾位置(Y方向)は現在の追尾位置のY座標である。
In step S308, the color acquisition
x = tracking position (X direction) (5)
y = tracking position (Y direction) (6)
Here, the tracking position (X direction) is the X coordinate of the tracking position, which is the position of the center of gravity of the current tracking area. The tracking position (Y direction) is the Y coordinate of the current tracking position.
色取得位置決定部13063は、ステップS310において、色取得位置(右)を決定する。ここで、色取得位置(右)のX座標x及びY座標yは、下記式(7)及び(8)により得られる。
x=追尾位置(X方向)+間隔(X方向) (7)
y=追尾位置(Y方向) (8)
色取得位置決定部13063は、ステップS312において、色取得位置(左)を決定する。ここで、色取得位置(左)のX座標x及びY座標yは、下記式(9)及び(10)により得られる。
x=追尾位置(X方向)−間隔(X方向) (9)
y=追尾位置(Y方向) (10)
色取得位置決定部13063は、ステップS314において、色取得位置(上)を決定する。ここで、色取得位置(上)のX座標x及びY座標yは、下記式(11)及び(12)により得られる。
x=追尾位置(X方向) (11)
y=追尾位置(Y方向)−間隔(Y方向) (12)
色取得位置決定部13063は、ステップS316において、色取得位置(下)を決定する。ここで、色取得位置(下)のX座標x及びY座標yは、下記式(13)及び(14)により得られる。
x=追尾位置(X方向) (13)
y=追尾位置(Y方向)+間隔(Y方向) (14)
ステップS316の後、処理は、色取得位置(中央)、色取得位置(右)、色取得位置(左)、色取得位置(上)及び色取得位置(下)を戻り値として、図4を参照して説明している追尾処理に戻る。
In step S310, the color acquisition
x = tracking position (X direction) + interval (X direction) (7)
y = tracking position (Y direction) (8)
In step S312, the color acquisition
x = tracking position (X direction) −interval (X direction) (9)
y = tracking position (Y direction) (10)
In step S314, the color acquisition
x = tracking position (X direction) (11)
y = tracking position (Y direction) −interval (Y direction) (12)
In step S316, the color acquisition
x = tracking position (X direction) (13)
y = tracking position (Y direction) + interval (Y direction) (14)
After step S316, the process returns the color acquisition position (center), the color acquisition position (right), the color acquisition position (left), the color acquisition position (upper), and the color acquisition position (lower) as return values, as shown in FIG. Return to the tracking process described with reference.
以上説明した色情報取得位置判断処理によれば、図6に示すような色取得位置が得られる。すなわち、図6において、自動車が追尾被写体310であり、その中に追尾領域320が設定されている。追尾領域320と同じ色の矩形領域が同色領域330として設定されている。ここで、色情報取得位置判断処理によって、追尾領域320の重心位置が色取得位置(中央)350Cに設定される。また、追尾領域320の右側に色取得位置(右)350Rが、追尾領域320の左側に色取得位置(左)350Lが、追尾領域320の上側に色取得位置(上)350Tが、追尾領域320の下側に色取得位置(下)350Bが、それぞれ設定される。
According to the color information acquisition position determination process described above, a color acquisition position as shown in FIG. 6 is obtained. That is, in FIG. 6, the car is the tracking subject 310, and the
図4に戻り、追尾処理について説明を続ける。追尾処理回路1306は、ステップS206において、色情報取得位置判断処理で決定された色取得位置(中央)350C、色取得位置(右)350R、色取得位置(左)350L、色取得位置(上)350T及び色取得位置(下)350Bのそれぞれの位置における色情報を取得する。追尾処理回路1306内の類似色検出部13064は、ステップS208において、最類似色判断処理を実行する。
Returning to FIG. 4, the description of the tracking process will be continued. In step S206, the
最類似色判断処理について図7に示すフローチャートを参照して説明する。類似色検出部13064は、ステップS400において、色取得位置(中央)350C、色取得位置(右)350R、色取得位置(左)350L、色取得位置(上)350T及び色取得位置(下)350Bのうち、その色情報が最も追尾色の色情報と類似している位置を選択する。この位置を最類似色位置と称する。なお、各色取得位置の色情報として、各色取得位置の1画素の色情報が用いられてもよいし、各色取得位置を中心とする複数画素の色情報が用いられてもよい。
The most similar color determination process will be described with reference to the flowchart shown in FIG. In step S400, the similar
類似色検出部13064は、ステップS402において追尾色の色情報と最類似色位置の色情報との差異が所定の閾値未満であるか否かを判定する。所定の閾値未満であれば、類似色検出部13064は、ステップS404において、戻り値に最類似色位置有りという情報と選択された最類似色位置の情報とを設定し、処理は図4を参照して説明している処理に戻る。一方、ステップS402の判定において所定の閾値以上であると判定された場合、類似色検出部13064は、ステップS406において、戻り値に最類似色位置無しという情報を設定し、処理は図4を参照して説明している処理に戻る。追尾色の色情報と最類似色位置の色情報との差異を評価することで、追尾の精度が向上する。
In step S402, the similar
例えば図8のように、追尾被写体310である自動車が左に移動している場合を考える。この場合、色取得位置(中央)350C、色取得位置(右)350R、色取得位置(左)350L、色取得位置(上)350T及び色取得位置(下)350Bのうち、追尾色と類似している位置は、色取得位置(左)350Lであると選択される。ここで、追尾色の色情報と色取得位置(左)350Lの色情報との差異が所定の閾値未満であれば、戻り値に最類似色位置有りという情報とこの最類似色位置は色取得位置(左)350Lであるという情報とが設定される。 For example, as shown in FIG. 8, consider a case where an automobile that is the tracking subject 310 is moving to the left. In this case, the color acquisition position (center) 350C, color acquisition position (right) 350R, color acquisition position (left) 350L, color acquisition position (upper) 350T, and color acquisition position (lower) 350B are similar to the tracking color. Is selected to be the color acquisition position (left) 350L. Here, if the difference between the color information of the tracking color and the color information of the color acquisition position (left) 350L is less than a predetermined threshold value, the information indicating that the most similar color position exists in the return value and the most similar color position are obtained. Information that the position (left) is 350L is set.
図4に戻り、追尾処理について説明を続ける。追尾処理回路1306内の追尾領域更新部13065は、ステップS210において最類似色位置が有るか否かを判定する。最類似色位置が無いと判定されたされた場合、追尾領域更新部13065は、ステップS212において追尾領域を更新しない。その後、処理はステップS216に移る。一方、ステップS210の判定において最類似色位置があると判定されたされた場合、追尾領域更新部13065は、ステップS214において追尾領域設定部13062に、追尾領域を最類似色判断処理で選択された最類似色位置に更新させる。なお、追尾領域は、最類似色位置を示す1画素である点としてよいし、その点を重心とする幅を有する領域としてもよい。その後、処理はステップS216に移る。
Returning to FIG. 4, the description of the tracking process will be continued. The tracking
追尾処理回路1306内の信頼性判定部13066は、ステップS216において追尾領域の信頼性を判断する。例えば信頼性判定部13066は、参照画像データの彩度から信頼性を判断する。具体的には、追尾領域の彩度及び輝度が所定値以上である場合、信頼性があると判断される。これらの信頼性を判定するための閾値は適宜設定され得る。
In step S216, the
追尾処理回路1306は、ステップS218において最終的な追尾領域を、RAM118の追尾データログエリアに記録する。また、追尾処理回路1306は、次回の追尾処理においては用いる同色領域も合わせて取得し、RAM118の追尾データログエリアに記録する。また、追尾処理回路1306は、追尾領域の色情報を追尾色ログエリアに記録する。ただし、ステップS216の信頼性判断において、信頼性がないと判断された場合には、追尾位置等を記録しないようにしてもよい。信頼性の判断結果を用いることで、追尾精度が向上する。
The
CPU1301は、ステップS220において表示素子駆動回路122を制御して、追尾枠の表示位置をステップS218で記憶させた追尾位置に対応した位置に更新する。すなわち、表示素子120に表示される追尾枠は更新され、ユーザは追尾位置を表示素子120上で確認しながら、撮像装置100の操作を行うことができる。その後、CPU1301は、図4の追尾処理を終了し、処理は図3を参照して説明した処理に戻る。
In step S220, the
本実施形態によれば、5つの色取得位置のうち追尾領域と最も類似した色を有する位置に次のフレームにおける追尾領域が更新される。このようにして、色の類似度に基づいて、追尾領域が更新され、追尾被写体が追尾されることになる。 According to this embodiment, the tracking area in the next frame is updated to a position having the color most similar to the tracking area among the five color acquisition positions. In this way, the tracking area is updated based on the color similarity, and the tracking subject is tracked.
このように、例えば画像取得部13061は、画像を取得する画像取得部として機能する。例えば追尾領域設定部13062は、画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定する追尾領域設定部として機能する。例えば色取得位置決定部13063は、画像において所定の位置関係を有する少なくとも3つの領域を比較領域に設定する比較領域設定部として機能する。例えば類似色検出部13064は、比較領域のうち前記追尾色に最も類似する色を有する比較領域を更新領域として選択する類似色検出部として機能する。例えば追尾領域更新部13065は、更新領域に基づいて追尾領域を再設定する追尾領域更新を追尾領域設定部に実行させる追尾領域更新部として機能する。例えば信頼性判定部13066は、類似色検出部が決定した前記更新領域の信頼性を判定する信頼性判定部として機能する。例えば焦点距離取得回路1305は、画像を撮像する際に用いられた光学系の焦点距離を取得する焦点距離取得部として機能する。例えば表示素子120は、追尾領域を表示する追尾領域告知部として機能する。
Thus, for example, the
従来知られている色追尾技術と本実施形態に係る色追尾技術とを比較する。従来の色追尾技術について図9を参照して説明する。図9(a)に示すように、追尾被写体410に追尾領域420が設定されているものとする。ここで、追尾領域420内の色情報は取得されている。次のフレーム、すなわち、図9(b)に示すように追尾被写体410が移動したフレームにおいて、前のフレームの追尾領域420の位置に基づいて決定されたサーチエリア450内が例えばラスタースキャンされ、前のフレームの追尾領域420と同じ色情報を有する領域が検索される。そして、図9(c)に示すように同じ色情報を有する領域の例えば重心領域が新たな追尾領域420として更新される。
A conventionally known color tracking technique and the color tracking technique according to the present embodiment will be compared. A conventional color tracking technique will be described with reference to FIG. As shown in FIG. 9A, it is assumed that a
図9を参照して説明したような従来の色追尾技術を用いると、次のような不具合が生じる恐れがある。例えば図10(a)から図10(b)まで、追尾被写体410内の追尾領域420が所望の通りに追尾されていたとする。ここで図10(c)に示すように、追尾領域420と類似した色を有する物体480が追尾被写体に近づき、サーチエリア450内に入ったとき、追尾領域420が図10(c)に示すように物体480の部分に更新される恐れがある。この場合、これ以降追尾被写体410は見失われて物体480が追尾される恐れがある。
If the conventional color tracking technique as described with reference to FIG. 9 is used, the following problems may occur. For example, it is assumed that the
これに対して、本実施形態では追尾色と最も類似する色を有する色取得位置が選択される。したがって、本実施形態に係る色追尾では色分解能が非常に高いと言える。このため、追尾被写体が見失われる可能性は従来技術に比べて極めて低い。本実施形態では、追尾領域は追尾被写体内において変位するが、色情報取得位置判断処理において同色領域の大きさに応じて色取得位置が適当に決定されているので、追尾領域は追尾被写体内に収まるように制御されている。例えば、図11に示すように、図8に示した場合よりも追尾被写体310である自動車が画像の大きな範囲を占めているとき、同色領域は大きくなる。このとき、色取得位置350の間隔は、図8に示した場合よりも広くなる。その結果、追尾被写体410は適切に追尾される。 On the other hand, in the present embodiment, a color acquisition position having a color most similar to the tracking color is selected. Therefore, it can be said that color resolution is very high in the color tracking according to the present embodiment. For this reason, the possibility that the tracking subject is lost is extremely low as compared with the prior art. In this embodiment, the tracking area is displaced within the tracking subject, but since the color acquisition position is appropriately determined according to the size of the same color area in the color information acquisition position determination process, the tracking area is within the tracking subject. It is controlled to fit. For example, as shown in FIG. 11, when the car that is the tracking subject 310 occupies a larger range of the image than in the case shown in FIG. At this time, the interval between the color acquisition positions 350 is wider than that shown in FIG. As a result, the tracking subject 410 is appropriately tracked.
本実施形態によれば、CPU1301によって行われる演算は、追尾色と数か所の色取得位置の色とを比較し最類似色位置を選択する演算であり、図9を参照して説明した従来技術のようにスキャンによる検索の演算を必要としない。したがって、従来技術に比べて本実施形態では、行われる演算量が格段に少ない。したがって、本実施形態によれば高速な処理が実現され得る。さらに、この高速化によって、フレーム間の追尾被写体の移動量は小さくなる。このことは、本実施形態に係る色追尾の原理において、追尾精度を向上させる。
According to the present embodiment, the calculation performed by the
なお、本実施形態では色取得位置を5点としたが、面を形成する3点以上であれば色取得位置は何点でもよい。また、必ずしも色取得位置のうちの1点が元の追尾領域と一致していなくてもよい。ただし、本実施形態のような5点が設定されると、追尾被写体がどのように移動してもよく追尾され得る。 In this embodiment, five color acquisition positions are used, but any number of color acquisition positions may be used as long as there are three or more points forming a surface. In addition, one point in the color acquisition position does not necessarily coincide with the original tracking area. However, if five points as in the present embodiment are set, the tracking subject may be tracked in any manner and may be tracked.
色情報取得位置判断処理において、撮影光学系102の焦点距離を考慮してもよい。例えば、CPU1301は、焦点距離取得回路1305によって取得された焦点距離に基づいて、焦点距離係数を算出する。CPU1301は、図5を参照して説明した色情報取得位置判断処理のステップS304及びステップS306における間隔の算出において、例えば下記式(15)及び(16)のようにこの焦点距離係数を考慮することができる。
間隔(X方向)=第1の基準間隔×補正倍率(X方向)×焦点距離係数 (15)
間隔(Y方向)=第2の基準間隔×補正倍率(Y方向)×焦点距離係数 (16)
なお、この場合、補正倍率は用いられなくてもよい。ただし、上式(15)及び(16)のように補正倍率も焦点距離係数も考慮されている方がより精度が高くなる。
In the color information acquisition position determination process, the focal length of the photographing
Interval (X direction) = first reference interval × correction magnification (X direction) × focal length coefficient (15)
Interval (Y direction) = second reference interval × correction magnification (Y direction) × focal length coefficient (16)
In this case, the correction magnification may not be used. However, the accuracy is higher when the correction magnification and the focal length coefficient are taken into consideration as in the above equations (15) and (16).
このように焦点距離係数が考慮されることによって、焦点距離が長いときは間隔が大きくされ、焦点距離が短いときは間隔が小さくされる。その結果、図11を参照して行った説明と同様に、例えばズームアップされて追尾被写体が画像内で大きな範囲を占めているとき、ズームアウトされて追尾被写体が画像内で小さな範囲を占めている場合に比べて、色取得位置の間隔は大きくなる。その結果、本実施形態に係る色追尾の精度が向上する。なお、焦点距離に応じて、色取得追加位置の数、面積、配置等が変化するように構成されてもよい。 By considering the focal length coefficient in this way, the interval is increased when the focal length is long, and the interval is decreased when the focal length is short. As a result, similar to the explanation given with reference to FIG. 11, for example, when the zoomed-up subject is occupied by a tracking subject occupying a large range in the image, the tracking subject is zoomed out and the tracking subject occupies a small range in the image. Compared with the case where the color acquisition position is, the interval between the color acquisition positions becomes large. As a result, the accuracy of color tracking according to the present embodiment is improved. Note that the number, area, arrangement, and the like of the color acquisition additional positions may be changed according to the focal length.
また、本実施形態では図5を参照して説明した色情報取得位置判断処理において色取得位置が算出されているが、色取得位置の位置関係を表す情報がポイントテンプレートとしてROM134に予め記憶されており、色取得位置決定部13063が色情報取得位置判断処理においてこのテンプレートの配置を決定するように構成されてもよい。また、色取得位置の位置関係が互いに異なるテンプレートが複数用意されており、色情報取得位置判断処理において同色領域等の条件に基づいてテンプレートが選択され、このテンプレートの配置が決定されるように構成されてもよい。また、撮影光学系102の焦点距離に応じてテンプレートが選択されるように構成されてもよい。テンプレートを用いることによって、処理量が削減され、高速な処理が実現される。また、テンプレートが用いられると、最類似色以外に、類似度比率や色分布パターン等が利用され得る。
In the present embodiment, the color acquisition position is calculated in the color information acquisition position determination process described with reference to FIG. 5, but information indicating the positional relationship of the color acquisition positions is stored in advance in the
このように、例えばROM134は、少なくも3つの比較領域の所定の位置関係をポイントテンプレートとして記憶するテンプレート記憶部として機能し、例えば色取得位置決定部13063は、画像において追尾領域の位置に基づいて前記ポイントテンプレートの位置を設定するテンプレート設定部として機能する。
Thus, for example, the
[第2の実施形態]
第2の実施形態について説明する。ここでは、第1の実施形態との相違点について説明し、同一の部分については、同一の符号を付してその説明を省略する。本実施形態では、第1の実施形態において最類似色位置が無いと判定されたとき、すなわち、例えば第1の実施形態による色追尾で追尾領域が追尾被写体から外れてしまったとき、スキャンによって追尾領域を検索する従来技術が用いられる。
[Second Embodiment]
A second embodiment will be described. Here, differences from the first embodiment will be described, and the same portions will be denoted by the same reference numerals and description thereof will be omitted. In the present embodiment, when it is determined that there is no most similar color position in the first embodiment, that is, for example, when the tracking area is out of the tracking subject in the color tracking according to the first embodiment, tracking is performed by scanning. Conventional techniques for searching for regions are used.
本実施形態に係る追尾処理を示すフローチャートを図12に示す。この図に示すように、ステップS500乃至ステップS508は、図4を参照して説明した第1の実施形態のステップS200乃至ステップS208とそれぞれ同じである。すなわち、CPU1301は、ステップS500において撮像素子IF回路116を制御して撮像素子114に撮像を実行させ、ステップS502において撮像素子114によって撮像された画像のデータを撮像素子IF回路116を介してRAM118に取り込む。追尾処理回路1306は、ステップS504において色情報取得位置判断処理を実行し、ステップS506において、色情報取得位置判断処理で決定された色取得位置のそれぞれの位置における色情報を取得し、ステップS508において、最類似色判断処理を実行する。
FIG. 12 is a flowchart showing the tracking process according to the present embodiment. As shown in this figure, steps S500 to S508 are the same as steps S200 to S208 of the first embodiment described with reference to FIG. That is, the
続いて、追尾処理回路1306内の追尾領域更新部13065は、ステップS510において最類似色位置が有るか否かを判定する。最類似色位置が有ると判定されたされた場合、追尾領域更新部13065は、ステップS512において最類似色位置を追尾領域に決定する。その後、処理はステップS522に移る。一方、ステップS510において最類似色位置が無いと判定されたされた場合、追尾処理回路1306内の追尾色重心検索部13067は、ステップS514において追尾色重心検索を行う。ここで、追尾色重心検索とは、例えば図9を参照して説明した従来技術を用いた色追尾である。このように、例えば追尾色重心検索部13067は、画像を走査して追尾色に類似する類似領域を検索し、この類似領域の重心位置を決定する類似領域検索部として機能する。
Subsequently, the tracking
追尾領域更新部13065は、ステップS516において追尾色重心があるか否かを判定する。追尾色重心があると判定された場合、追尾領域更新部13065は、ステップS518において色重心に基づいて追尾領域に決定する。その後、処理はステップS522に移る。ステップS516において追尾色重心がないと判定された場合、追尾領域更新部13065は、ステップS520において追尾領域を更新せず、処理はステップS522に移る。
The tracking
ステップS522乃至ステップS5226は、図4を参照して説明した第1の実施形態のステップ216乃至220と同様である。すなわち、信頼性判定部13066は、ステップS522において追尾領域の信頼性を判断する。追尾処理回路1306は、ステップS524において最終的な追尾領域を、RAM118の追尾データログエリアに記録する。また、次回の追尾処理においては用いる同色領域も合わせて取得し、RAM118の追尾データログエリアに記録する。CPU1301は、ステップS526において表示素子駆動回路122を制御して、追尾枠の表示位置をステップS524で記憶させた追尾位置に対応した位置に更新する。その後、CPU1301は、図12の追尾処理を終了し、処理は図3を参照して説明した処理に戻る。その他の処理は、第1の実施形態の場合と同様である。
Steps S522 to S5226 are the same as
本実施形態によれば、第1の実施形態において追尾被写体が見失われた際も、従来の技術を用いて、広い領域を探索して追尾被写体が見つけ出され得る。本実施形態によれば、第1の実施形態よりもさらに精度よく追尾被写体が追尾され得る。 According to the present embodiment, even when the tracking subject is lost in the first embodiment, the tracking subject can be found by searching a wide area using the conventional technique. According to the present embodiment, the tracking subject can be tracked with higher accuracy than in the first embodiment.
[第3の実施形態]
第3の実施形態について説明する。ここでは、第2の実施形態との相違点について説明し、同一の部分については、同一の符号を付してその説明を省略する。本実施形態では、第2の実施形態において最類似色位置があると判定されたときはフレームレートが高くされ、最類似色が無いと判定され、追尾色重心を用いるときはフレームレートが低くされる。
[Third Embodiment]
A third embodiment will be described. Here, differences from the second embodiment will be described, and the same portions will be denoted by the same reference numerals and description thereof will be omitted. In this embodiment, the frame rate is increased when it is determined that the most similar color position is present in the second embodiment, the frame rate is decreased when it is determined that there is no most similar color, and the tracking color centroid is used. .
本実施形態に係る追尾処理の一例を表すフローチャートを図13に示す。ステップS600乃至ステップS612の処理は、図12を参照して説明した第2の実施形態に係るステップS500乃至ステップS512の処理と同様である。すなわち、CPU1301は、ステップS600において撮像素子IF回路116を制御して撮像素子114に撮像を実行させ、ステップS602において撮像素子114によって撮像された画像のデータを撮像素子IF回路116を介してRAM118に取り込む。追尾処理回路1306は、ステップS604において色情報取得位置判断処理を実行し、ステップS606において色情報取得位置判断処理で決定された色取得位置のそれぞれの位置における色情報を取得し、ステップS608において最類似色判断処理を実行する。追尾処理回路1306は、ステップS610において最類似色位置が有るか否かを判定する。最類似色位置が有ると判定されたされた場合、追尾処理回路1306は、ステップS612において最類似色位置を追尾領域に決定する。
FIG. 13 is a flowchart illustrating an example of the tracking process according to the present embodiment. The processing from step S600 to step S612 is the same as the processing from step S500 to step S512 according to the second embodiment described with reference to FIG. That is, the
その後、追尾処理回路1306は、ステップS614においてフレームレートを高フレームレートに変更するようにCPU1301に指示を出力する。ここで高フレームレートとは、例えば60乃至120fps等である。その後、処理は、ステップS626に移る。
Thereafter, the
また、ステップS616乃至ステップS620の処理は、図12を参照して説明した第2の実施形態に係るステップS514乃至ステップS518の処理と同様である。すなわち、ステップS610において最類似色位置が無いと判定されたされた場合、追尾処理回路1306は、ステップS616において追尾色重心検索を行い、ステップS618において追尾色重心があるか否かを判定する。追尾色重心があると判定された場合、追尾処理回路1306は、ステップS620において色重心を追尾領域に決定する。
Further, the processing from step S616 to step S620 is the same as the processing from step S514 to step S518 according to the second embodiment described with reference to FIG. That is, if it is determined in step S610 that there is no most similar color position, the
その後、追尾処理回路1306は、ステップS622においてフレームレートを低フレームレートに変更するようにCPU1301に指示を出力する。ここで低フレームレートとは、例えば15乃至30fps等である。その後、処理は、ステップS626に移る。
Thereafter, the
また、ステップS624乃至ステップS630の処理は、図12を参照して説明した第2の実施形態に係るステップS520乃至ステップS526の処理と同様である。すなわち、ステップS618において追尾色重心がないと判定された場合、追尾処理回路1306は、ステップS5624において追尾領域を更新せず、処理はステップS626に移る。追尾処理回路1306は、ステップS626において追尾領域の信頼性を判断する。追尾処理回路1306は、ステップS628において最終的な追尾領域を、RAM118の追尾ログエリアに記録する。また、次回の追尾処理においては用いる同色領域も合わせて取得し、RAM118の追尾ログエリアに記録する。CPU1301は、ステップS630において表示素子駆動回路122を制御して、追尾枠の表示位置をステップS628で記憶させた追尾位置に対応した位置に更新する。その後、CPU1301は、図13の追尾処理を終了し、処理は図3を参照して説明した処理に戻る。その他の処理は、第2の実施形態の場合と同様である。
Further, the processing from step S624 to step S630 is the same as the processing from step S520 to step S526 according to the second embodiment described with reference to FIG. That is, if it is determined in step S618 that there is no tracking color centroid, the
上述のとおり、追尾色重心検索を行う従来技術に比べ、最類似色位置を用いる本発明に係る技術では、処理速度が非常に早い。したがって、本実施形態ではこの処理速度に合わせてフレームレートを変更している。本実施形態によれば、処理に必要かつ十分な時間が確保され、全体として処理速度を速めることができる。最類似色位置に基づく追尾領域の決定を高フレームレートで実行することで、フレーム間の画像の差が小さくなるので、最類似色位置に基づく色追尾の精度は向上する。 As described above, the processing speed of the technique according to the present invention using the most similar color position is very fast compared to the conventional technique that performs the tracking color gravity center search. Therefore, in this embodiment, the frame rate is changed in accordance with this processing speed. According to the present embodiment, a necessary and sufficient time for processing is ensured, and the processing speed can be increased as a whole. By executing the determination of the tracking area based on the most similar color position at a high frame rate, an image difference between frames is reduced, so that the accuracy of color tracking based on the most similar color position is improved.
上記の60乃至120fpsや15乃至30fps等はもちろん一例である。また、これらフレームレートは、表示素子120が画像を表示するフレームレート、記録メディア128に画像を記録するフレームレート、又は画像を撮影する際に用いられたオートフォーカス、自動露出若しくはオートホワイトバランスのフレームレートに応じて変更されてもよい。オートフォーカス等のフレームレートに応じて変更されることで、必要な追尾のフレームレートが確保される。
Of course, the above 60 to 120 fps, 15 to 30 fps, and the like are examples. These frame rates are the frame rate at which the
[第4の実施形態]
第4の実施形態について説明する。ここでは、第1の実施形態との相違点について説明し、同一の部分については、同一の符号を付してその説明を省略する。本実施形態では、第1の実施形態における色情報取得位置判断処理が異なる。
[Fourth Embodiment]
A fourth embodiment will be described. Here, differences from the first embodiment will be described, and the same portions will be denoted by the same reference numerals and description thereof will be omitted. In the present embodiment, the color information acquisition position determination process in the first embodiment is different.
本実施形態に係る色情報取得位置判断処理の一例を示すフローチャートを図14に示す。この図に示すように、ステップS701乃至ステップS716は、図5を参照して説明した第1の実施形態におけるステップS300乃至ステップS316と同様である。すなわち、色取得位置決定部13063は、ステップS700において補正倍率(X方向)を算出し、ステップS702において補正倍率(Y方向)を算出し、ステップS704において間隔(X方向)を算出し、ステップS706において間隔(Y方向)を算出する。次に色取得位置決定部13063は、ステップS708において色取得位置(中央)を算出し、ステップS710において色取得位置(右)を算出し、ステップS712において色取得位置(左)を算出し、ステップS714において色取得位置(上)を算出し、ステップS716において色取得位置(下)を算出する。
FIG. 14 is a flowchart illustrating an example of the color information acquisition position determination process according to the present embodiment. As shown in this figure, steps S701 to S716 are the same as steps S300 to S316 in the first embodiment described with reference to FIG. That is, the color acquisition
色取得位置決定部13063は、ステップS718において積算値(X方向)を算出する。ここで積算値(X方向)は、過去の複数のフレームにおける追尾領域の動きベクトルのX方向の積算値である。ここで上記のフレーム数は所定の値である。色取得位置決定部13063は、ステップS720において積算値(X方向)が所定の閾値より大きいか否かを判定する。積算値(X方向)が所定の閾値以下であると判定された場合、処理はステップS726に移る。
In step S718, the color acquisition
ステップS720において所定の閾値よりも大きいと判定された場合、色取得位置決定部13063は、ステップS722において色取得追加位置(右)のX座標xとY座標yをそれぞれ下記式(17)及び(18)に基づいて決定する。
x=追尾位置(X方向)+間隔(X方向)×2 (17)
y=追尾位置(Y方向) (18)
続いて、色取得位置決定部13063は、ステップS724において色取得追加位置(左)のX座標xとY座標yをそれぞれ下記式(19)及び(20)に基づいて決定する。
x=追尾位置(X方向)−間隔(X方向)×2 (19)
y=追尾位置(Y方向) (20)
If it is determined in step S720 that the color acquisition
x = tracking position (X direction) + interval (X direction) × 2 (17)
y = tracking position (Y direction) (18)
Subsequently, the color acquisition
x = tracking position (X direction) −interval (X direction) × 2 (19)
y = tracking position (Y direction) (20)
色取得位置決定部13063は、ステップS726において積算値(Y方向)を算出する。ここで積算値(Y方向)は、過去の複数のフレームにおける追尾領域の動きベクトルのY方向の積算値である。ここでフレーム数は所定の値である。CPU1301は、ステップS720において積算値(Y方向)が所定の閾値より大きいか否かを判定する。積算値(Y方向)が所定の閾値以下であると判定された場合、処理は図4を参照して説明した追尾処理に戻る。
In step S726, the color acquisition
ステップS728において所定の閾値よりも大きいと判定された場合、色取得位置決定部13063は、ステップS730において色取得追加位置(上)のX座標xとY座標yをそれぞれ下記式(21)及び(22)に基づいて決定する。
x=追尾位置(X方向) (21)
y=追尾位置(Y方向)−間隔(Y方向)×2 (22)
続いて、色取得位置決定部13063は、ステップS732において色取得追加位置(下)のX座標xとY座標yをそれぞれ下記式(23)及び(24)に基づいて決定する。
x=追尾位置(X方向) (23)
y=追尾位置(Y方向)+間隔(X方向)×2 (24)
その後、処理は図4を参照して説明した追尾処理に戻る。
If it is determined in step S728 that it is greater than the predetermined threshold value, the color acquisition
x = tracking position (X direction) (21)
y = tracking position (Y direction) −interval (Y direction) × 2 (22)
Subsequently, the color acquisition
x = tracking position (X direction) (23)
y = tracking position (Y direction) + interval (X direction) × 2 (24)
Thereafter, the processing returns to the tracking processing described with reference to FIG.
追尾処理に戻る際の戻り値は、色取得位置(中央)、色取得位置(右)、色取得位置(左)、色取得位置(上)及び色取得位置(下)、並びに、追加された色取得追加位置(右)及び色取得追加位置(左)、及び/又は、色取得追加位置(上)及び色取得追加位置(下)である。その他の処理は、第1の実施形態と同様である。 Return values when returning to the tracking process include color acquisition position (center), color acquisition position (right), color acquisition position (left), color acquisition position (upper), color acquisition position (lower), and added Color acquisition additional position (right) and color acquisition additional position (left), and / or color acquisition additional position (upper) and color acquisition additional position (lower). Other processes are the same as those in the first embodiment.
本実施形態では、ステップS720の判定で所定の閾値よりも大きいと判定された場合、すなわち、追尾領域のX方向の速度が所定の値より大きいとき、色取得追加位置が左右に設定される。同様に、ステップS728の判定で所定の閾値よりも大きいと判定された場合、すなわち、追尾領域のY方向の速度が所定の値より大きいとき、色取得追加位置が上下に設定される。すなわち、例えば図15に示すように、追尾被写体310が左に所定の速度より早く動いているとき、色取得位置(中央)350C、色取得位置(右)350R、色取得位置(左)350L、色取得位置(上)350T及び色取得位置(下)350Bに加えて、色取得追加位置(左)360Lと画像の領域から外れているため図示されていない色取得追加位置(右)が設定される。したがって、本実施形態では、図7を参照して説明した最類似色判断処理では、これら7点のうち最も追尾色に類似する色を有する位置が最類似位置として選択される。 In the present embodiment, when it is determined in step S720 that it is larger than the predetermined threshold, that is, when the speed in the X direction of the tracking area is larger than a predetermined value, the color acquisition additional position is set to the left and right. Similarly, when it is determined in step S728 that the speed is larger than the predetermined threshold, that is, when the speed of the tracking area in the Y direction is higher than a predetermined value, the color acquisition additional position is set up and down. That is, for example, as shown in FIG. 15, when the tracking subject 310 is moving to the left faster than a predetermined speed, the color acquisition position (center) 350C, the color acquisition position (right) 350R, the color acquisition position (left) 350L, In addition to the color acquisition position (upper) 350T and the color acquisition position (lower) 350B, a color acquisition additional position (left) 360L and a color acquisition additional position (right) not shown because they are out of the image area are set. The Therefore, in the present embodiment, in the most similar color determination process described with reference to FIG. 7, the position having the color most similar to the tracking color among these seven points is selected as the most similar position.
本実施形態によれば、追尾被写体の速度が速いとき、追尾被写体が色取得位置から外れて、その結果、追尾被写体を追尾されなくなることを防止することができる。 According to the present embodiment, when the speed of the tracking subject is high, it is possible to prevent the tracking subject from being out of the color acquisition position and consequently not being tracked.
なお、本実施形態では、色取得追加位置は、上下及び/又は左右に1つずつ追加されているが、追尾被写体の速度に応じて複数個ずつ追加されるように構成されてもよい。また、追尾被写体の移動方向に応じて、移動する方向にのみ色取得追加位置を追加するように構成されてもよい。また、追尾被写体の速度に応じて色取得位置の間隔を変更するように構成されてもよい。また、追尾被写体の速度に応じて色の比較に用いられる領域の面積が変更されるように構成されてもよい。 In the present embodiment, one color acquisition additional position is added vertically and / or left and right, but a plurality of color acquisition additional positions may be added according to the speed of the tracking subject. Further, the color acquisition additional position may be added only in the moving direction according to the moving direction of the tracking subject. Further, the color acquisition position interval may be changed according to the speed of the tracking subject. Further, the area of the region used for color comparison may be changed according to the speed of the tracking subject.
また、追尾領域の動きベクトルに基づいて色取得位置の配置を、上下左右でなく斜めに配置されるように構成されてもよい。例えば、回転角度θを下記式(25)により決定される。
θ=tan−1(積算値(Y方向)/積算値(X方向)) (25)
そして回転角度θを用いて、色取得位置のX座標x´及びY座標y´をそれぞれ下記式(26)及び(27)のように求められ得る。
x´=x×cosθ−y×sinθ (26)
y´=x×sinθ+y×cosθ (27)
ここで、x及びyは、それぞれ上記式(7)乃至(14)で求まる値である。
Further, the arrangement of the color acquisition positions based on the motion vector of the tracking area may be arranged diagonally instead of vertically and horizontally. For example, the rotation angle θ is determined by the following equation (25).
θ = tan −1 (integrated value (Y direction) / integrated value (X direction)) (25)
Then, using the rotation angle θ, the X-coordinate x ′ and the Y-coordinate y ′ of the color acquisition position can be obtained by the following equations (26) and (27), respectively.
x ′ = x × cos θ−y × sin θ (26)
y ′ = x × sin θ + y × cos θ (27)
Here, x and y are values obtained by the above formulas (7) to (14), respectively.
このように、色取得位置を追尾被写体の移動方向に合わせて斜めに配置することによっても、追尾被写体が色取得位置から外れて、その結果、追尾被写体を追尾されなくなることが防止され得る。なお、第4の実施形態及び上述したその変形例は、第2の実施形態又は第3の実施形態と組み合わせて用いられてもよいことはもちろんである。 As described above, by arranging the color acquisition position obliquely in accordance with the moving direction of the tracking subject, it is possible to prevent the tracking subject from being out of the color acquisition position and as a result, the tracking subject is not tracked. Needless to say, the fourth embodiment and the modifications described above may be used in combination with the second embodiment or the third embodiment.
また、色取得位置の決定にポイントテンプレートを用いる場合、種々のポイントテンプレートが予め用意され、追尾被写体の移動速度に応じてそれらのうちから適当なポイントテンプレートが選択されるように構成されてもよい。 When a point template is used for determining the color acquisition position, various point templates may be prepared in advance, and an appropriate point template may be selected from them according to the moving speed of the tracking subject. .
[第5の実施形態]
第5の実施形態について説明する。ここでは、第1の実施形態との相違点について説明し、同一の部分については、同一の符号を付してその説明を省略する。本実施形態は、第1の実施形態と比較して、図7を参照して説明した最類似判断処理が異なる。本実施形態に係る最類似色判断処理を図16に示すフローチャートを参照して説明する。
[Fifth Embodiment]
A fifth embodiment will be described. Here, differences from the first embodiment will be described, and the same portions will be denoted by the same reference numerals and description thereof will be omitted. This embodiment is different from the first embodiment in the most similar determination process described with reference to FIG. The most similar color determination process according to the present embodiment will be described with reference to the flowchart shown in FIG.
類似色検出部13064は、ステップS800において、色取得位置(中央)、色取得位置(右)、色取得位置(左)、色取得位置(上)及び色取得位置(下)のうち、その色が最も追尾色と類似している最類似色位置を選択する。類似色検出部13064は、ステップS802において追尾色の色情報と最類似色位置の色情報との差異が所定の閾値未満であるか否かを判定する。
In step S800, the similar
ステップS802の判定において所定の閾値未満であると判定された場合、類似色検出部13064は、ステップS804において、色取得位置(中央)の色と最類似位置の色との差異が所定の閾値より大きいか否かを判定する。この判定において所定の閾値より大きいと判定された場合、類似色検出部13064は、ステップS806において戻り値に最類似色位置有りという情報とこの最類似色位置の情報とを設定し、処理は図4を参照して説明した追尾処理に戻る。
If it is determined in step S802 that the color is less than the predetermined threshold, the similar
一方、ステップS804の判定において所定の閾値以下と判定された場合、類似色検出部13064は、ステップS808において追尾色の色情報と最類似色位置の色情報との差異が所定の閾値未満であるか否かを判定する。この判定において所定の閾値未満であると判定された場合、類似色検出部13064は、ステップS810において戻り値に、最類似色位置有りという情報とこの最類似色位置の情報として色取得位置(中央)の位置とを設定し、処理は図4を参照して説明した追尾処理に戻る。ステップS808の判定において所定の閾値以上であると判定された場合、処理はステップS806に移る。
On the other hand, if it is determined in step S804 that the color value is equal to or less than the predetermined threshold value, the similar
ステップS802の判定において所定の閾値以上であると判定された場合、類似色検出部13064は、ステップS812において、戻り値に最類似色位置無しという情報を設定し、処理は図4を参照して説明した追尾処理に戻る。その他の処理は、第1の実施形態と同様である。
If it is determined in step S802 that the threshold value is equal to or greater than the predetermined threshold, the similar
本実施形態によれば、追尾色に最も類似した色を有する色取得位置と色取得位置(中央)との色が近いとき、追尾領域として、追尾色に最も類似した色を有する色取得位置よりも色取得位置(中央)が優先的に採用される。すなわち、本実施形態では、複数の色取得位置のうち前の追尾領域と一致する中央の色取得位置の重み付けが高い。 According to this embodiment, when the color acquisition position having the color most similar to the tracking color is close to the color acquisition position (center), the color acquisition position having the color most similar to the tracking color is used as the tracking area. Also, the color acquisition position (center) is preferentially adopted. That is, in this embodiment, the weight of the central color acquisition position that matches the previous tracking area among the plurality of color acquisition positions is high.
前述のとおり本発明に係る色追尾技術では、色分解能が高い。このため、追尾領域の位置が必要以上に細かく更新されがちである。これに対して本実施形態によれば、追尾領域の不要な更新がある程度抑制され、安定した追尾が実現される。なお、第5の実施形態は、第2乃至第4の実施形態と組み合わせて用いられてもよいことはもちろんである。 As described above, the color tracking technique according to the present invention has high color resolution. For this reason, the position of the tracking area tends to be updated more finely than necessary. On the other hand, according to the present embodiment, unnecessary updating of the tracking area is suppressed to some extent, and stable tracking is realized. Needless to say, the fifth embodiment may be used in combination with the second to fourth embodiments.
なお、本発明は上記実施形態そのままに限定されるものではなく、実施段階ではその要旨を逸脱しない範囲で構成要素を変形して具体化できる。また、上記実施形態に開示されている複数の構成要素の適宜な組み合わせにより、種々の発明を形成できる。例えば、実施形態に示される全構成要素から幾つかの構成要素を削除しても、発明が解決しようとする課題の欄で述べられた課題が解決でき、かつ、発明の効果が得られる場合には、この構成要素が削除された構成も発明として抽出され得る。さらに、異なる実施形態にわたる構成要素を適宜組み合わせてもよい。 Note that the present invention is not limited to the above-described embodiment as it is, and can be embodied by modifying the constituent elements without departing from the scope of the invention in the implementation stage. In addition, various inventions can be formed by appropriately combining a plurality of components disclosed in the embodiment. For example, even if some constituent elements are deleted from all the constituent elements shown in the embodiment, the problem described in the column of problems to be solved by the invention can be solved and the effect of the invention can be obtained. The configuration in which this component is deleted can also be extracted as an invention. Furthermore, constituent elements over different embodiments may be appropriately combined.
100…撮像装置、102…撮影光学系、104…焦点調整機構、106…絞り、108…絞り駆動機構、110…シャッタ、112…シャッタ駆動機構、114…撮像素子、116…撮像素子インターフェイス(IF)回路、118…RAM、120…表示素子、122…表示素子駆動回路、124…タッチパネル、126…タッチパネル駆動回路、128…記録メディア、130…システムコントローラ、132…操作部、134…ROM、1301…CPU、1302…AF制御回路、1303…AE制御回路、1304…画像処理回路、1305…焦点距離取得回路、1306…追尾処理回路、13061…画像取得部、13062…追尾領域設定部、13063…色取得位置決定部、13064…類似色検出部、13065…追尾領域更新部、13066…信頼性判定部、13067…追尾色重心検索部、1307…顔検出回路、1308…メモリ制御回路。
DESCRIPTION OF
Claims (18)
前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定する追尾領域設定部と、
前記画像において所定の位置関係を有する少なくとも3つの領域を比較領域に設定する比較領域設定部と、
前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択する類似色検出部と、
前記更新領域に基づいて前記追尾領域を再設定する追尾領域更新を前記追尾領域設定部に実行させる追尾領域更新部と、
を具備することを特徴とする追尾装置。 An image acquisition unit for acquiring images;
A tracking area setting unit that sets a part of the image as a tracking area and sets a color of the tracking area as a tracking color;
A comparison area setting unit that sets at least three areas having a predetermined positional relationship in the image as comparison areas;
A similar color detection unit that selects the comparison region having the color most similar to the tracking color among the comparison regions as an update region;
A tracking area update unit that causes the tracking area setting unit to execute a tracking area update that resets the tracking area based on the update area;
A tracking device comprising:
少なくも3つの比較領域の所定の位置関係をポイントテンプレートとして記憶するテンプレート記憶部と、
前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定する追尾領域設定部と、
前記画像において前記追尾領域の位置に基づいて前記ポイントテンプレートの位置を設定するテンプレート設定部と、
設定された前記ポイントテンプレートの前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択する類似色検出部と、
前記更新領域に基づいて前記追尾領域を再設定する追尾領域更新を前記追尾領域設定部に実行させる追尾領域更新部と、
を具備することを特徴とする追尾装置。 An image acquisition unit for acquiring images;
A template storage unit that stores a predetermined positional relationship of at least three comparison regions as a point template;
A tracking area setting unit that sets a part of the image as a tracking area and sets a color of the tracking area as a tracking color;
A template setting unit for setting the position of the point template based on the position of the tracking area in the image;
A similar color detection unit that selects, as an update region, the comparison region that has the color most similar to the tracking color among the comparison regions of the set point template;
A tracking area update unit that causes the tracking area setting unit to execute a tracking area update that resets the tracking area based on the update area;
A tracking device comprising:
前記比較領域設定部は、前記焦点距離に応じて、前記比較領域の数、前記追尾領域と前記比較領域との距離、前記追尾領域及び前記比較領域を結ぶ線と前記画像の横軸とが成す角、並びに、前記追尾領域の面積のうち少なくとも1つを変更する、
ことを特徴とする請求項1に記載の追尾装置。 Further comprising a focal length acquisition unit for acquiring a focal length of an optical system used when capturing the image;
The comparison area setting unit includes the number of comparison areas, the distance between the tracking area and the comparison area, a line connecting the tracking area and the comparison area, and the horizontal axis of the image according to the focal length. Changing at least one of the corners and the area of the tracking region;
The tracking device according to claim 1.
前記類似色検出部は、前記比較領域の色と前記追尾色との類似度に応じて、前記比較領域のうち前記追尾領域と一致する前記比較領域とそれ以外の前記比較領域とで重み付けを変更して前記更新領域を決定する、
ことを特徴とする請求項1乃至4のうち何れか1項に記載の追尾装置。 One of the comparison areas and the tracking area coincide;
The similar color detection unit changes the weighting of the comparison area that matches the tracking area and the comparison areas other than the comparison area in the comparison area according to the similarity between the color of the comparison area and the tracking color. And determining the update area,
The tracking device according to any one of claims 1 to 4, wherein the tracking device is characterized in that:
前記類似色検出部が前記更新領域を決定しないとき、前記追尾領域更新部は、前記追尾領域更新を前記追尾領域設定部に実行させない、
ことを特徴とする請求項1乃至9のうち何れか1項に記載の追尾装置。 When the difference between the color of the comparison area and the tracking color is equal to or greater than a predetermined value, the similar color detection unit does not determine the update area,
When the similar color detection unit does not determine the update region, the tracking region update unit does not cause the tracking region setting unit to execute the tracking region update,
The tracking device according to claim 1, wherein the tracking device is one of the following.
前記比較領域の色と前記追尾色との差異が所定の値以上であるとき、
前記類似領域検索部は、前記重心位置を決定し、
前記追尾領域更新部は、前記追尾領域設定部に前記重心位置に基づいて前記追尾領域を再設定させる、
ことを特徴とする請求項1乃至10のうち何れか1項に記載の追尾装置。 The image processing apparatus further includes a similar area search unit that scans the image and searches for a similar area similar to the tracking color, and determines a centroid position of the similar area.
When the difference between the color of the comparison area and the tracking color is a predetermined value or more,
The similar region search unit determines the position of the center of gravity,
The tracking area update unit causes the tracking area setting unit to reset the tracking area based on the gravity center position.
The tracking device according to claim 1, wherein the tracking device is one of the following.
テンプレート設定部は、前記焦点距離に応じて、前記比較領域の数、前記比較領域の間隔、前記比較領域を結ぶ線と前記画像の任意の軸とが成す角、及び前記追尾領域の面積のうち少なくとも1つが異なる複数の前記ポイントテンプレートの中から1つの前記ポイントテンプレートを選択する、
ことを特徴とする請求項2に記載の追尾装置。 Further comprising a focal length acquisition unit for acquiring a focal length of an optical system used when capturing the image;
The template setting unit may include a number of the comparison regions, an interval between the comparison regions, an angle formed by a line connecting the comparison regions and an arbitrary axis of the image, and an area of the tracking region according to the focal length. Selecting one of the point templates from a plurality of the different point templates.
The tracking device according to claim 2.
前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定することと、
前記画像において所定の位置関係を有する少なくとも3つの領域を比較領域に設定することと、
前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択することと、
前記更新領域に基づいて前記追尾領域を再設定することと、
を具備することを特徴とする追尾方法。 Acquiring images,
Setting a partial area of the image as a tracking area, and setting a color of the tracking area as a tracking color;
Setting at least three regions having a predetermined positional relationship in the image as comparison regions;
Selecting the comparison area having the color most similar to the tracking color among the comparison areas as an update area;
Resetting the tracking area based on the update area;
The tracking method characterized by comprising.
前記画像のうち一部の領域を追尾領域に設定し、この追尾領域の色を追尾色に設定することと、
前記画像において前記追尾領域の位置に基づいて、少なくも3つの比較領域の所定の位置関係を有するポイントテンプレートの位置を設定することと、
前記ポイントテンプレートの前記比較領域のうち前記追尾色に最も類似する色を有する前記比較領域を更新領域として選択することと、
前記更新領域に基づいて前記追尾領域を再設定することと、
を具備することを特徴とする追尾方法。 Acquiring images,
Setting a partial area of the image as a tracking area, and setting a color of the tracking area as a tracking color;
Setting a position of a point template having a predetermined positional relationship of at least three comparison areas based on the position of the tracking area in the image;
Selecting the comparison area having the color most similar to the tracking color as the update area among the comparison areas of the point template;
Resetting the tracking area based on the update area;
The tracking method characterized by comprising.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2012015486A JP5965653B2 (en) | 2012-01-27 | 2012-01-27 | TRACKING DEVICE AND TRACKING METHOD |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2012015486A JP5965653B2 (en) | 2012-01-27 | 2012-01-27 | TRACKING DEVICE AND TRACKING METHOD |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2013157725A true JP2013157725A (en) | 2013-08-15 |
JP5965653B2 JP5965653B2 (en) | 2016-08-10 |
Family
ID=49052553
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2012015486A Active JP5965653B2 (en) | 2012-01-27 | 2012-01-27 | TRACKING DEVICE AND TRACKING METHOD |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5965653B2 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017163510A (en) * | 2016-03-11 | 2017-09-14 | 富士通株式会社 | Imaging control program, imaging control method and imaging control device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2007282188A (en) * | 2006-03-15 | 2007-10-25 | Nikon Corp | Object tracker, object tracking method, object tracking program and optical equipment |
WO2008026434A1 (en) * | 2006-08-30 | 2008-03-06 | Nikon Corporation | Image tracking apparatus, image tracking method and camera |
JP2008113423A (en) * | 2006-10-03 | 2008-05-15 | Nikon Corp | Tracking device, image-capturing apparatus, and tracking method |
JP2009296029A (en) * | 2008-06-02 | 2009-12-17 | Panasonic Corp | Image pickup apparatus |
JP2011044764A (en) * | 2009-08-19 | 2011-03-03 | Panasonic Corp | Image capturing apparatus |
-
2012
- 2012-01-27 JP JP2012015486A patent/JP5965653B2/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2007282188A (en) * | 2006-03-15 | 2007-10-25 | Nikon Corp | Object tracker, object tracking method, object tracking program and optical equipment |
WO2008026434A1 (en) * | 2006-08-30 | 2008-03-06 | Nikon Corporation | Image tracking apparatus, image tracking method and camera |
JP2008113423A (en) * | 2006-10-03 | 2008-05-15 | Nikon Corp | Tracking device, image-capturing apparatus, and tracking method |
JP2009296029A (en) * | 2008-06-02 | 2009-12-17 | Panasonic Corp | Image pickup apparatus |
JP2011044764A (en) * | 2009-08-19 | 2011-03-03 | Panasonic Corp | Image capturing apparatus |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017163510A (en) * | 2016-03-11 | 2017-09-14 | 富士通株式会社 | Imaging control program, imaging control method and imaging control device |
Also Published As
Publication number | Publication date |
---|---|
JP5965653B2 (en) | 2016-08-10 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4525089B2 (en) | Auto focus system | |
JP5830373B2 (en) | Imaging device | |
JP5251215B2 (en) | Digital camera | |
US9317748B2 (en) | Tracking apparatus | |
US7978968B2 (en) | Auto focus device | |
US8284994B2 (en) | Image processing apparatus, image processing method, and storage medium | |
EP3018891B1 (en) | Tracking device, tracking method, and non-transitory recording medium having tracking program stored therein | |
JP2006258944A (en) | Autofocus system | |
JP2006267221A (en) | Auto focus system | |
JP2009111716A (en) | Imaging apparatus, program and template generating method | |
JP5851206B2 (en) | TRACKING DEVICE AND TRACKING METHOD | |
JP2007129310A (en) | Imaging apparatus | |
JP2005338352A (en) | Autofocus system | |
JP2006058431A (en) | Autofocusing system | |
JP4596246B2 (en) | Auto focus system | |
JP2013012940A (en) | Tracking apparatus and tracking method | |
JP6172973B2 (en) | Image processing device | |
JP2006267220A (en) | Auto focus system | |
JP5965653B2 (en) | TRACKING DEVICE AND TRACKING METHOD | |
JP5965654B2 (en) | TRACKING DEVICE, IMAGING DEVICE, TRACKING METHOD USED FOR IMAGING DEVICE | |
JP2009229570A (en) | Autofocus system | |
EP2091233A2 (en) | Imaging apparatus | |
JP4568916B2 (en) | Auto focus system | |
JP2009229568A (en) | Autofocus system | |
JP5027704B2 (en) | Auto focus system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20150122 |
|
A711 | Notification of change in applicant |
Free format text: JAPANESE INTERMEDIATE CODE: A712 Effective date: 20150423 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20151022 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20151124 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20160114 |
|
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: 20160614 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20160704 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 5965653 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |
|
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 |