JP2019068243A - Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program - Google Patents

Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program Download PDF

Info

Publication number
JP2019068243A
JP2019068243A JP2017191747A JP2017191747A JP2019068243A JP 2019068243 A JP2019068243 A JP 2019068243A JP 2017191747 A JP2017191747 A JP 2017191747A JP 2017191747 A JP2017191747 A JP 2017191747A JP 2019068243 A JP2019068243 A JP 2019068243A
Authority
JP
Japan
Prior art keywords
image
foreground
images
background
processing apparatus
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2017191747A
Other languages
Japanese (ja)
Inventor
隆男 佐々木
Takao Sasaki
隆男 佐々木
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2017191747A priority Critical patent/JP2019068243A/en
Publication of JP2019068243A publication Critical patent/JP2019068243A/en
Pending legal-status Critical Current

Links

Images

Abstract

To provide an image processing apparatus capable of automatically creating a suitable panoramic image in which the same person image does not appear multiple times.SOLUTION: An image processing apparatus includes: recognition means for recognizing a foreground and a background from each of a plurality of images captured while performing a panning operation; and combining means for combining a foreground, which is an image corresponding to the foreground recognized in any one of the plurality of images and a plurality of backgrounds corresponding to the background recognized in each of the plurality of images to generate a panoramic image. The combining means preferentially performs combination of the foreground in a region of a background where the angle of view overlaps with the foreground from among the plurality of backgrounds.SELECTED DRAWING: Figure 7

Description

本発明は、複数の画像を合成してパノラマ画像を作成する画像処理装置に関するものである。   The present invention relates to an image processing apparatus that combines a plurality of images to create a panoramic image.

デジタルカメラなどの撮像装置をパンニングしながら複数の画像を撮像し、撮像した画像を繋ぎ合わせてパノラマ画像を生成する方法が知られている。従来のパノラマ画像を生成する撮像装置では、撮像者がパノラマ画像に含まれるように撮影することを想定しておらず、そのようなパノラマ画像を生成することは困難であった。そこで、特許文献1では、回転機構を用いて、撮像装置を三脚など固定して回転させることで、撮像者を映しこんだパノラマ画像を生成する方法を開示している。   There is known a method of capturing a plurality of images while panning an imaging device such as a digital camera and connecting the captured images to generate a panoramic image. In a conventional imaging apparatus that generates a panoramic image, it is not assumed that a photographer takes a picture so as to be included in the panoramic image, and it is difficult to generate such a panoramic image. Therefore, Patent Document 1 discloses a method of generating a panoramic image in which an image capturing person is reflected by fixing and rotating an imaging device such as a tripod using a rotation mechanism.

特開2013−34158号公報JP, 2013-34158, A

しかしながら、特許文献1で開示した方法では、三脚などの固定装置が必要であり、利便性がよくない。一方で、撮像者が撮像装置を自分に向かって撮像(いわゆる「自撮り」)する方法が広く使われている。撮像者が撮像装置を自分に向けて撮影しながら回転することで、撮像者自身の画像を含むパノラマ画像を生成する方法が考えられる。   However, in the method disclosed in Patent Document 1, a fixing device such as a tripod is required, and the convenience is not good. On the other hand, a method is widely used in which a photographer captures an image of the imaging device toward himself (so-called "self-portrait"). A method is conceivable in which a panoramic image including an image of the image capturing person is generated by the image capturing person rotating while shooting the image capturing apparatus toward the user.

図14は、自撮りパノラマ撮像の課題を説明するための図である。図14(a)に示すように、撮像者がデジタルカメラなどの撮像装置をもって、自分に撮像装置を向けたままパンニング(回転)しながら撮像すれば、従来の方法でも撮像者を含むパノラマ画像が生成される。しかしながら、従来のパノラマ撮像方法を用いると、図14(b)に示すように、同一の撮像者の人物像が複数回現れてしまうパノラマ画像が生成されてしまう。   FIG. 14 is a diagram for explaining the problem of self-portrait panoramic imaging. As shown in FIG. 14 (a), if an image pickup person takes an image while panning (rotating) with an image pickup device facing himself / herself with an image pickup device such as a digital camera, a panoramic image including the image pickup person is It is generated. However, when the conventional panoramic imaging method is used, as shown in FIG. 14B, a panoramic image in which a person image of the same image pickup person appears a plurality of times is generated.

本発明は、上記の課題を鑑みてなされたものであり、同一の人物像が複数回現れない好適なパノラマ画像を作成することを目的とする。   The present invention has been made in view of the above problems, and an object of the present invention is to create a suitable panoramic image in which the same human figure does not appear multiple times.

上記課題を解決するため、本願発明は、パンニング動作をしながら撮像された複数の画像のそれぞれから前景と背景を認識する認識手段と、前記複数の画像のいずれか1つの画像において認識された前景に対応する画像である前景画像と、前記複数の画像のそれぞれにおいて認識された背景に対応する複数の背景画像を合成し、パノラマ画像を生成する合成手段と、を有し、前記合成手段は、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記前景画像を優先して合成することを特徴とする画像処理装置を提供する。   In order to solve the above problems, the present invention relates to recognition means for recognizing a foreground and a background from each of a plurality of images captured while panning, and a foreground recognized in any one of the plurality of images. Combining a foreground image which is an image corresponding to a plurality of background images corresponding to the background recognized in each of the plurality of images to generate a panoramic image, the combining means The present invention provides an image processing apparatus characterized in that the foreground image is preferentially synthesized in a region where the angle of view overlaps with the foreground image among the plurality of background images.

本発明の構成によれば、同一の人物像が複数回現れない好適なパノラマ画像を作成できる画像処理装置を提供することができる。   According to the configuration of the present invention, it is possible to provide an image processing apparatus capable of creating a suitable panoramic image in which the same person image does not appear multiple times.

本発明の実施形態に係るデジタルカメラの概略構成を示す背面斜視図である。FIG. 1 is a rear perspective view showing a schematic configuration of a digital camera according to an embodiment of the present invention. 本発明の実施形態に係るデジタルカメラのハードウェア構成を示すブロック図である。It is a block diagram showing hardware constitutions of a digital camera concerning an embodiment of the present invention. 従来方法を用いるパノラマ撮像中のデジタルカメラの動く方向と画像データの切り出し領域との関係を説明するための図である。It is a figure for demonstrating the relationship between the moving direction of the digital camera in panorama imaging using the conventional method, and the cutting-out area | region of image data. 従来方法を用いるパノラマ画像の合成処理の流れを説明する図である。It is a figure explaining the flow of synthetic processing of a panoramic image using the conventional method. 本発明における自撮りパノラマ撮像を説明するための図である。It is a figure for demonstrating the self-portrait panoramic imaging in this invention. 本発明の実施形態を説明するためのフローチャートである。It is a flowchart for describing the embodiment of the present invention. 本発明の実施形態における画像合成を説明するためのフローチャートである。It is a flow chart for explaining image composition in an embodiment of the present invention. 本発明の実施形態における処理対象の画像の領域について説明するための図である。It is a figure for demonstrating the area | region of the image of the process target in embodiment of this invention. 本発明の実施形態における背景領域のみを合成する場合について説明するための図である。It is a figure for demonstrating the case where only the background area | region in embodiment of this invention is synthesize | combined. 本発明の実施形態における合成において1枚目の画像の前景領域を合成画像に使用する場合について説明するための図である。It is a figure for demonstrating the case where the foreground area | region of the 1st image is used for a synthetic | combination image in synthetic | combination in embodiment of this invention. 本発明の実施形態における合成において3枚目の画像の前景領域を合成画像に使用する場合の一例について説明するための図である。It is a figure for demonstrating an example in the case where the foreground area | region of the 3rd image is used for a synthetic | combination image in synthetic | combination in embodiment of this invention. 本発明の実施形態における合成において3枚目の画像の前景領域を合成画像に使用する場合のもう一例について説明するための図である。It is a figure for demonstrating another example in the case where the foreground area | region of the 3rd image is used for a synthetic | combination image in synthetic | combination in embodiment of this invention. 本発明の実施形態における撮像者以外の人物像がパノラマ撮像の画角に存在する場合について説明するための図である。It is a figure for demonstrating the case where persons' persons other than the imaging person in embodiment of this invention exist in the view | field angle of panorama imaging. 自撮りパノラマ撮像の課題を説明するための図である。It is a figure for demonstrating the subject of self-portrait panoramic imaging.

以下では、添付の図面を参照しながら、本発明の好適な実施形態について詳細に説明する。   Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings.

図1は、本発明の実施形態に係るデジタルカメラの概略構成を示す背面斜視図である。   FIG. 1 is a rear perspective view showing a schematic configuration of a digital camera according to an embodiment of the present invention.

デジタルカメラ100の背面には、画像や各種の情報を表示する表示部101と、ユーザによる各種操作を受け付ける各種スイッチやボタン等の操作部材からなる操作部102が設けられている。また、デジタルカメラ100の背面には、撮像モード等を切り替えるモード切替スイッチ104と、回転操作可能なコントローラホイール103が設けられている。デジタルカメラ100の上面には、撮像指示を行うシャッタボタン121と、デジタルカメラ100の電源のオン/オフを切り替える電源スイッチ122と、被写体に対して閃光を照射するストロボ141が設けられている。   On the back of the digital camera 100, a display unit 101 for displaying an image and various information, and an operation unit 102 including operation members such as various switches and buttons for receiving various operations by the user are provided. Further, on the back of the digital camera 100, a mode change switch 104 for switching an imaging mode and the like, and a controller wheel 103 which can be operated to rotate are provided. On the upper surface of the digital camera 100, a shutter button 121 for instructing imaging, a power switch 122 for switching on / off the power of the digital camera 100, and a strobe 141 for emitting a flash to a subject are provided.

デジタルカメラ100は、有線あるいは無線通信を介して外部装置と接続可能であり、外部装置に画像データ(静止画データ、動画データ)等を出力することができる。デジタルカメラ100の下面には、蓋131により開閉可能な記録媒体スロット(不図示)が設けられており、記録媒体スロットに対してメモリカード等の記録媒体130を挿抜することができるようになっている。   The digital camera 100 can be connected to an external device via wired or wireless communication, and can output image data (still image data, moving image data) and the like to the external device. A recording medium slot (not shown) which can be opened and closed by a lid 131 is provided on the lower surface of the digital camera 100 so that the recording medium 130 such as a memory card can be inserted into and removed from the recording medium slot. There is.

記録媒体スロットに格納された記録媒体130は、デジタルカメラ100のシステム制御部210(図2参照)と通信可能である。なお、記録媒体130は、記録媒体スロットに対して挿抜可能なメモリカード等に限定されるものではなく、光学ディスクやハードディスク等の磁気ディスクであってもよく、更に、デジタルカメラ100の本体に内蔵されていてもよい。   The recording medium 130 stored in the recording medium slot can communicate with the system control unit 210 (see FIG. 2) of the digital camera 100. The recording medium 130 is not limited to a memory card or the like which can be inserted into and removed from the recording medium slot, and may be a magnetic disk such as an optical disk or a hard disk. It may be done.

図2は、デジタルカメラ100のハードウェア構成を示すブロック図である。デジタルカメラ100は、バリア201、撮像レンズ202、シャッタ203及び撮像部204を備える。バリア201は、撮像光学系を覆うことにより、撮像光学系の汚れや破損を防止する。撮像レンズ202は、ズームレンズ、フォーカスレンズを含むレンズ群により構成されており、撮像光学系を構成する。シャッタ203は、絞り機能を備え、撮像部204に対する露光量を調節する。撮像部204は、光学像を電気信号(アナログ信号)に変換する撮像素子であり、例えば、RGBの画素が規則的に配置されたベイヤー配列構造を有するCCDセンサやCMOSセンサ等のイメージセンサである。なお、シャッタ203は、機械式シャッタ(以下、メカシャッタという)であってもよいし、撮像素子のリセットタイミングの制御によって蓄積時間を制御する電子シャッタであってもよい。   FIG. 2 is a block diagram showing the hardware configuration of the digital camera 100. As shown in FIG. The digital camera 100 includes a barrier 201, an imaging lens 202, a shutter 203, and an imaging unit 204. The barrier 201 covers the imaging optical system to prevent the contamination and damage of the imaging optical system. The imaging lens 202 is constituted by a lens group including a zoom lens and a focus lens, and constitutes an imaging optical system. The shutter 203 has an aperture function, and adjusts the exposure amount to the imaging unit 204. The imaging unit 204 is an imaging device that converts an optical image into an electrical signal (analog signal), and is an image sensor such as a CCD sensor or a CMOS sensor having a Bayer array structure in which RGB pixels are regularly arranged. . The shutter 203 may be a mechanical shutter (hereinafter referred to as a mechanical shutter), or may be an electronic shutter that controls the accumulation time by controlling the reset timing of the imaging device.

または、撮像部204を、ステレオ画像が取得できる、1つ画素に複数の光電変換部に設けられる構造にすれば、後述する自動焦点検出(AF)処理がより素早くできる。   Alternatively, if the imaging unit 204 has a structure in which a plurality of photoelectric conversion units are provided in one pixel, which can acquire a stereo image, automatic focus detection (AF) processing to be described later can be performed more quickly.

デジタルカメラ100は、A/D変換器205、画像処理部206、メモリ制御部207、D/A変換器208、メモリ209及びシステム制御部210を備える。撮像部204からA/D変換器205へアナログ信号が出力され、A/D変換器205は、取得したアナログ信号をデジタル信号からなる画像データに変換して、画像処理部206またはメモリ制御部207へ出力する。   The digital camera 100 includes an A / D converter 205, an image processing unit 206, a memory control unit 207, a D / A converter 208, a memory 209, and a system control unit 210. An analog signal is output from the imaging unit 204 to the A / D converter 205, and the A / D converter 205 converts the acquired analog signal into image data composed of a digital signal, and the image processing unit 206 or the memory control unit 207. Output to

画像処理部206は、A/D変換器205から取得した画像データまたはメモリ制御部207から取得したデータに対して、画素補間やシェーディング補正等の補正処理、ホワイトバランス処理、γ補正処理、色変換処理等を行う。また、画像処理部206は、画像の切り出しや変倍処理を行うことで電子ズーム機能を実現する。更に、画像処理部206は撮像した画像の画像データを用いて所定の演算処理を行い、こうして得られた演算結果に基づいてシステム制御部210が露光制御や測距制御を行う。例えば、システム制御部210により、TTL(スルー・ザ・レンズ)方式のAF(オートフォーカス)処理、AE(自動露出)処理、EF(ストロボプリ発光)処理が行われる。画像処理部206は、撮像した画像の画像データを用いて所定の演算処理を行い、得られた演算結果を用いて、システム制御部210はTTL方式のAWB(オートホワイトバランス)処理を行う。   The image processing unit 206 performs correction processing such as pixel interpolation and shading correction, white balance processing, γ correction processing, and color conversion on image data acquired from the A / D converter 205 or data acquired from the memory control unit 207. Perform processing etc. Further, the image processing unit 206 realizes an electronic zoom function by performing image clipping and scaling processing. Furthermore, the image processing unit 206 performs predetermined arithmetic processing using the image data of the captured image, and the system control unit 210 performs exposure control and distance measurement control based on the calculation result thus obtained. For example, the system control unit 210 performs TTL (through-the-lens) AF (auto focus) processing, AE (automatic exposure) processing, and EF (flash pre-emission) processing. The image processing unit 206 performs predetermined arithmetic processing using image data of a captured image, and the system control unit 210 performs TTL AWB (Auto White Balance) processing using the obtained arithmetic result.

画像処理部206は、複数の画像からパノラマ画像を合成し、またその合成結果の判断を行う画像合成処理回路を有する。画像合成処理回路は、単純な加算平均合成だけでなく、合成対象の画像データの各領域において最も明るい値または暗い値を持つ画素を選択して1枚の画像データを生成する比較明合成や比較暗合成等の処理を行うことができる。また、合成結果を特定の基準に基づいて評価し、判定する。たとえば、合成された画像の数が所定数に満たさない場合や、合成後の画像の長さが基準値に満たさない場合に、合成に失敗したと判定する。なお、画像処理部206を備える構成の代わりに、システム制御部210によるソフトウェア処理によって画像合成処理の機能を実現する構成としてもよい。   The image processing unit 206 has an image combining processing circuit that combines a panoramic image from a plurality of images and determines the combining result. The image synthesis processing circuit selects not only simple addition average synthesis but also pixels having the brightest value or dark value in each area of the image data to be synthesized to generate one image data. Processing such as dark composition can be performed. Also, the combined result is evaluated and determined based on specific criteria. For example, when the number of combined images does not satisfy a predetermined number, or when the length of the combined image does not meet a reference value, it is determined that combining has failed. Note that, instead of the configuration including the image processing unit 206, the configuration of the image combining process may be realized by software processing by the system control unit 210.

A/D変換器205から出力される画像データは、画像処理部206及びメモリ制御部207を介して、或いは、メモリ制御部207を介して、メモリ209に書き込まれる。メモリ209は、表示部101に表示する画像データを格納する画像表示用メモリ(ビデオメモリ)を兼ねている。メモリ209は、所定枚数の静止画像、パノラマ画像(広角画像)、パノラマ画像合成結果を格納することができる記憶容量を備えている。なお、メモリ209は、システム制御部210が不揮発性メモリ211から読み出したプログラム等を展開する作業領域として用いることもできる。   Image data output from the A / D converter 205 is written to the memory 209 via the image processing unit 206 and the memory control unit 207 or via the memory control unit 207. The memory 209 also serves as an image display memory (video memory) for storing image data to be displayed on the display unit 101. The memory 209 has a storage capacity capable of storing a predetermined number of still images, a panoramic image (wide-angle image), and a panoramic image synthesis result. The memory 209 can also be used as a work area in which a program or the like read out from the non-volatile memory 211 by the system control unit 210 is developed.

メモリ209に格納されている画像表示用データ(デジタルデータ)は、D/A変換器208に送信される。D/A変換器208は、受信したデジタルデータをアナログ信号に変換して表示部101に供給し、これにより、表示部101に画像が表示される。表示部101は、液晶ディスプレイまたは有機ELディスプレイ等の表示装置であり、D/A変換器208からのアナログ信号に基づいて画像を表示する。表示部101における画像表示のオン/オフは、システム制御部210によって切り替えられ、画像表示をオフにすることで電力消費を低減させることができる。なお、撮像部204からA/D変換器205を通じてメモリ209に蓄積されるデジタル信号をD/A変換器208によりアナログ信号に変換して表示部101に逐次表示することにより、スルー画像を表示する電子ビューファインダ機能を実現することができる。   Image display data (digital data) stored in the memory 209 is transmitted to the D / A converter 208. The D / A converter 208 converts the received digital data into an analog signal and supplies the analog signal to the display unit 101, whereby an image is displayed on the display unit 101. The display unit 101 is a display device such as a liquid crystal display or an organic EL display, and displays an image based on an analog signal from the D / A converter 208. The image display on the display unit 101 is switched on / off by the system control unit 210, and power consumption can be reduced by turning off the image display. A through image is displayed by converting a digital signal accumulated in the memory 209 from the imaging unit 204 through the A / D converter 205 into an analog signal through the D / A converter 208 and sequentially displaying the analog signal on the display unit 101. An electronic view finder function can be realized.

デジタルカメラ100は、不揮発性メモリ211、システムタイマ212、システムメモリ213、検出部215及びストロボ制御部217を備える。不揮発性メモリ211は、電気的に消去や記憶が可能なメモリ(例えば、EEPROM等)であり、システム制御部210が実行するプログラムや動作用の定数等を格納する。また、不揮発性メモリ211は、システム情報を記憶する領域やユーザ設定情報を記憶する領域を有しており、システム制御部210は、デジタルカメラ100の起動時に不揮発性メモリ211に記憶された種々の情報や設定を読み出して復元する。   The digital camera 100 includes a non-volatile memory 211, a system timer 212, a system memory 213, a detection unit 215, and a flash control unit 217. The non-volatile memory 211 is a memory (for example, an EEPROM or the like) which can be electrically erased and stored, and stores a program executed by the system control unit 210, a constant for operation, and the like. The non-volatile memory 211 also has an area for storing system information and an area for storing user setting information. The system control unit 210 stores various information stored in the non-volatile memory 211 when the digital camera 100 is activated. Read and restore information and settings.

システム制御部210は、CPUを備え、不揮発性メモリ211に記憶されている各種のプログラムコードを実行することにより、デジタルカメラ100の全体的な動作を制御する。なお、システム制御部210が不揮発性メモリ211から読み出したプログラムや動作用の定数、変数等は、システムメモリ213上に展開される。システムメモリ213には、RAMが用いられる。更に、システム制御部210は、メモリ209やD/A変換器208、表示部101等を制御することにより、表示制御を行う。システムタイマ212は、各種の制御に用いる時間や内蔵された時計の時間を計測する。ストロボ制御部217は、被写体の明るさに応じて、ストロボ141の発光を制御する。検出部215は、ジャイロやセンサを含み、デジタルカメラ100の角速度情報、姿勢情報等を取得する。なお、角速度情報は、デジタルカメラ100によるパノラマ撮像時の角速度及び角加速度の情報を含む。また、姿勢情報は、水平方向に対するデジタルカメラ100の傾き等の情報を含む。   The system control unit 210 includes a CPU, and controls various operations of the digital camera 100 by executing various program codes stored in the non-volatile memory 211. The program read from the non-volatile memory 211 by the system control unit 210, constants for operation, variables, and the like are expanded on the system memory 213. A RAM is used for the system memory 213. Furthermore, the system control unit 210 performs display control by controlling the memory 209, the D / A converter 208, the display unit 101, and the like. A system timer 212 measures time used for various controls and time of a built-in clock. The flash control unit 217 controls the light emission of the flash 141 according to the brightness of the subject. The detection unit 215 includes a gyro and a sensor, and acquires angular velocity information, posture information, and the like of the digital camera 100. The angular velocity information includes information on angular velocity and angular acceleration at the time of panoramic imaging by the digital camera 100. The posture information also includes information such as the tilt of the digital camera 100 with respect to the horizontal direction.

図2に示される表示部101、操作部102、コントローラホイール103、シャッタボタン121、モード切替スイッチ104、電源スイッチ122及びストロボ141は、図1を参照して説明したものと同じである。   The display unit 101, the operation unit 102, the controller wheel 103, the shutter button 121, the mode switching switch 104, the power switch 122, and the electronic flash 141 shown in FIG. 2 are the same as those described with reference to FIG.

操作部102を構成する各種の操作部材は、例えば、表示部101に表示される種々の機能アイコンの選択に用いられ、所定の機能アイコンが選択されることにより、場面毎に機能が割り当てられる。即ち、操作部102の各操作部材は、各種の機能ボタンとして作用する。機能ボタンとしては、例えば、終了ボタン、戻るボタン、画像送りボタン、ジャンプボタン、絞込みボタン、属性変更ボタン、DISPボタン等が挙げられる。例えば、メニューボタンが押下されると、各種の設定を行うためのメニュー画面が表示部101に表示される。ユーザは、表示部101に表示されたメニュー画面と、上下左右の4方向ボタンやSETボタンとを用いて、直感的に設定操作を行うことができる。   Various operation members constituting the operation unit 102 are used, for example, to select various function icons displayed on the display unit 101, and functions are assigned to each scene by selecting a predetermined function icon. That is, each operation member of the operation unit 102 functions as various function buttons. Examples of the function buttons include an end button, a back button, an image feed button, a jump button, a narrow-down button, an attribute change button, and a DISP button. For example, when the menu button is pressed, a menu screen for performing various settings is displayed on the display unit 101. The user can intuitively perform the setting operation using the menu screen displayed on the display unit 101 and the four-direction button or the SET button on the top, bottom, left, and right.

回転操作が可能な操作部材であるコントローラホイール103は、4方向ボタンと共に選択項目を指定するとき等に使用される。コントローラホイール103を回転操作すると、操作量(回転角度や回転回数等)に応じた電気的なパルス信号が発生する。システム制御部210は、このパルス信号を解析して、デジタルカメラ100の各部を制御する。   The controller wheel 103, which is an operation member capable of rotating, is used together with a four-way button when designating a selection item. When the controller wheel 103 is rotated, an electrical pulse signal corresponding to the amount of operation (rotation angle, number of rotations, etc.) is generated. The system control unit 210 analyzes this pulse signal to control each unit of the digital camera 100.

シャッタボタン121は、第1スイッチSW1と第2スイッチSW2を有する。第1スイッチSW1は、シャッタボタン121の操作途中の半押し状態でオンとなり、これにより、撮像準備を指示する信号がシステム制御部210に送信される。システム制御部210は、第1スイッチSW1がオンになった信号を受信すると、AF処理、AE処理、AWB処理、EF処理等の動作を開始する。第2スイッチSW2は、シャッタボタン121の操作が完了する全押し状態でオンとなり、これにより、撮像開始を指示する信号がシステム制御部210に送信される。システム制御部210は、第2スイッチSW2がオンになった信号を受信すると、撮像部204からの信号読み出しから記録媒体130への画像データの書き込みまでの一連の撮像動作を行う。   The shutter button 121 has a first switch SW1 and a second switch SW2. The first switch SW1 is turned on when the shutter button 121 is halfway pressed, and a signal instructing preparation for imaging is transmitted to the system control unit 210. When receiving the signal that the first switch SW1 is turned on, the system control unit 210 starts operations such as AF processing, AE processing, AWB processing, and EF processing. The second switch SW2 is turned on in the fully-pressed state in which the operation of the shutter button 121 is completed, whereby a signal instructing start of imaging is transmitted to the system control unit 210. When the system control unit 210 receives a signal that the second switch SW2 is turned on, the system control unit 210 performs a series of imaging operations from signal reading from the imaging unit 204 to writing of image data to the recording medium 130.

モード切替スイッチ104は、デジタルカメラ100の動作モードを、静止画撮像モード、動画撮像モード、再生モード等の各種モードの間で切り替えるためのスイッチである。静止画撮像モードは、オート撮像モード等の他に、パノラマ撮像によりパノラマ画像を合成するパノラマ画像撮像モードを含む。   The mode switching switch 104 is a switch for switching the operation mode of the digital camera 100 among various modes such as a still image capturing mode, a moving image capturing mode, and a reproduction mode. The still image pickup mode includes, in addition to the auto pickup mode and the like, a panoramic image pickup mode for synthesizing panoramic images by panoramic pickup.

デジタルカメラ100は、電源部214及び電源制御部218を備える。電源部214は、アルカリ電池やリチウム電池等の一次電池、NiCd電池やNiMH電池、Li電池等の二次電池、或いは、ACアダプタ等であり、電源制御部218へ電力を供給する。電源制御部218は、電源部214における電池の装着の有無、電池の種類、電池残量等を検出し、その検出結果及びシステム制御部210の指示に基づいて、必要な電圧を必要な期間、記録媒体130を含む各部へ供給する。   The digital camera 100 includes a power supply unit 214 and a power control unit 218. The power supply unit 214 is a primary battery such as an alkaline battery or a lithium battery, a secondary battery such as a NiCd battery, a NiMH battery or a Li battery, or an AC adapter, and supplies power to the power control unit 218. The power supply control unit 218 detects the presence or absence of a battery attached to the power supply unit 214, the type of the battery, the remaining battery capacity, and the like, and based on the detection result and the instruction of the system control unit 210, a necessary period It supplies to each part including the recording medium 130.

デジタルカメラ100は、記録媒体130が記録媒体スロット(不図示)に装着された際に、記録媒体130とシステム制御部210との間の通信を可能にするための記録媒体I/F216を備える。記録媒体130の詳細については、図1を参照して既に説明しているため、ここでの説明を省略する。   The digital camera 100 includes a recording medium I / F 216 for enabling communication between the recording medium 130 and the system control unit 210 when the recording medium 130 is loaded into a recording medium slot (not shown). The details of the recording medium 130 have already been described with reference to FIG.

次に、パノラマ撮像の方法と、複数の撮像画像からパノラマ画像を合成する方法について説明する。最初に、パノラマ画像を合成するために撮像画像の画像データから所定の領域を切り出す処理について説明する。   Next, a method of panoramic imaging and a method of combining panoramic images from a plurality of captured images will be described. First, a process of cutting out a predetermined area from image data of a captured image to synthesize a panoramic image will be described.

図3は、従来方法を用いるパノラマ撮像中のデジタルカメラ100の動く方向と画像データの切り出し領域との関係を説明するための図である。   FIG. 3 is a diagram for explaining the relationship between the moving direction of the digital camera 100 during panoramic imaging using the conventional method and the cutout area of image data.

図3(a)は、撮像部204が有する撮像素子の有効画像領域を示しており、“Wv”は水平方向の有効画素数であり、“Hv”は垂直方向の有効画素数である。図3(b)は、撮像画像の画像データから切り出した切り出し領域を示しており、“Wcrop”は水平方向の切り出し画素数であり、“Hcrop”は垂直方向の切り出し画素数である。   FIG. 3A shows the effective image area of the imaging element of the imaging unit 204, where "Wv" is the number of effective pixels in the horizontal direction, and "Hv" is the number of effective pixels in the vertical direction. FIG. 3B shows a cutout area cut out from the image data of the captured image, “Wcrop” is the number of cutout pixels in the horizontal direction, and “Hcrop” is the number of cutout pixels in the vertical direction.

図3(c)は、矢印で示す水平方向にデジタルカメラ100を移動させながらパノラマ撮像を行った場合の画像データに対する切り出し領域を示す図である。図3(c)においてハッチングにて示した領域S1が画像データからの切り出し領域を示しており、下記の(式1)および(式2)を満たす。
Wv>Wcrop・・・・・・(式1)
Hv=Hcrop・・・・・・(式2)
FIG. 3C is a diagram showing a cutout area for image data when performing panoramic imaging while moving the digital camera 100 in the horizontal direction indicated by an arrow. An area S1 hatched in FIG. 3C indicates a cutout area from the image data, and the following (Expression 1) and (Expression 2) are satisfied.
Wv> Wcrop ············ (Equation 1)
Hv = Hcrop ··········· (Equation 2)

同様に、図3(d)は、矢印で示す鉛直方向にデジタルカメラ100を移動させながらパノラマ撮像を行った場合の画像データに対する切り出し領域を示す図である。図3(d)においてハッチングにて示した領域S2が画像データの切り出し領域を示しており、下記の(式3)および(式4)を満たす。
Wv=Wcrop・・・・・・(式3)
Hv>Hcrop・・・・・・(式4)
Similarly, FIG. 3D is a view showing a cutout area for image data when performing panoramic imaging while moving the digital camera 100 in the vertical direction indicated by an arrow. An area S2 indicated by hatching in FIG. 3D indicates a cutout area of the image data, and the following (Expression 3) and (Expression 4) are satisfied.
Wv = Wcrop ············ (Equation 3)
Hv> Hcrop ············ (Equation 4)

撮像画像の画像データの切り出し領域は、画像データ毎に異なるようにしてもよい。また、パノラマ撮像の開始時とパノラマ撮像の終了時の画像データについては、画角を広くするために切り出し領域を広くしてもよい。画像データの切り出し領域の決定方法は、例えば、撮像直後のデジタルカメラ100の角度と1フレーム前のデジタルカメラ100の角度との差等により決定することができる。パノラマ画像の合成処理に必要な画像データのみを切り出して保存することにより、メモリ209の記憶容量を節約することができる。   The cutout area of the image data of the captured image may be different for each image data. In addition, with regard to the image data at the start of panoramic imaging and at the end of panoramic imaging, the cutout region may be widened in order to widen the angle of view. The method of determining the cutout region of the image data can be determined, for example, by the difference between the angle of the digital camera 100 immediately after imaging and the angle of the digital camera 100 one frame before, or the like. The storage capacity of the memory 209 can be saved by cutting out and storing only the image data necessary for the synthesis process of the panoramic image.

次に、パノラマ画像の合成方法について説明する。システム制御部210は、パノラマ撮像時に保存された切り出し領域をメモリ209から読み出し、読み出した画像データにパノラマ合成を行う。   Next, a method of combining panoramic images will be described. The system control unit 210 reads out from the memory 209 the cutout area stored at the time of panoramic imaging, and performs panoramic combination on the read out image data.

図4は、従来方法を用いたパノラマ画像の合成処理の流れを説明する図である。図4では、ドットハッチングされた領域は、被写界にある並木を模式的に表した領域であり、斜線ハッチングされた領域は、画像データの切り出し領域を表している。図4(a)は、ユーザがシャッタボタン121を押下し、第1スイッチSW1がオンにされた状態を示し、ユーザは、主被写体に対してピント合わせを行うことを示している。図4(b)は、シャッタボタン121の第2スイッチSW2がオンにされた位置を示しており、ユーザが合成しようとしているパノラマ画像の一方の端に合わせて画角を設定している。図4(b)では、撮像部204は画像410を撮像する。図4(c)乃至図4(e)では、ユーザが合成しようとしているパノラマ画像の他方の端に向けてデジタルカメラ100を移動させながら、パノラマ撮像を行っている状態を模式的に示している。図4(e)は、ユーザがシャッタボタン121の押下をやめ、パノラマ撮像が終了した状態を示している。図4(b)乃至図4(e)では、撮像部204が画像410乃至470計7枚の画像を撮像したが、画像430、450および460は不図示である。画像処理部206は、撮像部204が撮像した画像410乃至470に対して切り出し処理を行い、切り出し領域411乃至471を生成する。システム制御部210において、切り出し領域の幅は、予め定めてもよいが、パノラマ撮像中のデジタルカメラ100の移動速度などに応じて変化させてもよい。   FIG. 4 is a diagram for explaining the flow of panoramic image synthesis processing using the conventional method. In FIG. 4, the dot-hatched area is an area schematically representing a row tree in the field, and the hatched area represents a cutout area of the image data. FIG. 4A shows a state in which the user presses the shutter button 121 and the first switch SW1 is turned on, and shows that the user performs focusing on the main subject. FIG. 4B shows the position where the second switch SW2 of the shutter button 121 is turned on, and the angle of view is set in accordance with one end of the panoramic image to be synthesized by the user. In FIG. 4B, the imaging unit 204 captures an image 410. FIGS. 4C to 4E schematically show a state in which panoramic imaging is performed while moving the digital camera 100 toward the other end of the panoramic image that the user is trying to combine. . FIG. 4E shows a state in which the user has stopped pressing the shutter button 121 and panoramic imaging has been completed. In FIGS. 4B to 4E, the imaging unit 204 captures a total of seven images 410 to 470, but the images 430, 450, and 460 are not shown. The image processing unit 206 performs cutout processing on the images 410 to 470 captured by the imaging unit 204, and generates cutout regions 411 to 471. In the system control unit 210, the width of the cutout region may be determined in advance, but may be changed according to the moving speed of the digital camera 100 during panoramic imaging and the like.

図4(f)は、画像処理部206が、撮像部204が撮像した複数の画像を合成してできたパノラマ画像を示している。ここで、システム制御部210は、合成を行う前に、画像に対して位置合わせを行う。また、手振れなどのため、切り出し領域411乃至471の上辺と下辺とは合っていないため、画像処理部206は、縦方向に対しても切り出し処理を行う。その結果、画像処理部206は、領域400が示したようなパノラマ画像を生成する。   FIG. 4F shows a panoramic image formed by combining the plurality of images captured by the imaging unit 204 by the image processing unit 206. Here, the system control unit 210 aligns the image before combining. In addition, since the upper side and the lower side of the cutout regions 411 to 471 do not coincide with each other because of camera shake or the like, the image processing unit 206 performs the cutout processing also in the vertical direction. As a result, the image processing unit 206 generates a panoramic image as indicated by the area 400.

システム制御部210は、画像処理部206が検出した複数の動きベクトルに基づいて、位置合わせを行う。一例としては、画像処理部206は、切り出し領域を任意のサイズの小ブロックに分割し、小ブロック毎に輝度の差分絶対値和(Sum of Absolute Difference、以下、SADをいう)が最小となる対応点を算出する。システム制御部210は、算出したSADが最小となる対応点より、動きベクトルを算出することができる。システム制御部210は、SADのほかに、差分二乗和(Sum of Squared Difference、以下SSDをいう)や正規化相互相関(Normalized Cross Correlation、以下NCCをいう)などを用いてもよい。   The system control unit 210 performs alignment based on the plurality of motion vectors detected by the image processing unit 206. As an example, the image processing unit 206 divides the cutout region into small blocks of an arbitrary size, and minimizes the sum of absolute differences of luminance (hereinafter referred to as SAD) for each small block. Calculate points. The system control unit 210 can calculate the motion vector from the corresponding point at which the calculated SAD is minimum. The system control unit 210 may use, in addition to SAD, a sum of squared difference (hereinafter referred to as SSD), a normalized cross correlation (hereinafter referred to as NCC), or the like.

図4では、説明を容易にするため、切り出し領域411乃至471の互いに重畳する領域がなく、かつ、互いに隣接している例を示している。もし、重畳する領域が存在していれば、重畳する領域の中央を境目として、画像処理部206は、その左側に片方の切り出し領域、右側にもう片方の切り出し領域の画素情報を合成画像に出力する。もしくは、画像処理部206は、境目上に両方の切り出し領域の画素情報を50%ずつ合成した値を出力し、境目からの距離が離れるに従って境目の左側では片方の切り出し領域を、境目の右側ではもう片方の切り出し領域の割合を大きくしながら合成を行う。   In FIG. 4, in order to facilitate the description, an example is shown in which there are no overlapping regions of the cutout regions 411 to 471 and they are adjacent to each other. If there is a region to be superimposed, the image processing unit 206 outputs pixel information of one cutout region on the left side and the other cutout region on the right side to the composite image, using the center of the superposition region as a boundary. Do. Alternatively, the image processing unit 206 outputs a value obtained by combining pixel information of both cutout regions by 50% on the boundary, and one cutout region is on the left side of the boundary as the distance from the boundary is longer, and on the right side of the boundary The synthesis is performed while increasing the ratio of the other cutout region.

しかしながら、前述のパノラマ画像の合成の方法を、自撮りに適用すると、以下のような課題が生じる。自撮りでパンニングをする場合、撮像者が自らの画像を写すため、撮像部をパンニングの全過程で自分に向かって撮像を行う。そのために、自撮りでパンニング動作をして撮像した画像では、従来のパノラマとは異なり、撮像者自身の像が多数の画像に入る。   However, when the above-described panoramic image synthesis method is applied to self-shooting, the following problems occur. In the case of panning with self-portrait, in order to capture an image of the photographer, the imaging unit captures an image of the imaging unit toward itself in the entire process of panning. Therefore, in the image captured by the panning operation with self-portrait, unlike the conventional panorama, the image of the photographer's own is included in many images.

図5は、自撮りパノラマ撮像を説明するための図である。図5(a)に示したように、撮像者が撮像装置をもって自分に撮像装置を向けてパンニング(回転)しながら撮像する。撮像者が期待する成果物のパノラマ画像は、図5(b)に示したような、背景画像(並木)の前に、撮像者の人物像が1つだけ現れる画像である。しかしながら、従来のパノラマ撮像方法を用いると、パンニング中撮像したすべての画像に撮像者の人物像が入ってしまい、撮像者の人物像が複数回映るようになってしまう。   FIG. 5 is a diagram for explaining self-portrait panoramic imaging. As shown in FIG. 5A, the image pickup person points the image pickup apparatus to himself / herself with the image pickup apparatus and performs imaging while panning (rotation). The panoramic image of the product expected by the photographer is an image in which only one person image of the photographer appears before the background image (lined tree) as shown in FIG. 5 (b). However, when the conventional panoramic imaging method is used, the image of the image capturing person is included in all the images captured during panning, and the image of the image capturing person is displayed a plurality of times.

前述したような課題を解決するために、本実施形態では、図4が示した従来技術とは異なり、パノラマ撮像中、前景画像と背景画像とを抽出し、背景画像を合成するとともに、前景画像を選択し合成を行う。以下では、本実施形態のフローについて図を用いて詳細に説明する。   In order to solve the problems as described above, in the present embodiment, different from the prior art shown in FIG. 4, the foreground image and the background image are extracted during panorama imaging, the background image is synthesized, and the foreground image Select and compose. Hereinafter, the flow of the present embodiment will be described in detail with reference to the drawings.

図6は、本実施形態を説明するためのフローチャートである。ユーザが、モード切替スイッチ104で、自撮りパノラマモードを選択した場合に、デジタルカメラ100が図6の処理を実行する。あるいは、ユーザが、操作部102に設けたボタンなどの操作で、デジタルカメラ100のメニュー画面、または表示部101兼用のタッチパネルから自撮りパノラマモードを選択する。   FIG. 6 is a flowchart for explaining the present embodiment. When the user selects the self-portrait panorama mode with the mode switching switch 104, the digital camera 100 executes the processing of FIG. Alternatively, the user selects the self-portrait panoramic mode from the menu screen of the digital camera 100 or the touch panel also serving as the display unit 101 by operating the button or the like provided on the operation unit 102.

ステップS601で、ユーザがパノラマ撮像のための設定を行う。たとえば、ユーザがパノラマ合成画像の画角やパンニング方向などの設定を行う。もし、ステップS601で、ユーザが設定をしなかった場合は、デジタルカメラ100は、パノラマ撮像において、初期の設定を用いるか、前回のパノラマ撮像のときの設定を用いる。   In step S601, the user performs setting for panoramic imaging. For example, the user sets the angle of view and panning direction of the panoramic composite image. If it is determined in step S601 that the user has not made settings, the digital camera 100 uses initial settings or uses settings from the previous panorama imaging in panorama imaging.

続いて、ステップS602で、システム制御部210は、第1スイッチSW1が押されたか否かの判定を行い、第1スイッチSW1が押されたと判定された場合、ステップS603の処理に移る。第1スイッチSW1が押されなかったと判定された場合、ステップS601の処理に戻る。   Subsequently, in step S602, the system control unit 210 determines whether or not the first switch SW1 is pressed. If it is determined that the first switch SW1 is pressed, the process proceeds to step S603. If it is determined that the first switch SW1 has not been pressed, the process returns to the process of step S601.

ステップS603で、検出部215は、姿勢検知処理を行う。姿勢検知処理では検出部215は、デジタルカメラ100のパンニング方向を判断する。ユーザがステップS601でデジタルカメラ100のパンニング方向を設定したのであれば、ここで、システム制御部210は、デジタルカメラ100に設定されたパンニング方向と実際のパンニング方向とを比較し、異なる場合では適宜に警告を出す。   In step S603, the detection unit 215 performs posture detection processing. In the attitude detection process, the detection unit 215 determines the panning direction of the digital camera 100. If the user has set the panning direction of the digital camera 100 in step S601, then the system control unit 210 compares the panning direction set in the digital camera 100 with the actual panning direction, and if different, appropriately. Give a warning to

ステップS604で、デジタルカメラ100は、自動露出処理制御(AE)処理と自動焦点検出(AF)処理とを行う。   In step S604, the digital camera 100 performs automatic exposure processing control (AE) processing and automatic focus detection (AF) processing.

ステップS605で、システム制御部210は、ステップS604のAE処理結果に基づいて撮像感度などの撮像条件を決定する。   In step S605, the system control unit 210 determines imaging conditions such as imaging sensitivity based on the AE processing result in step S604.

ステップS606で、システム制御部210は、第2スイッチSW2が押されたか否かの判定を行う。ステップS606において、第2スイッチSW2が押されなかったと判定された場合、システム制御部210は、ステップS602に戻り、第1スイッチSW1が押されたままか否か(いわゆる半押しのままか否か)判定する。ステップS606において、システム制御部210は、第2スイッチSW2が押されたと判定された場合、ステップS607に進み、ステップS605で決定した撮像条件で撮像部204が撮像する。   In step S606, the system control unit 210 determines whether the second switch SW2 has been pressed. If it is determined in step S606 that the second switch SW2 has not been pressed, the system control unit 210 returns to step S602, and whether or not the first switch SW1 is kept pressed (whether so-called half pressed or not) )judge. When it is determined in step S606 that the system control unit 210 determines that the second switch SW2 is pressed, the process proceeds to step S607, and the imaging unit 204 captures an image under the imaging condition determined in step S605.

ステップS608でシステム制御部210は撮像が継続中かを判定し、継続している場合はステップS607に処理を戻し、撮像が終了したと判定した場合はステップS609に進む。たとえば、システム制御部210は、ステップS601のユーザ設定に基づいて、撮像が継続か終了かを判断する。一例としては、ステップS601で設定した画角に達したら、システム制御部210は撮像が終了したと判断する。自撮りパノラマの場合、撮像者が図5(a)に示したように回転しながらパンニングすることが多く、回転角度が360度になったら撮像が終了するほうが好ましい。この場合、ステップS608で、システム制御部210は、検出部215に設けたジャイロの情報に用いて撮像の終了を判断するのもよい。または、システム制御部210は、ユーザが第2スイッチSW2の押下の中止をもって、撮像の終了を判断する。   In step S608, the system control unit 210 determines whether imaging is continuing, and if so, the process returns to step S607, and if it is determined that imaging has ended, the process proceeds to step S609. For example, based on the user setting in step S601, the system control unit 210 determines whether the imaging is continued or ended. As an example, when the angle of view set in step S601 is reached, the system control unit 210 determines that the imaging has ended. In the case of a self-portrait panorama, as shown in FIG. 5A, the photographer often pans while rotating, and it is preferable that imaging ends when the rotation angle reaches 360 degrees. In this case, in step S608, the system control unit 210 may use information of a gyro provided in the detection unit 215 to determine the end of imaging. Alternatively, the system control unit 210 determines the end of imaging when the user cancels the pressing of the second switch SW2.

ステップS609では、システム制御部210は、ステップS607で撮像部204が撮像した画像に対して合成を行う。ステップS601乃至ステップS608での処理は、従来のパノラマ撮像と大差がなく、ステップS609での処理は本実施形態の特徴的な部分である。以下では、図とフローチャートを用いてステップS609について詳細に説明する。   In step S609, the system control unit 210 performs composition on the image captured by the imaging unit 204 in step S607. The processes in steps S601 to S608 are substantially the same as the conventional panoramic imaging, and the process in step S609 is a characteristic part of this embodiment. In the following, step S 609 will be described in detail using the drawings and the flowchart.

図7は、本実施形態におけるステップS609での画像合成の処理について説明するためのフローチャートである。まず、ステップS701で、システム制御部210は、デジタルカメラ100が自撮りパノラマモードに設定されているかどうかについて判断する。デジタルカメラ100が自撮りパノラマモードでなければ、図4に示したような従来のパノラマ合成方法で行うことになり、フローはステップS707に進む。自撮りパノラマモードの場合、フローはステップS702に進む。ステップS702で、システム制御部210が、撮像の順に処理対象の画像を選択する。   FIG. 7 is a flowchart for explaining the process of image composition in step S609 in the present embodiment. First, in step S701, the system control unit 210 determines whether the digital camera 100 is set to the self-portrait panorama mode. If the digital camera 100 is not in the self-portrait panorama mode, the conventional panorama synthesis method as shown in FIG. 4 is used, and the flow proceeds to step S707. In the case of the self-portrait panoramic mode, the flow proceeds to step S702. In step S702, the system control unit 210 selects an image to be processed in the order of imaging.

図8は、本実施形態における処理対象の画像に対して設定する領域について説明するための図である。ステップS702でシステム制御部210が選択した処理対象の画像に対しては、後述の処理で人物像が重複して現れないようにするために、前景領域と背景領域との特定が必要である。同時に、システム制御部210が位置合わせのための動きベクトルの探索領域を定める。図8(a)乃至図8(c)は、前景領域、および動きベクトルの探索領域、背景領域の設定の一例である。図8(a)では、システム制御部210が、公知の顔検出処理などを用いて人物像の領域を抽出し、人物像の幅と画像の高さとを持つ矩形領域を前景領域として設定することを示している。あるいは、パノラマ画像の撮像を行う前に、予めフォーカスレンズを移動させながら撮像を繰り返すスキャンAFを行って領域ごとの被写体距離を判定し、所定値以下の距離情報に対応する領域を人物像の領域として抽出してもよい。   FIG. 8 is a diagram for explaining an area set for an image to be processed in the present embodiment. For the image to be processed selected by the system control unit 210 in step S702, it is necessary to specify the foreground area and the background area in order to prevent overlapping of human images in the process described later. At the same time, the system control unit 210 determines a motion vector search area for alignment. FIGS. 8A to 8C are examples of setting of the foreground area, the search area of the motion vector, and the background area. In FIG. 8A, the system control unit 210 extracts a human image area using known face detection processing or the like, and sets a rectangular area having a human image width and an image height as a foreground area. Is shown. Alternatively, before capturing a panoramic image, scan AF which repeats imaging while moving the focus lens in advance is performed to determine the subject distance for each area, and an area corresponding to distance information less than a predetermined value is an area of a human image It may be extracted as

図8(b)では、システム制御部210は、前景領域以外の画像の部分を動きベクトルの探索領域として設定する。図8(c)では、システム制御部210は、人物像の両側の矩形の部分を背景領域として設定する様子を示している。なお、図8は一例にすぎず、図8では説明を簡略化するために前景領域以外の画像の全部を動きベクトルの探索領域として設定しているが、それに限られるものではない。例えば、人物像の輪郭に沿って前景領域を設定するようにしてもよい。なお、前景領域にあたる人物の姿勢や表情などは、画像によって大きく変化する可能性があり、動きベクトルの検出には不適であるため、動きベクトルの探索領域には含めないようにすることが望ましい。   In FIG. 8B, the system control unit 210 sets a portion of the image other than the foreground area as a motion vector search area. FIG. 8C shows that the system control unit 210 sets rectangular portions on both sides of the human image as a background area. Note that FIG. 8 is only an example, and in FIG. 8 all images other than the foreground area are set as the search area for motion vectors in order to simplify the description, but the present invention is not limited to this. For example, the foreground area may be set along the contour of the human image. Note that the posture or expression of the person corresponding to the foreground area may greatly change depending on the image and is not suitable for detecting a motion vector, so it is desirable not to include it in the motion vector search area.

システム制御部210が、動きベクトルの探索領域の全部または一部において、複数の小ブロックを設定する。システム制御部210は、1枚の画像に設定された複数の小ブロックのいずれかを選択し、もう1枚の画像の動きベクトルの探索領域において、この選択した小ブロックと同じ位置であって、かつ、この小ブロックより広い探索ブロックを設定する。システム制御部210は、もう1枚の画像で、一方の画像の選択した小ブロックと最も相関が高くなる(SADの値が最小となる)領域を抽出する。システム制御部210は、抽出した領域の中心である対応点の座標と、選択した小ブロックの中心位置の座標から、その小ブロックに対応する動きベクトルを算出することができる。システム制御部210は、これを全ての小ブロックに対して行い、全ての小ブロックに対応する動きベクトルを算出する。   The system control unit 210 sets a plurality of small blocks in all or part of the motion vector search area. The system control unit 210 selects one of a plurality of small blocks set in one image, and the same position as the selected small block in the search area of the motion vector of the other image, And set a search block wider than this small block. The system control unit 210 extracts, in the other image, an area where the correlation with the selected small block of one image is the highest (the value of SAD is the smallest). The system control unit 210 can calculate a motion vector corresponding to the small block from the coordinates of the corresponding point which is the center of the extracted area and the coordinates of the center position of the selected small block. The system control unit 210 performs this for all the small blocks, and calculates motion vectors corresponding to all the small blocks.

ステップS703で、システム制御部210は、ステップS702で選択した処理対象の画像の前景領域を合成画像に使用するかどうかについて判断する。たとえば、ユーザが予め、1枚目、最後、もしくは撮影開始から所定時間後に撮像されたいずれか1つの画像の人物像を合成に使用するように、メニュー画面等で設定したものとする。ステップS703で、システム制御部210は、こうしたユーザの設定に基づいて処理対象の画像の前景領域を合成に使用するかどうかについて判断する。処理対象の画像の前景領域を合成に使用する場合は、ステップS704に進み、システム制御部210は、処理対象の画像の全部を合成に使用することを示すフラグを付与する。逆に、処理対象の画像の前景領域を合成に使用しない場合は、ステップS705に進み、システム制御部210は、処理対象の背景領域のみを合成に使用することを示すフラグを付与する。次に、ステップS706で、システム制御部210がすべての画像に対して処理が済んでいるかどうかについて判断し、済んでいなければステップ702に戻り、済んでいればステップS707に進む。ステップS707では、システム制御部210が位置合わせ及び合成を行う。以下では、図を用いて、合成画像の生成について詳細に説明する。   In step S703, the system control unit 210 determines whether the foreground area of the image to be processed selected in step S702 is to be used for the composite image. For example, it is assumed that the user sets in advance on the menu screen or the like so that the first image, the last image, or the human image of any one image captured after a predetermined time from the start of shooting is used for composition. In step S703, the system control unit 210 determines whether to use the foreground area of the image to be processed for composition based on the settings of the user. If the foreground area of the image to be processed is used for composition, the process proceeds to step S704, and the system control unit 210 assigns a flag indicating that all of the image to be processed is used for composition. Conversely, when the foreground area of the image to be processed is not used for composition, the process proceeds to step S705, and the system control unit 210 assigns a flag indicating that only the background area to be processed is used for composition. Next, in step S706, the system control unit 210 determines whether all the images have been processed. If not, the process returns to step 702. If it is completed, the process proceeds to step S707. In step S 707, the system control unit 210 performs alignment and combination. Hereinafter, generation of a composite image will be described in detail with reference to the drawings.

図9は、本実施形態における背景領域のみを合成する場合について説明するための図である。図9(a)乃至図9(d)に示した画像では、パノラマ撮像で得られた4枚の画像のそれぞれを示す。この4枚の画像は、図7のステップS705で前景領域を合成に使用せず、背景のみを合成に使用するフラグを付与された画像である。図9(e)乃至図9(h)のそれぞれは、図9(a)乃至図9(d)のそれぞれを合成に用いた後の合成画像を示す。まず、図9(a)は、前景領域に相当する人物像の両側に背景領域aとb(グレーの部分)が存在することを示している。そして、図9(e)では、図9(a)の画像の背景領域だけが合成に使われているよう様子を示している。図9(e)は、前景領域も示しているが、後述の説明のように、この前景領域は最終的に上書きされる。したがって、画像の前景領域は、合成に使わないと判明した後に削除してもよい。図9(b)では、図9(a)のつぎに撮像された画像を示し、同様にこの画像の前景領域の両側に背景領域aとb(グレーの部分)が存在する。図9(b)では、前景領域の両側に位置する背景領域のうち、図9(a)の背景領域と重複しない領域を背景領域aとbとして設定している。図9(f)は、図9(a)と図9(b)とが示した画像の背景領域を合成した画像を示している。システム制御部210は、同様な処理を図9(c)と図9(d)とが示した画像に対して行い、最終的に図9(h)が示したような合成画像を生成する。図9(h)では、図9(a)乃至図9(d)のいずれの前景領域も存在しなく、つなぎ目が自然な背景領域の合成画像が得られる。なお、図9(d)に示す4枚目の画像までを合成した時点で、4枚目の左側の背景領域と、1枚目の右側の背景領域との間のギャップが無くなったため、5枚目以降の画像では前景領域の右側の背景領域のみを合成に用いればよい。   FIG. 9 is a diagram for describing the case of combining only the background area in the present embodiment. The images shown in FIG. 9A to FIG. 9D show each of the four images obtained by panoramic imaging. These four images do not use the foreground area for combining in step S 705 in FIG. 7, and are images provided with a flag that uses only the background for combining. Each of FIG. 9 (e) to FIG. 9 (h) shows a composite image after using each of FIG. 9 (a) to FIG. 9 (d) for composition. First, FIG. 9A shows that background areas a and b (gray parts) exist on both sides of a person image corresponding to a foreground area. FIG. 9E shows that only the background area of the image of FIG. 9A is used for composition. FIG. 9 (e) also shows the foreground area, but this foreground area is finally overwritten as described later. Thus, the foreground region of the image may be deleted after it is determined that it will not be used for compositing. FIG. 9B shows an image captured next to FIG. 9A. Similarly, background areas a and b (gray parts) exist on both sides of the foreground area of this image. In FIG. 9B, of the background areas located on both sides of the foreground area, areas not overlapping with the background area of FIG. 9A are set as background areas a and b. FIG. 9 (f) shows an image obtained by combining the background areas of the images shown in FIGS. 9 (a) and 9 (b). The system control unit 210 performs the same processing on the images shown in FIG. 9C and FIG. 9D, and finally generates a composite image as shown in FIG. In FIG. 9H, there is no foreground area in FIGS. 9A to 9D, and a composite image of a background area with natural joints is obtained. Since the gap between the background area on the left side of the fourth sheet and the background area on the right side of the first sheet disappears when the images up to the fourth image shown in FIG. In the image after the eye, only the background area on the right side of the foreground area may be used for composition.

図10は、本実施形態における合成において1枚目の画像の前景領域を合成画像に使用する場合について説明するための図である。図9と同様に、図10(a)乃至図10(d)に示す画像は、撮像で得られた4枚の画像を示し、図10(e)乃至図10(h)のそれぞれは、図10(a)乃至図10(d)を順に合成した後の合成画像を示す。ここで、ユーザが1枚目の画像(図10(a)が示す画像)の前景領域を合成画像に使用すると設定したものとする。この場合、図10(e)に示すように図10(a)の画像の全面を合成画像に使用する。次に、図10(b)に対して、システム制御部210がその右側のグレーの背景領域bを合成に使用する。その理由は、背景領域b以外の部分は、図10(a)に示した画像と重なり、システム制御部210が図10(a)に示した画像を優先的に使用するためである。同様に、システム制御部210が図10(c)と図10(d)に対しても同様な処理を行い、最終的に図10(h)が示したような合成画像を作成する。図10(h)は、図10(a)の前景領域とともに、背景の合成画像が映るパノラマ画像を示している。   FIG. 10 is a diagram for describing the case where the foreground area of the first image is used for the composite image in the composition in the present embodiment. Similar to FIG. 9, the images shown in FIGS. 10 (a) to 10 (d) show four images obtained by imaging, and each of FIGS. 10 (e) to 10 (h) is a diagram. The composite image after synthesize | combining 10 (a) thru | or FIG. 10 (d) in order is shown. Here, it is assumed that the user sets the foreground area of the first image (the image shown in FIG. 10A) to be used for the composite image. In this case, as shown in FIG. 10E, the entire surface of the image of FIG. 10A is used as a composite image. Next, with respect to FIG. 10B, the system control unit 210 uses the gray background area b on the right side for synthesis. The reason is that the portions other than the background area b overlap the image shown in FIG. 10A, and the system control unit 210 preferentially uses the image shown in FIG. Similarly, the system control unit 210 performs the same process on FIGS. 10 (c) and 10 (d), and finally creates a composite image as shown in FIG. 10 (h). FIG. 10 (h) shows a panoramic image in which a composite image of the background is shown together with the foreground area of FIG. 10 (a).

図11は、本実施形態における合成において3枚目の画像の前景領域を合成画像に使用する場合の一例について説明するための図である。図11(a)乃至図11(d)は、撮像で得られた4枚の画像を示し、図10と同様である。ただし、図11では、3枚目の画像(図11(c))の前景領域を合成に用いるという点で、図10とは異なる。図11(a)と図11(b)とに対する処理は、図9と同様である。つまり、システム制御部210は、図11(a)と図11(b)が示す画像の背景領域をそれぞれ切り出して合成に用い、図11(f)に示す合成画像を生成する。ここで、図11(c)が示す3枚目の画像の前景領域を合成画像に使用するため、図7が示したフローチャートの通り、図11(c)が示す画像の全面を合成画像に使用する。具体的に図11(g)が示すように、図11(c)が示す画像の全体を合成画像に使用し、すでに合成済みの部分と重なる部分を上書きするように図11(c)が示す画像を優先的に使用する。その結果、3枚目の画像が合成に使われた後、図11(g)が示したような合成画像が生成できる。図11(g)に示す画像は、図11(a)の左側の背景領域と図11(c)の画像の全部とからなる。次に、図11(d)に示す画像が撮像された後、システム制御部210は、図11(d)に示す画像の右側の背景領域bを合成に用い、最終的に図11(h)に示したような合成画像を作成する。   FIG. 11 is a diagram for describing an example of using the foreground area of the third image in the composition in the composition in the present embodiment. FIGS. 11A to 11D show four images obtained by imaging, which are similar to FIGS. However, FIG. 11 differs from FIG. 10 in that the foreground area of the third image (FIG. 11 (c)) is used for combining. The processes for FIGS. 11 (a) and 11 (b) are the same as in FIG. That is, the system control unit 210 cuts out the background areas of the images shown in FIGS. 11A and 11B and uses them in the synthesis to generate a synthesized image shown in FIG. Here, in order to use the foreground area of the third image shown in FIG. 11C for the composite image, the entire surface of the image shown in FIG. 11C is used for the composite image as shown in the flowchart in FIG. Do. Specifically, as shown in FIG. 11 (g), FIG. 11 (c) shows that the entire image shown in FIG. 11 (c) is used for the composite image, and the portion overlapping with the already synthesized portion is overwritten. Use images preferentially. As a result, after the third image is used for combining, a combined image as shown in FIG. 11 (g) can be generated. The image shown in FIG. 11 (g) consists of the background area on the left side of FIG. 11 (a) and the entire image of FIG. 11 (c). Next, after the image illustrated in FIG. 11D is captured, the system control unit 210 uses the background area b on the right side of the image illustrated in FIG. Create a composite image as shown in.

ただし、図7のフローチャートに示したような合成方法は一例にすぎず、様々な変形をして実施することができる。たとえば、次のような合成方法で実施してもよい。   However, the synthesis method as shown in the flowchart of FIG. 7 is merely an example, and various modifications can be made. For example, the following synthesis method may be used.

図12は、本実施形態における合成において3枚目の画像の前景領域を合成画像に使用する別の一例について説明するための図である。図12に示す合成方法は、3枚目の画像の全面よりは狭い範囲を合成画像に用いることが、図11に示す方法との違いである。図12(a)乃至図12(d)のそれぞれは図11(a)乃至図11(d)のそれぞれと同様である。システム制御部210は、図12(a)と図12(b)とが示した画像の背景領域をそれぞれ切り出して合成に用い、図12(f)に示したような合成画像を生成し、図12(f)は図11(f)と同様である。   FIG. 12 is a diagram for describing another example of using the foreground area of the third image in the composition in the composition in the present embodiment. The difference between the combining method shown in FIG. 12 and the method shown in FIG. 11 is that a range narrower than the entire surface of the third image is used for the combining image. Each of FIG. 12 (a) to FIG. 12 (d) is the same as each of FIG. 11 (a) to FIG. 11 (d). The system control unit 210 cuts out the background areas of the images shown in FIG. 12A and FIG. 12B and uses them for combining to generate a combined image as shown in FIG. 12 (f) is similar to FIG. 11 (f).

ここで図11(h)に示す合成画像から、図11(b)に示す画像の左側の背景領域aが合成画像には含まれていないことがわかる。これは、図11(c)に示した画像を合成に用いるとき、上書きされるためである。図12では、前述した背景領域aが上書きされないように、3枚目の画像の合成に使われる領域を減らす。図12(c)では、システム制御部210が合成に用いる領域がグレーになっていて、図11(c)と比べて図12(b)の背景領域aに相当する部分が欠けていることがわかる。図12で示した方法では、図12(b)の背景領域aを図12(h)の合成画像に映りこむようにすることができる。   Here, it can be seen from the composite image shown in FIG. 11 (h) that the background area a on the left side of the image shown in FIG. 11 (b) is not included in the composite image. This is because the image shown in FIG. 11C is overwritten when it is used for composition. In FIG. 12, the area used for combining the third image is reduced so that the background area a described above is not overwritten. In FIG. 12C, the area used for composition by the system control unit 210 is gray, and a portion corresponding to the background area a in FIG. 12B is missing compared to FIG. 11C. Recognize. According to the method shown in FIG. 12, the background area a of FIG. 12B can be reflected in the composite image of FIG.

なお、ステップS701で自撮りパノラマモードでないと判定した場合には、ステップS707では従来通りの方法でパノラマ画像の合成を行えばよい。つまり、連続して撮像された画像のそれぞれから前景領域と背景領域を抽出する必要はなく、図3や図4に示すように画像の中央付近の領域を切り出して、位置合わせをして合成すればよい。   If it is determined in step S701 that the self-portrait panoramic mode is not set, in step S707, panoramic images may be synthesized by a conventional method. That is, it is not necessary to extract the foreground area and the background area from each of the continuously captured images, and as shown in FIG. 3 and FIG. 4, the area near the center of the image is cut out, aligned and synthesized. Just do it.

また、上述した図9乃至図12では、説明を容易にするため、画像全体を前景領域と背景領域に分ける例を上げて説明を行ってきたが、これに限られるものではない。図3や図4に示すように、画像の中央付近の領域を短冊状に切り出し、この領域内で前景領域と背景領域を区別するようにしてもよい。ただし、短冊状に切り出す領域は、撮像者がはみ出ないように十分な幅を設ける必要がある。   Further, in FIG. 9 to FIG. 12 described above, although the example in which the entire image is divided into the foreground area and the background area has been described in order to facilitate the description, the present invention is not limited to this. As shown in FIG. 3 and FIG. 4, an area near the center of the image may be cut out in a strip shape, and the foreground area and the background area may be distinguished within this area. However, it is necessary to provide an area which is cut into a strip shape with a sufficient width so that the photographer does not go out.

また、本発明は、「前景」が撮像者である場合のみに適用できるものでなく、様々な場面に適用できる。例えば、システム制御部210は、前景の抽出手段として、学習済みの畳込みニューラルネットワーク(CNN)を使用し、いわゆる一般物体認識手段を使用し、前景となりうる被写体を抽出する。その場合、システム制御部210は、学習済みの一般物体の中から、ユーザが予め前景として認識してほしい物体を設定できるようにしてもよい。   Further, the present invention can be applied not only to the case where the "foreground" is a photographer but to various scenes. For example, the system control unit 210 uses a trained convolutional neural network (CNN) as a foreground extraction unit, and uses a so-called general object recognition unit to extract a subject that can be the foreground. In that case, the system control unit 210 may set an object which the user wants to be recognized as a foreground in advance from among the learned general objects.

ここまでは、撮像者以外の人物が撮影する画角に入っていないことを前提として、説明をしてきた。撮像者以外の人物像がパノラマ撮像の画角に入ってしまうと、前述のような実施方法では以下のような課題が起きる可能性がある。図13は、本実施形態における撮像者以外の人物像がパノラマ撮像の画角に存在する場合について説明するための図である。   Up to this point, the explanation has been made on the premise that a person other than the photographer has not entered an angle of view for photographing. When an image of a person other than the photographer enters the angle of view of panoramic imaging, the following problems may occur in the above-described implementation method. FIG. 13 is a diagram for describing the case where an image of a person other than the image capturer in the present embodiment exists at an angle of view of panoramic imaging.

図13(a)乃至図13(d)では、パノラマ撮像で撮像部204が連続して撮像した4枚の画像を示している。そのうち、図13(b)乃至図13(d)の画像は、撮像者の人物像以外は、ほかにもう1人の人物像が入っていることがわかる。前述した前景領域の判断方法では、システム制御部210が顔認識で人物像を特定し、その人物像を前景領域と見なす。しかしながら、図13のような場合では、システム制御部210は、撮像者でない人物像を前景領域として認識してしまう可能性がある。もともと背景に存在する人物像は、システム制御部210によって前景にあると誤認識されると、合成に用いられず、その背景領域にあたる画角が欠けてしまう可能性がある。例えば、図13に示したような場合では、システム制御部210は、図13(b)に示した画像の最も右側の領域を前景領域と誤認してしまうとする。図13(b)に示した画像の最も右側の領域が前景領域とされてしまうため、システム制御部210は図13(b)に示した画像の前景領域を合成画像に使用すると選択しない限り、図13(b)に示した画像の最も右側の領域は合成に使われない。システム制御部210は、図13(b)に示した画像の最も右側の領域にあたる画角を有するほかの画像の領域を合成画像に使わないと、その画角が欠けてしまう。たとえば、システム制御部210は、1枚目の画像、つまり図13(a)に示した画像の前景領域を合成に用いると設定すると仮定する。この場合では、図13(b)に示した画像の最も右側の領域が前景領域に該当するため、システム制御部210がこの領域を合成画像に用いない。同様に、図13(c)に示した画像でも、システム制御部210が撮像者でない人物像を前景領域と認識し、合成画像に用いない。図13(d)においても同様である。その結果、図13(b)に示した画像の最も右側の領域にあたる画角をもつ領域は、いずれも合成画像に用いられていなく、合成画像にその画角にあたる部分が欠けてしまう。   13A to 13D show four images continuously captured by the imaging unit 204 in panoramic imaging. Among them, it can be seen that the images of FIG. 13B to FIG. 13D contain one more person image other than the person image of the imaging person. In the foreground area determination method described above, the system control unit 210 identifies a human image by face recognition, and regards the human image as a foreground area. However, in the case as illustrated in FIG. 13, the system control unit 210 may recognize an image of a person who is not the image capturing person as the foreground area. If a human image originally existing in the background is erroneously recognized as being in the foreground by the system control unit 210, it is not used for synthesis, and the angle of view corresponding to the background area may be lost. For example, in the case shown in FIG. 13, it is assumed that the system control unit 210 misidentifies the rightmost area of the image shown in FIG. 13B as the foreground area. Since the rightmost area of the image shown in FIG. 13B is regarded as the foreground area, the system control unit 210 selects the foreground area of the image shown in FIG. The rightmost region of the image shown in FIG. 13 (b) is not used for composition. If the system control unit 210 does not use the area of the other image having the angle of view corresponding to the rightmost area of the image illustrated in FIG. 13B in the composite image, the angle of view is lost. For example, it is assumed that the system control unit 210 sets the first image, that is, the foreground area of the image illustrated in FIG. 13A to be used for composition. In this case, since the rightmost area of the image shown in FIG. 13B corresponds to the foreground area, the system control unit 210 does not use this area for the composite image. Similarly, even in the image shown in FIG. 13C, the system control unit 210 recognizes a person who is not the image pickup person as a foreground area and does not use it for the composite image. The same applies to FIG. As a result, none of the regions having the angle of view corresponding to the rightmost region of the image shown in FIG. 13B is used for the composite image, and a portion corresponding to the field angle is missing in the composite image.

上述のような課題を解決するために、システム制御部210が単純に人物を認識して前景領域と判断するような実施方法を改める必要がある。たとえば、2つ以上の人物像が現れたとき、システム制御部210が人物像の被写体距離を取得し、被写体距離の最も近い方のみを前景領域と判断する。または、システム制御部210が、最も面積の大きい人物像のみを前景領域と判断する。以上の方法で、システム制御部210が撮像者でない人物像を前景領域と誤認してしまうことを防ぐことが期待できる。   In order to solve the problems as described above, it is necessary to revise an implementation method in which the system control unit 210 simply recognizes a person and determines it as a foreground region. For example, when two or more human images appear, the system control unit 210 acquires the subject distance of the human image, and determines only the closest subject distance as the foreground area. Alternatively, the system control unit 210 determines that only the human image with the largest area is the foreground area. It can be expected to prevent the system control unit 210 from misidentifying a person who is not a photographer as a foreground area by the above method.

本実施形態によれば、撮像者が自撮りでパンニングして撮像した画像を用いて、前景の撮像者の人物像を含むパノラマ画像を撮像するとき、前景の画像が多数回出なく、違和感のないパノラマ画像を作成できる。   According to the present embodiment, when capturing a panoramic image including a person's image of the foreground imager using an image captured and photographed by the imager by self-portrait, the image of the foreground does not appear many times, and it is uncomfortable Can create panoramic images.

(その他の実施形態)
なお、上記実施形態においては、個人向けのデジタルカメラをもとに説明を行ったが、パノラマ撮像および合成機能を搭載していれば、携帯機器やスマートフォン、あるいは、サーバーに接続されたネットワークカメラなどに適用することも可能である。
(Other embodiments)
Although the above embodiment has been described based on a digital camera for individuals, if a panoramic imaging and combining function is installed, a portable device, a smartphone, a network camera connected to a server, etc. It is also possible to apply to

なお、本発明は、上述の実施形態の1つ以上の機能を実現するプログラムを、ネットワークまたは記録媒体を介してシステムまたは装置に供給し、そのシステムまたは装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読み出し作動させる処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。   Note that the present invention supplies a program that implements one or more functions of the above-described embodiments to a system or apparatus via a network or a recording medium, and one or more processors in a computer of the system or apparatus Can be realized by processing for reading out and operating. It can also be implemented by a circuit (eg, an ASIC) that implements one or more functions.

100 デジタルカメラ
102 操作部
104 モード切替スイッチ
130 記録媒体
204 撮像部
206 画像処理部
207 メモリ制御部
209 メモリ
210 システム制御部
215 検出部
216 I/F
100 digital camera 102 operation unit 104 mode selector switch 130 recording medium 204 imaging unit 206 image processing unit 207 memory control unit 209 memory 210 system control unit 215 detection unit 216 I / F

Claims (13)

パンニング動作をしながら撮像された複数の画像のそれぞれから前景と背景を認識する認識手段と、
前記複数の画像のいずれか1つの画像において認識された前景に対応する画像である前景画像と、前記複数の画像のそれぞれにおいて認識された背景に対応する複数の背景画像を合成し、パノラマ画像を生成する合成手段と、を有し、
前記合成手段は、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記前景画像を優先して合成することを特徴とする画像処理装置。
Recognition means for recognizing a foreground and a background from each of a plurality of images captured while performing a panning operation;
A foreground image, which is an image corresponding to the foreground recognized in any one of the plurality of images, and a plurality of background images corresponding to the background recognized in each of the plurality of images, are combined to form a panoramic image And generating means for generating
The image processing apparatus according to claim 1, wherein the combining unit combines the foreground image with priority in a region where the angle of view overlaps with the foreground image among the plurality of background images.
前記合成手段は、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記背景画像に対して前記前景画像を上書きするか、前記前景画像のみを用いて合成することを特徴とする請求項1に記載の画像処理装置。   The combining unit may overwrite the background image on the background image or combine only the foreground image in a region where the angle of view overlaps the foreground image among the plurality of background images. The image processing apparatus according to claim 1, characterized in that 前記合成手段は、第1のモードが設定された場合に、前記認識手段の認識の結果を用いて、前記前景画像と前記複数の背景画像を用いて合成し、第2のモードが設定された場合に、前記認識手段の認識の結果を用いずに前記複数の画像を用いて合成することを特徴とする請求項1または2に記載の画像処理装置。   When the first mode is set, the combining means combines the foreground image and the plurality of background images using the recognition result of the recognition means, and the second mode is set. 3. The image processing apparatus according to claim 1, wherein the image is synthesized using the plurality of images without using the recognition result of the recognition unit. 前記第1のモードでは、前記認識手段が、撮像者の人物像を前景として認識することを特徴とする請求項3に記載の画像処理装置。   The image processing apparatus according to claim 3, wherein in the first mode, the recognition unit recognizes a person's image of a photographer as a foreground. 前記第1のモードでは、前記認識手段が、前記撮像者の人物像を含まない領域を背景として認識することを特徴とする請求項4に記載の画像処理装置。   The image processing apparatus according to claim 4, wherein in the first mode, the recognition unit recognizes an area not including the person image of the image pickup person as a background. 前記第1のモードは、撮像者が自分を撮像した画像を用いてパノラマ画像を生成するモードであることを特徴とする請求項3乃至5のいずれか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 3 to 5, wherein the first mode is a mode in which a panoramic image is generated using an image obtained by capturing an image of a photographer. 前記いずれか1つの画像は、前記複数の画像が撮像される前に予め指定されることを特徴とする請求項1乃至6のいずれか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 6, wherein any one image is designated in advance before the plurality of images are captured. 前記合成手段は、前記複数の画像を撮像された順に合成することを特徴とする請求項1乃至7のいずれか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 7, wherein the combining unit combines the plurality of images in the order in which the plurality of images are captured. 前記合成手段は、前記前景画像を含む1つの画像の全体を、合成に用いる他の背景画像より優先して合成することを特徴とする請求項1乃至8のいずれか1項に記載の画像処理装置。   The image processing according to any one of claims 1 to 8, wherein the combining means combines one whole of the image including the foreground image in preference to other background images used for combining. apparatus. 前記合成手段は、前記前景画像を含む1つの画像のうちの、前記前景画像よりも前記パンニング動作の方向の側に存在する領域の画像を、合成に用いる他の背景画像より優先して合成することを特徴とする請求項1乃至8のいずれか1項に記載の画像処理装置。   The combining unit preferentially combines, in one image including the foreground image, an image of a region present in the direction of the panning operation with respect to the foreground image over other background images used for combining. The image processing apparatus according to any one of claims 1 to 8, characterized in that: 撮像手段と、
パンニング動作をしながら前記撮像手段によって撮像された複数の画像のそれぞれから前景と背景を認識する認識手段と、
前記複数の画像のいずれか1つの画像において認識された前景に対応する画像である前景画像と、前記複数の画像のそれぞれにおいて認識された背景に対応する複数の背景画像を合成し、パノラマ画像を生成する合成手段と、を有し、
前記合成手段は、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記前景画像を優先して合成することを特徴とする撮像装置。
Imaging means,
A recognition unit that recognizes a foreground and a background from each of a plurality of images captured by the imaging unit while performing a panning operation;
A foreground image, which is an image corresponding to the foreground recognized in any one of the plurality of images, and a plurality of background images corresponding to the background recognized in each of the plurality of images, are combined to form a panoramic image And generating means for generating
The imaging device is characterized in that the combining means preferentially combines the foreground image in a region where the angle of view overlaps with the foreground image among the plurality of background images.
パンニング動作をしながら撮像された複数の画像のそれぞれから前景と背景を認識する認識ステップと、
前記複数の画像のいずれか1つの画像において認識された前景に対応する画像である前景画像と、前記複数の画像のそれぞれにおいて認識された背景に対応する複数の背景画像を合成し、パノラマ画像を生成する合成ステップと、を有し、
前記合成ステップにおいて、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記前景画像を優先して合成することを特徴とする画像処理方法。
Recognizing a foreground and a background from each of a plurality of images captured while panning;
A foreground image, which is an image corresponding to the foreground recognized in any one of the plurality of images, and a plurality of background images corresponding to the background recognized in each of the plurality of images, are combined to form a panoramic image Generating a synthesis step,
The image processing method according to claim 1, wherein, in the combining step, the foreground image is prioritized and combined in a region where the angle of view overlaps with the foreground image among the plurality of background images.
画像処理装置のコンピュータに動作させるコンピュータのプログラムであって、
パンニング動作をしながら撮像された複数の画像のそれぞれから前景と背景を認識する認識ステップと、
前記複数の画像のいずれか1つの画像において認識された前景に対応する画像である前景画像と、前記複数の画像のそれぞれにおいて認識された背景に対応する複数の背景画像を合成し、パノラマ画像を生成する合成ステップと、を有し、
前記合成ステップにおいて、前記複数の背景画像のうち、前記前景画像と画角が重なる領域においては、前記前景画像を優先して合成することを特徴とするプログラム。
A computer program that causes a computer of an image processing apparatus to operate,
Recognizing a foreground and a background from each of a plurality of images captured while panning;
A foreground image, which is an image corresponding to the foreground recognized in any one of the plurality of images, and a plurality of background images corresponding to the background recognized in each of the plurality of images, are combined to form a panoramic image Generating a synthesis step,
The program is characterized in that, in the combining step, in a region where the angle of view overlaps with the foreground image among the plurality of background images, the foreground image is combined preferentially.
JP2017191747A 2017-09-29 2017-09-29 Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program Pending JP2019068243A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017191747A JP2019068243A (en) 2017-09-29 2017-09-29 Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017191747A JP2019068243A (en) 2017-09-29 2017-09-29 Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program

Publications (1)

Publication Number Publication Date
JP2019068243A true JP2019068243A (en) 2019-04-25

Family

ID=66340053

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017191747A Pending JP2019068243A (en) 2017-09-29 2017-09-29 Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program

Country Status (1)

Country Link
JP (1) JP2019068243A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012182582A (en) * 2011-02-28 2012-09-20 Olympus Imaging Corp Imaging apparatus
JP2013034158A (en) * 2011-08-03 2013-02-14 Nikon Corp Imaging apparatus
JP2014068081A (en) * 2012-09-24 2014-04-17 Canon Inc Imaging apparatus and control method of the same, program and storage medium
US20160110848A1 (en) * 2013-08-30 2016-04-21 A9.Com, Inc. Self-portrait enhancement techniques

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012182582A (en) * 2011-02-28 2012-09-20 Olympus Imaging Corp Imaging apparatus
JP2013034158A (en) * 2011-08-03 2013-02-14 Nikon Corp Imaging apparatus
JP2014068081A (en) * 2012-09-24 2014-04-17 Canon Inc Imaging apparatus and control method of the same, program and storage medium
US20160110848A1 (en) * 2013-08-30 2016-04-21 A9.Com, Inc. Self-portrait enhancement techniques

Similar Documents

Publication Publication Date Title
JP7023662B2 (en) Image processing device, image pickup device, control method and program of image processing device
JP6833746B2 (en) Imaging equipment, imaging methods, programs and recording media
JP6124700B2 (en) IMAGING DEVICE, ITS CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM
JP6604831B2 (en) Image processing apparatus, image processing apparatus control method, and program
JP6516787B2 (en) Image processing apparatus, control method for image processing apparatus, and program
JP2022128489A (en) Image capture device
JP6833801B2 (en) Imaging equipment, imaging methods, programs and recording media
JP7163057B2 (en) IMAGING DEVICE, IMAGING METHOD, PROGRAM AND RECORDING MEDIUM
US10867389B2 (en) Image processing apparatus, image pickup apparatus, method for controlling image processing apparatus and storage medium
JP7158892B2 (en) Image processing device, image processing method, imaging device, program and recording medium
JP7158841B2 (en) Imaging device, imaging method, program, recording medium, and image processing device
JP6590894B2 (en) Image processing apparatus, imaging apparatus, image processing method, and program
JP2019125928A (en) Imaging device, imaging method, and program
US10846822B2 (en) Image processing apparatus, image pickup apparatus, control method of image processing apparatus, and recording apparatus
JP7051586B2 (en) Imaging equipment, imaging methods and programs
JP6869841B2 (en) Image processing device, control method of image processing device, and program
JP2019068243A (en) Image processing apparatus, imaging apparatus, control method of image processing apparatus, and program
JP2019186831A (en) Image processing apparatus, imaging apparatus, image processing method, and program
JP6929133B2 (en) Imaging device, control method and program of imaging device
JP2018207178A (en) Imaging apparatus, control method and program of imaging apparatus
US10116877B2 (en) Image processing apparatus and image processing method
JP2023086270A (en) Image processing device, image processing method, imaging apparatus, program, and recording medium
JP2022010685A (en) Imaging device, imaging method, program, and recording medium
JP2021016128A (en) Imaging apparatus, imaging method, and program
JP2021125735A (en) Imaging control device, control method thereof, program, and storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200716

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210719

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210914

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20220315