JP2019096995A - Image processing system, image processing method, and program - Google Patents

Image processing system, image processing method, and program Download PDF

Info

Publication number
JP2019096995A
JP2019096995A JP2017223680A JP2017223680A JP2019096995A JP 2019096995 A JP2019096995 A JP 2019096995A JP 2017223680 A JP2017223680 A JP 2017223680A JP 2017223680 A JP2017223680 A JP 2017223680A JP 2019096995 A JP2019096995 A JP 2019096995A
Authority
JP
Japan
Prior art keywords
image
light emission
area
images
difference
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
Application number
JP2017223680A
Other languages
Japanese (ja)
Other versions
JP6995582B2 (en
Inventor
宏典 海田
Hironori Kaida
宏典 海田
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 JP2017223680A priority Critical patent/JP6995582B2/en
Publication of JP2019096995A publication Critical patent/JP2019096995A/en
Application granted granted Critical
Publication of JP6995582B2 publication Critical patent/JP6995582B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

To generate an image in which lightness of both main subject region and other region becomes appropriate.SOLUTION: A digital camera 100 calculates a prediction vector 905 for predicting movement of a moving subject, by using the differential regions 901, 902 of non-flash images 320, 330, 340. The digital camera 100 sets the region excepting the differential region 906 corresponding to the prediction vector 905, out of the differential region of a flash image 410 and a non-flash image 320, as a main subject replacement region 908. The digital camera 100 replaces the image of a region corresponding to the main subject replacement region 908, out of the background image 420, by a flash image 310 as the final image.SELECTED DRAWING: Figure 9

Description

本発明は、画像処理装置、画像処理方法、およびプログラムに関し、特に、ストロボ光を発光して撮像された画像を処理するために用いて好適なものである。   The present invention relates to an image processing apparatus, an image processing method, and a program, and is particularly suitable for use in processing a captured image by emitting strobe light.

夜景と人物被写体等の主要被写体とを含むシーンの撮影に際して、夜景と主要被写体との双方が際立った画像を記録できるように様々な技術が提案されている。
特許文献1に開示されている技術では、ストロボ光の発光を伴うフラッシュオン撮影と、ストロボ光の発光を伴わないフラッシュオフ撮影とを連続して行う。フラッシュオフ撮影の時には、夜景が適正に露光されるように、撮影感度を高く設定する。一方、フラッシュオン撮影時の画像(フラッシュ画像)は、主要被写体の明るさが適正な画像となる。従って、これら非フラッシュ画像(フラッシュオフ撮影時に得られる画像)とフラッシュ画像とを合成することにより、夜景と主要被写体との双方の明るさが適正となる画像を記録できる。
In photographing a scene including a night scene and a main subject such as a human subject, various techniques have been proposed so that images in which both the night scene and the main subject stand out can be recorded.
In the technology disclosed in Patent Document 1, flash-on shooting with flash light emission and flash-off shooting without flash light emission are performed in succession. At the time of flash-off shooting, the shooting sensitivity is set high so that the night scene is properly exposed. On the other hand, the image at the time of flash-on shooting (flash image) is an image in which the brightness of the main subject is appropriate. Therefore, by combining the non-flash image (image obtained at flash-off shooting) and the flash image, it is possible to record an image in which the brightness of both the night scene and the main subject is appropriate.

特開2012−44378号公報JP 2012-44378 A 特開2008−118555号公報JP, 2008-118555, A 特開平7−318793号公報Japanese Patent Application Laid-Open No. 7-318793 特開2012−169753号公報JP, 2012-169753, A 特開2004−104425号公報Unexamined-Japanese-Patent No. 2004-104425

しかしながら、前述の技術では、主要被写体の明るさが適正となる領域の判定をフラッシュ画像と非フラッシュ画像との差分値を比較することで行う。そのため、ストロボ光の当たらない主要被写体以外の領域に移動する被写体がある場合、当該移動する被写体の領域を主要被写体の領域と誤って判定する虞がある。このため、主要被写体の領域とその他の領域とを適切に合成することができない。その結果、主要被写体の領域とその他の領域との双方の明るさを適正にすることができなくなる虞がある。
本発明は、このような問題点に鑑みてなされたものであり、主要被写体の領域とその他の領域との双方の明るさが適正となる画像を生成することを目的とする。
However, in the above-described technology, the determination of the area in which the brightness of the main subject is appropriate is performed by comparing the difference value between the flash image and the non-flash image. Therefore, when there is a subject moving to an area other than the main subject not exposed to the strobe light, the area of the moving subject may be erroneously determined as the area of the main subject. Therefore, the area of the main subject and the other areas can not be properly synthesized. As a result, there is a possibility that the brightness of both the area of the main subject and the other areas can not be made appropriate.
The present invention has been made in view of such problems, and it is an object of the present invention to generate an image in which the brightness of both the area of the main subject and the other areas is appropriate.

本発明の画像処理装置は、ストロボ光が発光された状態で撮像された発光画像と、ストロボ光が発光されていない状態で撮像された非発光画像とを取得する取得手段と、複数の前記非発光画像の画素情報の変化に基づいて、前記発光画像において動きのある被写体の領域を検出する検出手段と、を有することを特徴とする。   An image processing apparatus according to the present invention includes an acquisition unit that acquires a light emission image captured in a state in which flash light is emitted and a non-emission image captured in a state in which flash light is not emitted; And detecting means for detecting an area of a subject having a motion in the luminescent image based on a change in pixel information of the luminescent image.

本発明によれば、主要被写体の領域とその他の領域との双方の明るさが適正となる画像を生成することができる。   According to the present invention, it is possible to generate an image in which the brightness of both the area of the main subject and the other areas is appropriate.

デジタルカメラの構成を示す図である。It is a figure showing composition of a digital camera. デジタルカメラの全体処理の第1の例を示すフローチャートである。It is a flowchart which shows the 1st example of the whole process of a digital camera. デジタルカメラで撮像される画像を説明する図である。It is a figure explaining the picture picturized with a digital camera. 画像処理された撮像画像を説明する図である。It is a figure explaining the captured image by which image processing was carried out. フラッシュ画像と背景画像とを合成する方法を説明する図である。It is a figure explaining the method to synthesize | combine a flash image and a background image. 背景画像生成処理を説明するフローチャートである。It is a flowchart explaining background image generation processing. 差分情報を算出する処理を説明するフローチャートである。It is a flowchart explaining the process which calculates difference information. 主要被写体置き換え領域検出処理を説明するフローチャートである。It is a flow chart explaining main subject substitution field detection processing. 主要被写体置き換え領域を検出する方法の第1の例を説明する図である。It is a figure explaining the 1st example of the method of detecting the main subject substitution field. 動き領域を予測する方法を説明する図である。It is a figure explaining the method to predict a motion area. 動き領域の予測を行う方法の変形例を説明する図である。It is a figure explaining the modification of the method of performing prediction of a motion area. デジタルカメラの全体処理の第2の例を示すフローチャートである。It is a flowchart which shows the 2nd example of the whole process of a digital camera. 画面表示用画像と本撮影画像を説明する図である。FIG. 6 is a diagram for explaining an image for screen display and an actual photographed image. 主要被写体置き換え領域を検出する方法の第2の例を説明する図である。It is a figure explaining the 2nd example of the method of detecting the main subject substitution field. デジタルカメラの全体処理の第3の例を示すフローチャートである。It is a flowchart which shows the 3rd example of the whole process of a digital camera. 主要被写体置き換え領域を検出する方法の第3の例を説明する図である。It is a figure explaining the 3rd example of the method of detecting a main subject substitution field.

以下、図面を参照しながら、実施形態を説明する。以下の各実施形態では、被写体を撮影して、動画像や静止画像のデータを、各種の記録メディアに記録する撮像装置がデジタルカメラである場合を例に挙げて説明する。しかしながら、撮像装置は、デジタルカメラに限定されず、ビデオカメラであっても、スマートフォンやタブレット等の各種の携帯機器に含まれるものであっても良い。また、撮像装置は、工業用カメラ、車載用カメラ、または医療用カメラに適用されるものであっても良い。尚、記録メディアとしては、例えば、テープ、固体メモリ、光ディスク、および磁気ディスク等が挙げられる。また、以下の各実施形態では、画像処理装置が撮像装置に含まれる場合を例に挙げて説明する。しかしながら、画像処理装置は、撮像手段を備える装置とは別の装置であっても良い。   Hereinafter, embodiments will be described with reference to the drawings. In each of the following embodiments, an example will be described in which the imaging device that captures an object and records moving image and still image data on various recording media is a digital camera. However, the imaging device is not limited to a digital camera, and may be a video camera or may be included in various portable devices such as a smartphone and a tablet. Also, the imaging device may be applied to an industrial camera, an on-vehicle camera, or a medical camera. As the recording medium, for example, a tape, a solid memory, an optical disc, a magnetic disc and the like can be mentioned. In each of the following embodiments, the case where the image processing apparatus is included in the imaging apparatus will be described as an example. However, the image processing apparatus may be an apparatus different from the apparatus provided with the imaging means.

(第1の実施形態)
まず、第1の実施形態を説明する。
図1は、デジタルカメラ100の機能構成の一例を示すブロック図である。
システム制御部101は、例えばCPUである。システム制御部101は、デジタルカメラ100が備える各ブロックの動作を制御する。具体的にシステム制御部101は、デジタルカメラ100が備える各ブロックの動作プログラムを読み出し、システムメモリ103に展開して実行することにより、各ブロックの動作を制御する。デジタルカメラ100が備える各ブロックの動作プログラムは、例えば、不揮発性メモリ102に記憶されている。
First Embodiment
First, the first embodiment will be described.
FIG. 1 is a block diagram showing an example of a functional configuration of the digital camera 100. As shown in FIG.
The system control unit 101 is, for example, a CPU. The system control unit 101 controls the operation of each block included in the digital camera 100. Specifically, the system control unit 101 reads an operation program of each block included in the digital camera 100, and develops and executes the program in the system memory 103 to control the operation of each block. The operation program of each block provided in the digital camera 100 is stored, for example, in the non-volatile memory 102.

不揮発性メモリ102は、例えばEEPROM等の電気的に消去・記録可能なメモリである。不揮発性メモリ102は、デジタルカメラ100が備える各ブロックの動作プログラムに加え、各ブロックの動作において必要なパラメータ等を記憶する。システムメモリ103は、例えばRAMのような揮発性メモリである。また、本実施形態では不揮発性メモリ102には、好適な画像を得るために必要な処理情報が記憶されている。システムメモリ103は、各ブロックの動作プログラムの展開領域としてだけではなく、各ブロックの動作において出力された中間データ等が一時的に記憶される格納領域としても用いられる。   The nonvolatile memory 102 is, for example, an electrically erasable / recordable memory such as an EEPROM. The non-volatile memory 102 stores, in addition to the operation program of each block included in the digital camera 100, parameters and the like necessary for the operation of each block. The system memory 103 is a volatile memory such as, for example, a RAM. Further, in the present embodiment, the non-volatile memory 102 stores processing information necessary to obtain a suitable image. The system memory 103 is used not only as a development area for the operation program of each block but also as a storage area for temporarily storing intermediate data and the like output in the operation of each block.

システムタイマ105は、デジタルカメラ100に内蔵されるタイマである。システムタイマ105は、システム制御部101により実行される各プログラムや処理における経過時間の計測やタイムスタンプ等に用いられる。
撮像ユニット120は、被写体を撮像し、画像データを出力するユニットである。撮像ユニット120は、撮影レンズ121、シャッタ122、撮像素子123、およびA/D変換部124を有する。撮影レンズ121は、フォーカスレンズやズームレンズ、カラーフィルタ等を含む撮影レンズ郡である。撮影レンズ121は、絞りおよびNDフィルタ機能を備えるシャッタ122を介して光学像を撮像素子123に結像する。撮像素子123は、例えばCCDやCMOSセンサ等の撮像素子であり、撮影レンズ121を介して結像された光学像をアナログ画像信号に変換してA/D変換部124に出力する。A/D変換部124は、撮像素子123から入力されたアナログ画像信号に対してA/D変換処理を適用することにより、アナログ画像信号をデジタル画像信号(画像データ/フレーム)に変換する。
The system timer 105 is a timer built in the digital camera 100. The system timer 105 is used for measuring an elapsed time in each program or process executed by the system control unit 101 and for time stamp.
The imaging unit 120 is a unit that images a subject and outputs image data. The imaging unit 120 includes a photographing lens 121, a shutter 122, an imaging element 123, and an A / D converter 124. The imaging lens 121 is an imaging lens group including a focus lens, a zoom lens, a color filter, and the like. The photographing lens 121 forms an optical image on the image pickup element 123 through a shutter 122 having an iris and an ND filter function. The imaging device 123 is an imaging device such as a CCD or a CMOS sensor, converts an optical image formed through the imaging lens 121 into an analog image signal, and outputs the analog image signal to the A / D conversion unit 124. The A / D conversion unit 124 converts the analog image signal into a digital image signal (image data / frame) by applying an A / D conversion process to the analog image signal input from the imaging element 123.

画像処理部104は、撮像ユニット120から出力された画像データ、または後述するメモリ制御部106によりメモリ107から読み出された画像データに対し、種々の画像変換処理を適用する。種々の画像変換処理には、所定の画素補間処理や、縮小処理等のリサイズ処理や、色変換処理等が含まれる。また、画像処理部104は、A/D変換部124より入力されたデジタル画像信号を用いて露出制御や測距制御に係る演算処理を実行し、当該演算処理の結果をシステム制御部101に出力する。システム制御部101は、当該演算処理の結果に基づき、不図示の駆動系により撮影レンズ121およびシャッタ122を動作させて露出制御、測距制御、およびEF(フラッシュプリ発光)処理等の動作を開始させる。   The image processing unit 104 applies various image conversion processing to the image data output from the imaging unit 120 or the image data read from the memory 107 by the memory control unit 106 described later. Various image conversion processing includes predetermined pixel interpolation processing, resizing processing such as reduction processing, color conversion processing, and the like. Further, the image processing unit 104 executes arithmetic processing related to exposure control and distance control using the digital image signal input from the A / D converter 124, and outputs the result of the arithmetic processing to the system control unit 101. Do. The system control unit 101 operates the photographing lens 121 and the shutter 122 by a drive system (not shown) based on the result of the arithmetic processing to start operations such as exposure control, distance measurement control, and EF (flash pre-emission) processing. Let

メモリ制御部106は、メモリ107からの情報の読み出しと、メモリ107への情報の書き込みとを制御するブロックである。メモリ制御部106は、A/D変換部124より入力されたデジタル画像信号、または画像処理部104により各種処理が適用されて出力された画像信号を、メモリ107に書き込む。メモリ107には、撮影中の画像のフレームに係る画像群に加え、撮影中の音声の情報も書き込まれる。このため、メモリ107は、当該情報を格納するために十分な記憶容量を有するように設計されているものとする。   The memory control unit 106 is a block that controls reading of information from the memory 107 and writing of information to the memory 107. The memory control unit 106 writes, in the memory 107, the digital image signal input from the A / D conversion unit 124 or an image signal to which various processes are applied by the image processing unit 104 and output. In the memory 107, in addition to the image group relating to the frame of the image being photographed, information of the sound being photographed is also written. For this reason, the memory 107 is designed to have a sufficient storage capacity to store the information.

ストロボ113は、撮影時にストロボ光の発光動作を行う。ストロボ制御部114は、ストロボ113の発光動作を制御する。入力操作部115は、デジタルカメラ100が備える操作部材(電源ボタン、モード切り替えSW、および撮影ボタン等)を有するユーザインタフェースである。入力操作部115は、ユーザによる各操作部材の操作がなされたことを検出すると、当該操作に対応する制御信号をシステム制御部101に伝送する。I/F111は、記録媒体112とデジタルカメラ100とを相互に接続するためのインタフェースである。記録媒体112には、例えば記録媒体I/F111を介して、MPEG等の所定の符号化形式に従って符号化部110により符号化された画像データおよび音声データが記録される。記録媒体112は、例えばメモリカードやHDD等の、デジタルカメラ100に着脱可能に接続される記録装置である。   The flash 113 performs flash light emission operation at the time of shooting. The flash control unit 114 controls the light emission operation of the flash 113. The input operation unit 115 is a user interface having operation members (a power button, a mode switching SW, an imaging button, and the like) included in the digital camera 100. When the input operation unit 115 detects that the user operates each operation member, the input operation unit 115 transmits a control signal corresponding to the operation to the system control unit 101. The I / F 111 is an interface for connecting the recording medium 112 and the digital camera 100 to each other. Image data and audio data encoded by the encoding unit 110 according to a predetermined encoding format such as MPEG are recorded on the recording medium 112 via, for example, the recording medium I / F 111. The recording medium 112 is, for example, a recording device detachably connected to the digital camera 100, such as a memory card or an HDD.

このような構成をもつ本実施形態のデジタルカメラ100の処理の一例を、図2のフローチャートを用いて説明する。尚、図2のフローチャート(全体処理)は、例えば、デジタルカメラ100において撮影の指示がなされた際に開始されるものとする。
S200において、システム制御部101は、撮像処理を行う。具体的にシステム制御部101は、画像処理部104による演算処理の結果を取得し、露出値を決定する。露出値は、シャッタスピード、絞りの開口量、およびISO感度の設定を含む、撮像ユニット120に係る制御量である。システム制御部101は、決定した露出値を撮像ユニット120に設定する。システム制御部101は、撮像ユニット120により時系列的に連続して撮像されたフラッシュ画像と複数の非フラッシュ画像とを取得する。このように本実施形態では、例えば、S200において、ストロボ光が発光された状態で撮像された発光画像と、ストロボ光が発光されていない状態で撮像された非発光画像とを取得することの一例が実現される。
An example of processing of the digital camera 100 according to the present embodiment having such a configuration will be described using the flowchart of FIG. Note that the flowchart (whole process) in FIG. 2 is started, for example, when an instruction for photographing is given in the digital camera 100.
In S200, the system control unit 101 performs an imaging process. Specifically, the system control unit 101 acquires the result of the arithmetic processing by the image processing unit 104, and determines the exposure value. The exposure value is a control amount related to the imaging unit 120 including the setting of the shutter speed, the aperture amount of the aperture, and the ISO sensitivity. The system control unit 101 sets the determined exposure value in the imaging unit 120. The system control unit 101 acquires a flash image and a plurality of non-flash images continuously captured by the imaging unit 120 in time series. As described above, in this embodiment, for example, in S200, an example of obtaining a light emission image captured in a state in which flash light is emitted and a non-emission image captured in a state in which flash light is not emitted Is realized.

ここで、図3を参照しながら、本実施形態のデジタルカメラ100で撮像される画像の一例を説明する。図3(a)は、フラッシュ画像310の一例を示す。図3(b)、図3(c)、図3(d)は、それぞれ1枚目の非フラッシュ画像320、2枚目の非フラッシュ画像330、3枚目の非フラッシュ画像340を示す。フラッシュ画像310は、ストロボ光を発光して撮像された画像であり、非フラッシュ画像320、330、340は、ストロボ光を発光せずに撮像された画像である。図3(a)〜図3(d)は、フラッシュ画像310、1枚目の非フラッシュ画像320、2枚目の非フラッシュ画像330、3枚目の非フラッシュ画像340の順に連続して撮像される画像である。尚、1枚目〜3枚目の非フラッシュ画像320、330、340の後にフラッシュ画像310を連続して撮像してもよい。   Here, an example of an image captured by the digital camera 100 of the present embodiment will be described with reference to FIG. FIG. 3A shows an example of the flash image 310. FIGS. 3B, 3C, and 3D show the first non-flash image 320, the second non-flash image 330, and the third non-flash image 340, respectively. The flash image 310 is an image captured by emitting a strobe light, and the non-flash images 320, 330, and 340 are images captured without emitting a strobe light. 3A to 3D, the flash image 310, the first non-flash image 320, the second non-flash image 330, and the third non-flash image 340 are sequentially captured in this order. Image. The flash image 310 may be continuously captured after the first to third non-flash images 320, 330, and 340.

フラッシュ画像310は、非フラッシュ画像320、330、340に比べ、背景が暗い。これは、フラッシュ画像310を撮像する際には、非フラッシュ画像320、330、340に比べ、ストロボ光を発光する分、露出を下げるためである。システム制御部101は、主要被写体302が適正の明るさになるように例えば露出を1段下げる。そして、システム制御部101は、非フラッシュ画像の適正な露出の明るさに合うようにストロボ113からストロボ光が発光されるようにストロボ制御部114を制御し、ストロボ光が発光された状態で撮像ユニット120により撮像を実行させる。   The flash image 310 has a darker background than the non-flash images 320, 330, 340. This is because when the flash image 310 is captured, the exposure is lowered by the amount of flash light emission compared to the non-flash images 320, 330, and 340. The system control unit 101 lowers the exposure, for example, by one stage so that the main subject 302 has appropriate brightness. Then, the system control unit 101 controls the flash control unit 114 so that the flash light is emitted from the flash 113 so as to match the appropriate exposure brightness of the non-flash image, and imaging is performed in the state where the flash light is emitted. The unit 120 performs imaging.

従って、非フラッシュ画像320、330、340は、フラッシュ画像310に比べ、ストロボ光が届かない領域303(フラッシュ画像310の領域301に対応する領域)で明るさが1段高くなっている。また、非フラッシュ画像320、330、340を撮像する際にはストロボ光が発光されないため、光量が低い。よって、非フラッシュ画像320、330、340は、画像全体にノイズが多く含まれた画像となる。更に、フラッシュ画像310の、ストロボ光が当たっていない領域301に関しては、非フラッシュ画像320、330、340よりもノイズが1段悪化した画像となる。フラッシュ画像310および非フラッシュ画像320、330、340は、撮影指示に基づいて本撮影された画像である。   Therefore, the brightness of the non-flash images 320, 330, and 340 is one step higher than that of the flash image 310 in the area 303 (area corresponding to the area 301 of the flash image 310) to which the strobe light does not reach. In addition, when the non-flash images 320, 330, and 340 are captured, the light amount is low because the strobe light is not emitted. Therefore, the non-flash images 320, 330, and 340 become images in which a large amount of noise is included in the entire image. Further, the area 301 of the flash image 310 not exposed to strobe light is an image that is one step worse than the non-flash images 320, 330, and 340. The flash image 310 and the non-flash images 320, 330, and 340 are images that have been captured on the basis of a capture instruction.

続いて図4を参照しながら、本実施形態のデジタルカメラ100で撮像された画像に対し画像処理を行うことで生成される画像の一例について説明する。図4(a)は、ゲイン調整後のフラッシュ画像410の一例を示す。フラッシュ画像410は、図3(a)に示すフラッシュ画像310に対し明るさが1段分明るくなるようにデジタルゲインを掛けた画像である。フラッシュ画像410の背景領域401の明るさは、図3(b)〜図3(d)に示す非フラッシュ画像320、330、340の明るさと合っている。また、図4(b)は、背景画像420の一例を示す。背景画像420は、後述する図2に示すフローチャートのS202の処理によって、非フラッシュ画像320、330、340と、フラッシュ画像410とを合成した画像である。このように本実施形態では、例えば、ゲイン調整後のフラッシュ画像410を生成することにより、前記発光画像の背景の領域の明るさが前記非発光画像の明るさに近づくように前記発光画像の明るさを調整することの一例が実現される。また、明るさが調整された前記発光画像は、例えば、ゲイン調整後のフラッシュ画像410により実現される。   Subsequently, an example of an image generated by performing image processing on an image captured by the digital camera 100 according to the present embodiment will be described with reference to FIG. 4. FIG. 4A shows an example of the flash image 410 after gain adjustment. The flash image 410 is an image obtained by multiplying the flash image 310 shown in FIG. 3A by a digital gain so that the brightness is brightened by one step. The brightness of the background area 401 of the flash image 410 matches the brightness of the non-flash images 320, 330, and 340 shown in FIGS. 3 (b) to 3 (d). Further, FIG. 4B shows an example of the background image 420. The background image 420 is an image obtained by combining the non-flash images 320, 330, and 340 and the flash image 410 by the process of S202 of the flowchart shown in FIG. 2 described later. As described above, in the present embodiment, for example, by generating the flash image 410 after gain adjustment, the brightness of the light emission image is made so that the brightness of the background area of the light emission image approaches the brightness of the non-light emission image. An example of adjusting the height is realized. Further, the light emission image whose brightness has been adjusted is realized, for example, by the flash image 410 after gain adjustment.

図2の説明に戻り、S201において、システム制御部101は、位置合わせ処理を行う。具体的にシステム制御部101は、図4(a)に示すフラッシュ画像410と図3(b)〜図3(d)に示す非フラッシュ画像320、330、340とを合成するためにこれらの画像のうちの所定の1枚の画像を基準に各画像の位置合わせを行う。この処理を行うことで、フラッシュ画像410と複数の非フラッシュ画像320、330、340とにおける手ブレ等の影響を改善することができる。このように本実施形態では、例えば、S201により、複数の非発光画像の位置を合わせることの一例が実現される。尚、本実施形態では、フラッシュ画像310、複数の非フラッシュ画像320、330、340の順に撮像を行う場合を例に挙げて説明する。   Returning to the explanation of FIG. 2, in step S201, the system control unit 101 performs alignment processing. Specifically, the system control unit 101 uses these images to combine the flash image 410 shown in FIG. 4A and the non-flash images 320, 330, and 340 shown in FIGS. 3B to 3D. Each image is aligned based on a predetermined one of the images. By performing this process, the influence of camera shake or the like on the flash image 410 and the plurality of non-flash images 320, 330, and 340 can be improved. As described above, in the present embodiment, for example, an example of aligning the positions of a plurality of non-light emitting images is realized by S201. In the present embodiment, an example in which the flash image 310 and the plurality of non-flash images 320, 330, and 340 are imaged in order will be described.

画像の位置合わせ方法の一例としては、動きベクトルを求めて、動きベクトルの向きおよび大きさを基にした変換係数を算出し、変換係数に基づいて画像を変形させる方法がある。例えば、基準画像から所定サイズのテンプレート画像を作成し、位置合わせ対象画像とテンプレート画像とのマッチング処理(テンプレートマッチング処理)を行うことで、動きベクトルを算出する。尚、このような動きベクトルを用いた位置合わせについては、特許文献2に記載されているので、ここでは、その詳細な説明を省略する。また、位置合わせの方法は、前述したものに限定されず、様々な手法があるため、それらの手法を使用して位置合わせ処理を行っても良い。   As an example of the image alignment method, there is a method of obtaining a motion vector, calculating a transform coefficient based on the direction and magnitude of the motion vector, and deforming the image based on the transform coefficient. For example, a template image of a predetermined size is created from the reference image, and a motion vector is calculated by performing matching processing (template matching processing) between the alignment target image and the template image. In addition, about the position alignment which used such a motion vector, since it describes in patent document 2, the detailed description is abbreviate | omitted here. Further, the method of alignment is not limited to the one described above, and there are various methods, and therefore the alignment process may be performed using these methods.

次に、S202において、システム制御部101は、背景画像生成処理を行う。図4(b)に示す背景画像420は、図3(b)〜図3(d)に示す非フラッシュ画像320、330、340と、図4(a)に示すフラッシュ画像410とを合成することで作成される。背景画像生成処理については後で詳しく述べる。本実施形態では、例えば、S202により、前記発光画像と前記複数の非発光画像とを合成した画像を、前記非発光画像に基づく画像として生成することの一例が実現される。また、前記非発光画像に基づく画像は、例えば、背景画像420により実現される。   Next, in step S202, the system control unit 101 performs background image generation processing. The background image 420 shown in FIG. 4B is to combine the non-flash images 320, 330 and 340 shown in FIG. 3B to FIG. 3D with the flash image 410 shown in FIG. Created by The background image generation process will be described in detail later. In the present embodiment, for example, an example of generating an image obtained by combining the light emitting image and the plurality of non-light emitting images as an image based on the non-light emitting image is realized by S202. Also, an image based on the non-emission image is realized by, for example, a background image 420.

次に、S203において、システム制御部101は、主要被写体置き換え領域検出処理を行う。具体的にシステム制御部101は、図3(a)に示すフラッシュ画像310と、図4(b)に示す背景画像420とを合成するための主要被写体置き換え領域を検出する。主要被写体置き換え領域は、フラッシュ画像310の領域であって、背景画像420に対して置き換える主要被写体の領域である。S203では、図4(a)に示すフラッシュ画像410と図3(b)〜図3(d)に示す非フラッシュ画像320、330、340とを用いて、動く被写体の領域を除去し、ストロボ光が当たっている領域を検出する。主要被写体置き換え領域検出処理については後で詳しく述べる。本実施形態では、例えば、S203により、複数の前記非発光画像の画素情報の変化に基づいて、前記発光画像において動きのある被写体の領域を検出することの一例が実現される。また、動きのない被写体の領域は、例えば、主要被写体の領域により実現される。   Next, in step S203, the system control unit 101 performs main subject replacement area detection processing. Specifically, the system control unit 101 detects a main subject replacement area for combining the flash image 310 shown in FIG. 3A and the background image 420 shown in FIG. 4B. The main subject replacement area is an area of the flash image 310 and an area of the main subject to be substituted for the background image 420. In S203, the area of the moving object is removed using the flash image 410 shown in FIG. 4A and the non-flash images 320, 330, and 340 shown in FIGS. Detect the area that is hit. The main subject replacement area detection process will be described in detail later. In the present embodiment, an example of detecting an area of a subject having a motion in the light emission image is realized based on changes in pixel information of the plurality of non-light emission images, for example, in S203. Also, the area of the subject without motion is realized by, for example, the area of the main subject.

次に、S204において、図1のシステム制御部101は、S203の処理で求めた主被写体置き換え領域の検出結果に基づいて、フラッシュ画像310と背景画像420とを合成する。本実施形態では、例えば、S204により、前記発光画像と、前記非発光画像に基づく画像とを合成することの一例が実現される。図5を参照しながら、フラッシュ画像310と背景画像420とを合成する方法の一例を説明する。   Next, in step S204, the system control unit 101 in FIG. 1 combines the flash image 310 and the background image 420 based on the detection result of the main subject replacement area obtained in the process of step S203. In the present embodiment, for example, one example of combining the light emission image and the image based on the non-light emission image is realized by S204. An example of a method of combining the flash image 310 and the background image 420 will be described with reference to FIG.

図5(a)は、フラッシュ画像310の一例を示し、図5(b)は、背景画像420の一例を示す。図5(c)は、S203の処理で求めた主要被写体置き換え領域の検出結果530の一例を示す。図5(d)は、本実施形態の最終画像540である。図5(c)において、領域501は、図5(a)に示すフラッシュ画像310のうち、背景画像420に合成する領域(すなわち、主要被写体置き換え領域)を示す。また、領域502は、図5(b)に示す背景画像420を合成する領域を示す。従って、システム制御部101は、図5(c)に示す主要被写体置き換え領域の検出結果530に応じて、フラッシュ画像310と背景画像420とを合成し、最終画像540を生成する。
以上、図2のフローチャートを用いて、フラッシュ画像と非フラッシュ画像とを合成する全体の処理の一例を説明した。
5A shows an example of the flash image 310, and FIG. 5B shows an example of the background image 420. FIG. 5C shows an example of the detection result 530 of the main subject replacement area obtained in the process of S203. FIG. 5D is the final image 540 of this embodiment. In FIG. 5C, an area 501 indicates an area (that is, a main subject replacement area) to be combined with the background image 420 in the flash image 310 shown in FIG. 5A. An area 502 indicates an area where the background image 420 shown in FIG. 5B is to be synthesized. Therefore, the system control unit 101 combines the flash image 310 and the background image 420 according to the detection result 530 of the main subject replacement area shown in FIG. 5C, and generates the final image 540.
In the above, an example of the entire process of combining a flash image and a non-flash image has been described with reference to the flowchart of FIG.

続いて、図6のフローチャートを参照しながら、図2のS202の背景画像生成処理の一例を詳しく説明する。ここでは一例として、1枚の(ゲイン調整後の)フラッシュ画像410と、3枚の非フラッシュ画像320、330、340とを合成して背景画像420を生成する処理を説明する。   Subsequently, an example of the background image generation process of S202 of FIG. 2 will be described in detail with reference to the flowchart of FIG. Here, as an example, a process of combining the single flash image 410 (after gain adjustment) and the three non-flash images 320, 330, and 340 to generate the background image 420 will be described.

S600において、システム制御部101は、合成処理を行った回数を記録するレジスタの値iを初期化(レジスタの値iに「1」を設定)する。
次に、S601において、システム制御部101は、レジスタの値iが、合成する回数N(ここではN=3)を超えていないかを判定する。この判定の結果、真の場合(レジスタの値iが、合成する回数Nを超えていない場合)、処理はS602のステップに移る。一方、偽の場合(レジスタの値iが、合成する回数Nを超えている場合)、システム制御部101は、背景画像生成処理を終了し、この時点で得られている画像を背景画像420とする(図4(b)を参照)。
In step S600, the system control unit 101 initializes a value i of a register that records the number of times of synthesis processing (sets “1” to the value i of the register).
Next, in step S601, the system control unit 101 determines whether the value i of the register exceeds the number N of times of synthesis (here, N = 3). As a result of this determination, if the result is true (if the register value i does not exceed the number N of times of combining), the process proceeds to the step S602. On the other hand, in the case of false (when the register value i exceeds the number N of times of composition), the system control unit 101 ends the background image generation processing, and uses the image obtained at this time as the background image 420. (See FIG. 4 (b)).

次に、S602において、システム制御部101は、差分情報を算出する。図3、図4、および図7を参照しながら、差分情報を算出する処理の一例を説明する。
まず、システム制御部101は、合成基準画像と、合成対象の画像とのフレーム間の差分情報を算出する。システム制御部101は、例えば、図3(b)に示す1枚目の非フラッシュ画像320を合成基準画像に設定する。1枚目の非フラッシュ画像320と2枚目の非フラッシュ画像330とのフレーム間の差分情報は、図7(a)に示す差分情報710となる。差分情報は、例えば、各画像の明るさまたは色差のフレーム間の画素ごとの差分値で表わされる。図7に示す例では、差分値の絶対値が閾値を上回る領域を、領域701のように白い領域で表す。システム制御部101は、この白い領域701で示されている領域を被写体が動いている領域と判断する。システム制御部101は、黒い領域702を被写体が動いていない領域と判断する。以上の処理と同様の処理を行うことで、図7(b)に示すように、1枚目の非フラッシュ画像320と3枚目の非フラッシュ画像340とのフレーム間の差分情報720が得られる。
Next, in step S602, the system control unit 101 calculates difference information. An example of the process of calculating the difference information will be described with reference to FIGS. 3, 4 and 7.
First, the system control unit 101 calculates inter-frame difference information between the combined reference image and the image to be combined. The system control unit 101 sets, for example, the first non-flash image 320 shown in FIG. 3B as a composite reference image. The difference information between the frames of the first non-flash image 320 and the second non-flash image 330 is the difference information 710 shown in FIG. 7A. The difference information is represented, for example, by a pixel-by-pixel difference value between lightness or color difference frames of each image. In the example illustrated in FIG. 7, a region where the absolute value of the difference value exceeds the threshold is represented by a white region such as a region 701. The system control unit 101 determines that the area indicated by the white area 701 is an area in which the subject is moving. The system control unit 101 determines that the black area 702 is an area in which the subject is not moving. By performing the same process as the above process, as shown in FIG. 7B, difference information 720 between the frames of the first non-flash image 320 and the third non-flash image 340 can be obtained. .

合成基準画像とフラッシュ画像とのフレーム間の差分情報を算出する場合には、図3(a)に示すフラッシュ画像310を用いず、図4(a)に示すゲインが調整されたフラッシュ画像410を用いる。主要被写体以外の領域の明るさをフラッシュ画像と非フラッシュ画像に合わせることで、被写体が動いている領域(差分)を抽出できるようにするためである。図7(c)は、1枚目の非フラッシュ画像320とフラッシュ画像410とのフレーム間の差分情報730を示す。
尚、合成基準画像としてフラッシュ画像を用いてもよい。この場合には、図3(a)に示すフラッシュ画像310を用いず、図4(a)に示すゲインが調整されたフラッシュ画像410を合成基準画像として用いる。
When calculating difference information between frames of the combined reference image and the flash image, the flash image 410 shown in FIG. 4A is adjusted without using the flash image 310 shown in FIG. Use. By matching the brightness of the area other than the main subject with the flash image and the non-flash image, it is possible to extract the area (difference) in which the subject is moving. FIG. 7C illustrates the difference information 730 between the first non-flash image 320 and the flash image 410.
Note that a flash image may be used as a composite reference image. In this case, instead of using the flash image 310 shown in FIG. 3A, the flash image 410 whose gain is adjusted as shown in FIG. 4A is used as a composite reference image.

図6の説明に戻り、S603において、システム制御部101は、S602で算出したフレーム間の差分情報を基に、以下の処理を行う。即ち、システム制御部101は、i−1回の処理までに合成された画像と、i回目の処理(S602)において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像と、の合成を行う。尚、1回目の処理においては、i−1回の処理までに合成された画像は、初期の合成基準画像(ここでは、1枚目の非フラッシュ画像320)である。また、合成基準画像と最初に合成する画像が、例えば、2枚目の非フラッシュ画像330である場合、1回目の処理(S602)において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像は、2枚目の非フラッシュ画像330である。このように本実施形態では、例えば、S603により、前記発光画像および前記複数の発光画像のうち基準となる画像と、前記発光画像および前記複数の発光画像のうち前記基準となる画像と異なる画像とを合成することの一例が実現される。   Referring back to FIG. 6, in step S603, the system control unit 101 performs the following processing based on the difference information between the frames calculated in step S602. That is, the system control unit 101 calculates an image that has been synthesized up to i-1 times of processing, and an image obtained by calculating a difference value (difference information) between frames with respect to the synthesized reference image in the i-th process (S602). Do the synthesis of In the first process, the image synthesized by i-1 times is the initial synthesized reference image (here, the first non-flash image 320). Also, if the composite reference image and the image to be combined first are the second non-flash image 330, for example, the difference value (difference information) between the frames with respect to the composite reference image in the first process (S602) The calculated image is the second non-flash image 330. Thus, in the present embodiment, for example, in S603, an image serving as a reference among the light emission image and the plurality of light emission images, and an image different from the image serving as the reference among the light emission image and the plurality of light emission images An example of combining is realized.

システム制御部101は、i回目の処理において算出した差分情報に基づいて、i−1回の処理までに合成された画像と、i回目の処理において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像との合成割合を変えるのが好ましい。具体的にシステム制御部101は、i回目の処理(S602)で算出された差分情報(差分値)が大きい領域ほど、i−1回の処理までに合成された画像の割合を大きくする。i回目の処理(S602)で算出された差分情報(差分値)の値が極端に大きい領域については、i回目の処理において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像の合成割合を0(ゼロ)にする。この場合、当該領域は、i−1回の処理までに合成された画像になる。例えば、差分情報(差分値)の範囲と、合成割合との関係を予め設定しておくことで、システム制御部101は、合成割合を決定することができる。本実施形態では、このようにして、前記基準となる画像の画素情報と、前記基準となる画像と異なる画像の画素情報との差分に応じて、既に合成されている画像と、当該基準となる画像と異なる画像とを合成する割合を決定することの一例が実現される。   Based on the difference information calculated in the i-th process, the system control unit 101 calculates the difference between the frames compared to the image synthesized up to the i-1th process and the synthesized reference image in the i-th process. It is preferable to change the composition ratio with the image for which information is calculated. Specifically, the system control unit 101 increases the ratio of the images synthesized by the process of i-1 times as the area in which the difference information (difference value) calculated in the i-th process (S602) is larger. An image in which an inter-frame difference value (difference information) is calculated with respect to a combined reference image in an area where the value of difference information (difference value) calculated in the i-th process (S602) is extremely large Set the composition ratio of to 0 (zero). In this case, the area is an image synthesized by i-1 times of processing. For example, the system control unit 101 can determine the combining ratio by setting in advance the relationship between the range of difference information (difference value) and the combining ratio. In this embodiment, in this way, an image which has already been synthesized according to the difference between the pixel information of the reference image and the pixel information of the image different from the reference image, and the reference An example of determining the proportion of combining an image with a different image is realized.

次に、S604において、システム制御部101は、レジスタの値iをインクリメントする。そして、処理は、S601のステップに戻る。
以上の処理を繰り返し、図3(b)〜図3(d)に示す非フラッシュ画像320、330、340と図4(a)に示すフラッシュ画像410とを合成することで、図4(b)に示す背景画像420が生成される。
Next, in step S604, the system control unit 101 increments the value i of the register. Then, the process returns to the step of S601.
The above processing is repeated, and the non-flash images 320, 330, and 340 shown in FIGS. 3B to 3D and the flash image 410 shown in FIG. A background image 420 shown in FIG.

図7(a)〜図7(c)に示す差分情報710、720、730を用いることで、例えば、以下のようにすることができる。即ち、差分情報(差分値)が大きい領域については、i−1回目の処理までに合成された画像を得ることができる(図4(b)に示す領域403、404を参照)。それ以外の領域については、i−1回の処理までに合成された画像と、i回目の処理において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像との加重平均をとった画像を得ることができる(図4(b)に示す領域405を参照)。即ち、各回(各i)のS603において、重み(合成割合)を領域毎に変えながら、i−1回の処理までに合成された画像と、i回目の処理において合成基準画像に対しフレーム間の差分値(差分情報)を算出した画像とを合成することができる。従って、図4(b)に示す背景画像420は、図3(b)に示す非フラッシュ画像320に比べ、領域405の領域におけるノイズが低減された画像となる。   By using the difference information 710, 720, and 730 shown in FIGS. 7A to 7C, for example, the following can be performed. That is, for an area where the difference information (difference value) is large, it is possible to obtain an image synthesized by the (i-1) -th process (see areas 403 and 404 shown in FIG. 4B). For the other areas, a weighted average of the image synthesized by the i-1th process and the image for which the inter-frame difference value (difference information) is calculated with respect to the synthesized reference image in the i-th process is taken. An image can be obtained (see region 405 shown in FIG. 4 (b)). That is, in S603 of each time (each i), while changing the weight (composition ratio) for each area, the image synthesized by the process of i-1 times and the frame between the synthesized reference image in the i-th process It is possible to combine an image for which a difference value (difference information) has been calculated. Therefore, the background image 420 illustrated in FIG. 4B is an image in which noise in the area 405 is reduced as compared to the non-flash image 320 illustrated in FIG. 3B.

続いて、図8および図9を参照しながら、図2のS203の主要被写体置き換え領域検出処理の一例を詳しく説明する。図8は、主要被写体置き換え領域検出処理の一例を説明するフローチャートである。図9は、主要被写体置き換え領域を検出する方法の一例を説明する図である。
S800において、システム制御部101は、被写体が動いている領域の動きベクトルを抽出する。以下の説明では、被写体が動いている領域を、必要に応じて動き領域と称する。システム制御部101は、ゲインが調整されたフラッシュ画像410と複数の非フラッシュ画像320、330、340とを用いて動きベクトル(動き領域の動く方向と動き量を示すベクトル)を抽出する。
Subsequently, an example of the main subject replacement area detection process of S203 of FIG. 2 will be described in detail with reference to FIGS. 8 and 9. FIG. 8 is a flowchart for explaining an example of the main subject replacement area detection process. FIG. 9 is a diagram for explaining an example of a method of detecting the main subject replacement area.
In step S800, the system control unit 101 extracts a motion vector of an area in which the subject is moving. In the following description, the area in which the subject is moving is referred to as a moving area as necessary. The system control unit 101 extracts a motion vector (a vector indicating a moving direction and a motion amount of a motion area) using the flash image 410 whose gain is adjusted and the plurality of non-flash images 320, 330, and 340.

ここでは、時系列的に隣り合う非フラッシュ画像間の差分領域901、902を基にして動きベクトルを算出する領域を特定する場合を例に挙げて説明する。システム制御部101は、非フラッシュ画像320、330のフレーム間の差分領域(前述した差分値)を算出し、差分値の絶対値が閾値を上回る領域を差分領域901とする。同様に、システム制御部101は、非フラッシュ画像330、340のフレーム間の差分領域(前述した差分値)を算出し、差分値の絶対値が閾値を上回る領域を差分領域902とする。差分領域901、902は、動きベクトルを特定する領域である。   Here, a case where a region for calculating a motion vector is specified based on the difference regions 901 and 902 between non-flash images adjacent in time series will be described as an example. The system control unit 101 calculates a difference area (the above-described difference value) between frames of the non-flash images 320 and 330, and sets an area where the absolute value of the difference value exceeds a threshold as the difference area 901. Similarly, the system control unit 101 calculates a difference area (the above-described difference value) between the frames of the non-flash images 330 and 340, and sets an area where the absolute value of the difference value exceeds the threshold as the difference area 902. The difference areas 901 and 902 are areas for specifying motion vectors.

そして、システム制御部101は、差分領域901、902(動き領域)に対する動きベクトルを算出する。システム制御部101は、例えば、差分領域901に含まれる領域のうち、時間的に遅く撮像された画像に対応する領域の重心から時間的に早く撮像された画像に対応する領域の重心に向かうベクトルを差分領域901に対する動きベクトルとする。例えば、差分領域901について、時間的に早く撮像された画像に対応する領域は、1枚目の非フラッシュ画像320において、2枚目の非フラッシュ画像330に対し明るさが大きく異なる領域である。時間的に遅く撮像された画像に対応する領域は、2枚目の非フラッシュ画像330において、1枚目の非フラッシュ画像320に対し明るさが大きく異なる領域である。差分領域902についても差分領域901と同様にして動きベクトルを算出することができる。   Then, the system control unit 101 calculates motion vectors for the difference areas 901 and 902 (motion areas). For example, the system control unit 101 determines, among the areas included in the difference area 901, a vector directed to the center of gravity of the area corresponding to the image captured earlier in time from the center of gravity of the area corresponding to the image captured late in time. As a motion vector for the difference area 901. For example, in the difference area 901, the area corresponding to the image captured earlier in time is an area where the brightness of the first non-flash image 320 is significantly different from that of the second non-flash image 330. The area corresponding to the image captured late in time is an area where the brightness of the second non-flash image 330 is significantly different from that of the first non-flash image 320. The motion vector can be calculated for the difference area 902 as well as the difference area 901.

このとき、システム制御部101は、動きベクトルを計算する範囲を、差分領域901、902の大きさに応じて変更しても良い。例えば、差分領域901、902の大きさが大きいほど、動きベクトルを計算する範囲を大きくすることができる。システム制御部101は、例えば、差分領域901、902が含まれる範囲で、動きベクトルを算出する。システム制御部101は、動きベクトルの算出により、非フラッシュ画像320、330の間、非フラッシュ画像330、340の間で、それぞれ動きベクトル903、904を求めることができる。本実施形態では、このようにして、2つの非発光画像の画素情報に閾値を上回る差分がある領域の大きさに応じて、当該2つの非発光画像における被写体の動きを示す動きベクトルを検出する範囲を変更することの一例が実現される。   At this time, the system control unit 101 may change the range for calculating the motion vector according to the size of the difference areas 901 and 902. For example, the larger the size of the difference regions 901 and 902, the larger the range for calculating the motion vector can be. For example, the system control unit 101 calculates a motion vector in a range including the difference areas 901 and 902. The system control unit 101 can obtain motion vectors 903 and 904 between the non-flash images 320 and 330 and between the non-flash images 330 and 340, respectively, by calculating the motion vector. In this embodiment, the motion vector indicating the movement of the subject in the two non-light emitting images is detected according to the size of the region where the pixel information of the two non-light emitting images has a difference exceeding the threshold. An example of changing the range is realized.

図8の説明に戻り、S801において、システム制御部101は、1枚目の非フラッシュ画像320とフラッシュ画像410との間の動き領域を予測する。図9および図10を参照しながら、動き領域を予測する方法の一例を詳しく説明する。図10は、動き領域を予測する方法の一例を説明する図である。   Returning to the description of FIG. 8, in step S <b> 801, the system control unit 101 predicts a motion area between the first non-flash image 320 and the flash image 410. An example of a method of predicting a motion area will be described in detail with reference to FIGS. 9 and 10. FIG. 10 is a diagram for explaining an example of a method of predicting a motion area.

図10において、動きベクトル1002、1003は、それぞれ図9に示す動きベクトル903、904に対応し、一つの平面上にプロットされたものである。また、移動方向1001は、動きベクトル1002、1003の方向を示す。予測ベクトル1004は、図9に示す予測ベクトル905に対応するものである。システム制御部101は、例えば、動きベクトル1002、1003の移動方向、大きさ、および位置に基づいて、予測ベクトル1004を求める。   In FIG. 10, motion vectors 1002 and 1003 correspond to the motion vectors 903 and 904 shown in FIG. 9, respectively, and are plotted on one plane. The moving direction 1001 indicates the direction of the motion vectors 1002 and 1003. The predicted vector 1004 corresponds to the predicted vector 905 shown in FIG. The system control unit 101 obtains a predicted vector 1004 based on, for example, the moving directions, the sizes, and the positions of the motion vectors 1002 and 1003.

まず、システム制御部101は、動きベクトル1002、1003から、移動方向1001を算出する。その後、システム制御部101は、動きベクトル1002の始点を終点とし、動きベクトル1002の大きさの半分の大きさを有し、移動方向1001に沿う向きのベクトルを予測ベクトル1004として算出する。本実施形態では、フラッシュ画像310と、非フラッシュ画像320、330、340の撮影間隔は非常に短い撮影となっており、移動する被写体の動きは等速運動として予測できる。また、本実施形態では、フラッシュ画像310は、非フラッシュ画像320、330、340に比べ露出時間が1段分短い。そのため、非フラッシュ画像320、330、340間の移動量に比べ、フラッシュ画像310と非フラッシュ画像320と間では、1/2倍の移動量であることが推測される。   First, the system control unit 101 calculates the movement direction 1001 from the motion vectors 1002 and 1003. Thereafter, the system control unit 101 sets the start point of the motion vector 1002 as an end point, calculates the vector having the half size of the size of the motion vector 1002, and the orientation along the movement direction 1001 as the prediction vector 1004. In the present embodiment, the photographing interval between the flash image 310 and the non-flash images 320, 330, and 340 is very short, and the movement of the moving subject can be predicted as constant velocity movement. Further, in the present embodiment, the flash image 310 has an exposure time shorter by one stage than the non-flash images 320, 330, and 340. Therefore, it is estimated that the movement amount between the flash image 310 and the non-flash image 320 is 1/2 times the movement amount between the non-flash images 320, 330, and 340.

ただし、フラッシュ画像310、非フラッシュ画像320、330、340の露出時間が極端に短い際には、露出時間の差は小さくなる。このため、予測ベクトルの大きさは、非フラッシュ画像間の動きベクトルの大きさと差がなくなる。よって、システム制御部101は、非フラッシュ画像間の動きベクトルの大きさと同じ大きさのベクトルを予測ベクトルとすることができる。予測ベクトルの大きさは、フラッシュ画像の撮影時と非フラッシュ画像の撮影時の露出時間の差に依存する。このため、システム制御部101は、露出時間の差に応じて、予測ベクトルの大きさを切り替えることを行っても良い。例えば、所定の範囲の露光時間であれば等速度運動で予測ベクトルを推定することができる。このため、システム制御部101は、例えば、フラッシュ画像と非フラッシュ画像の露出の差が2段差有る場合には、非フラッシュ画像間の動きベクトルの大きさの1/4倍の大きさのベクトルを予測ベクトルにする。
本実施形態では、以上のようにして、前記動きベクトルに基づいて、前記発光画像と前記複数の非発光画像のうちの1つの前記非発光画像との間における被写体の動きを予測する予測ベクトルを導出することの一例が実現される。
However, when the exposure times of the flash image 310 and the non-flash images 320, 330, and 340 are extremely short, the difference between the exposure times becomes small. For this reason, the magnitudes of the prediction vectors do not differ from the magnitudes of motion vectors between non-flash images. Therefore, the system control unit 101 can set a vector having the same size as the size of the motion vector between non-flash images as the prediction vector. The size of the predicted vector depends on the difference between the exposure time at the time of shooting of the flash image and the time of shooting of the non-flash image. Therefore, the system control unit 101 may switch the size of the predicted vector according to the difference in exposure time. For example, if the exposure time is within a predetermined range, the prediction vector can be estimated by constant velocity motion. Therefore, for example, when there is a difference in exposure between the flash image and the non-flash image of two steps, the system control unit 101 sets a vector having a size that is 1/4 times the size of the motion vector between the non-flash images. Make it a prediction vector.
In the present embodiment, as described above, a predicted vector for predicting the motion of the subject between the light emitting image and the non-light emitting image of one of the plurality of non-light emitting images based on the motion vector is used. An example of deriving is realized.

続いてシステム制御部101は、予測ベクトル905に対応する位置に、差分情報914に含まれる差分領域(白い領域)のうち、予測ベクトル905に最も近い位置にある差分領域906(白い領域)を、動き差分領域予測結果907として設定する。予測ベクトル905に対応する位置は、例えば、予測ベクトル905の大きさ、向き、および位置に基づいて定められる。尚、差分情報914、差分領域906の導出は、前述した方法と同様の方法で実現される。動き差分領域予測結果907は、差分情報の予測結果である。   Subsequently, the system control unit 101 sets the difference area 906 (white area) at the position closest to the prediction vector 905 in the difference area (white area) included in the difference information 914 at the position corresponding to the prediction vector 905. The motion difference area prediction result 907 is set. The position corresponding to the prediction vector 905 is determined based on, for example, the size, the orientation, and the position of the prediction vector 905. Derivation of the difference information 914 and the difference area 906 is realized by the same method as the method described above. The motion difference area prediction result 907 is a prediction result of difference information.

本実施形態では、例えば、差分情報914により、前記発光画像の画素情報と前記複数の非発光画像のうちの1つの前記非発光画像の画素情報との差分を示す画像である第1の差分画像の一例が実現される。また、例えば、図9において、非フラッシュ画像320、330間の差分情報(差分領域901を含む差分情報)により、前記複数の非発光画像のうちの2つの非発光画像の画素情報の差分を示す画像である第2の差分画像の一例が実現される。同様に、図9において、非フラッシュ画像330、340間の差分情報(差分領域902を含む差分情報)により、前記複数の非発光画像のうちの2つの非発光画像の画素情報の差分を示す画像である第2の差分画像の一例が実現される。   In the present embodiment, for example, a first difference image which is an image indicating the difference between the pixel information of the light emission image and the pixel information of the non-light emission image of one of the plurality of non-light emission images by the difference information 914. An example is realized. Also, for example, in FIG. 9, the difference information between the non-flash images 320 and 330 (difference information including the difference area 901) indicates the difference between the pixel information of two non-emission images among the plurality of non-emission images. An example of a second difference image that is an image is realized. Similarly, in FIG. 9, an image showing differences in pixel information of two non-emission images among the plurality of non-emission images by difference information between the non-flash images 330 and 340 (difference information including the difference area 902). An example of the second difference image, which is

図8の説明に戻り、S802において、システム制御部101は、フラッシュ画像410と非フラッシュ画像320との差分情報914に含まれる差分領域(白い領域)のうち、動き差分領域予測結果907に対応する差分領域906を除去する。このように本実施形態では、例えば、差分領域906により、動きのある被写体の領域の一例が実現される。また、差分情報914内の差分領域906以外の差分領域(白い領域)により、動きのない被写体の領域の一例が実現される。このように本実施形態では、例えば、差分情報914と予測ベクトル905とに基づいて動き差分領域予測結果907が導出され、動き差分領域予測結果907に基づいて差分領域906が検出され除去される。従って、前記発光画像の画素情報と前記複数の非発光画像のうちの1つの前記非発光画像の画素情報との差分を示す第1の差分画像と、前記予測ベクトルとに基づいて、前記発光画像において動きのある被写体の領域が検出される。   Returning to the description of FIG. 8, in step S802, the system control unit 101 corresponds to the motion difference region prediction result 907 among the difference regions (white regions) included in the difference information 914 between the flash image 410 and the non-flash image 320. The difference area 906 is removed. As described above, in the present embodiment, for example, the difference area 906 realizes an example of the area of the subject with motion. Further, the difference area (white area) other than the difference area 906 in the difference information 914 realizes an example of the area of the subject without motion. Thus, in the present embodiment, for example, the motion difference region prediction result 907 is derived based on the difference information 914 and the prediction vector 905, and the difference region 906 is detected and removed based on the motion difference region prediction result 907. Therefore, based on the first difference image indicating the difference between the pixel information of the light emission image and the pixel information of the non-light emission image of one of the plurality of non-light emission images, the light emission image based on the prediction vector The area of the subject with motion is detected at.

以上のように動き差分領域予測結果907を用いれば、予測ベクトル905の算出精度が低い場合であっても、差分領域906を特定して除去することができる。しかしながら、システム制御部101は、予測ベクトル905の算出精度が高く、予測ベクトル905だけから差分領域906を正確に導出することができる場合、差分情報914に含まれる差分領域906を予測ベクトル905から直接特定して除去してもよい。   As described above, by using the motion difference area prediction result 907, even if the calculation accuracy of the prediction vector 905 is low, the difference area 906 can be identified and removed. However, when the calculation accuracy of the prediction vector 905 is high and the difference area 906 can be accurately derived from only the prediction vector 905, the system control unit 101 directly adds the difference area 906 included in the difference information 914 from the prediction vector 905. It may be identified and removed.

このようにしてシステム制御部101は、フラッシュ画像410と非フラッシュ画像320との差分情報914から、差分領域906を除去した後に差分情報914に含まれる差分領域(白い領域)を、主要被写体置き換え領域908として検出する。差分情報914には、動いていない主要被写体と動いている被写体とのそれぞれが差分領域として含まれている。このため、動き差分領域予測結果907である差分領域を取り除くことで、動いている被写体が含まれる領域を除去することができる。従って、システム制御部101は、ストロボ光が当たっている主要被写体の領域(主要被写体置き換え領域908)を検出することができる。   In this manner, the system control unit 101 removes the difference area 906 from the difference information 914 between the flash image 410 and the non-flash image 320, and then the difference area (white area) included in the difference information 914 Detect as 908. The difference information 914 includes, as difference areas, the main subject that is not moving and the moving subject. Therefore, by removing the difference area that is the motion difference area prediction result 907, the area including the moving subject can be removed. Therefore, the system control unit 101 can detect the area of the main subject illuminated by the strobe light (main subject replacement area 908).

以上説明したように、本実施形態では、デジタルカメラ100は、非フラッシュ画像320、330、340の差分領域901、902を用いて、動いている被写体の動きを予測する予測ベクトル905を算出する。デジタルカメラ100は、フラッシュ画像410と非フラッシュ画像320の差分領域のうち、予測ベクトル905に対応する差分領域906を除く領域を主要被写体置き換え領域908とする。デジタルカメラ100は、背景画像420の領域のうち、主要被写体置き換え領域908に対応する領域の画像を、フラッシュ画像310に置き換えて最終画像とする。従って、動いている被写体があっても、フラッシュ画像310に含まれる被写体の領域のうち、ストロボ光が当たっている領域を適切に判別して抽出することができる。よって、例えば、夜景と主要被写体との双方の明るさが適正となる画像を好適に生成することが可能となる。   As described above, in the present embodiment, the digital camera 100 uses the difference areas 901 and 902 of the non-flash images 320, 330, and 340 to calculate the prediction vector 905 for predicting the motion of the moving subject. In the difference area between the flash image 410 and the non-flash image 320, the digital camera 100 sets an area excluding the difference area 906 corresponding to the predicted vector 905 as a main subject replacement area 908. The digital camera 100 replaces the image of the area corresponding to the main subject replacement area 908 in the area of the background image 420 with the flash image 310 as the final image. Therefore, even if there is a moving subject, it is possible to appropriately determine and extract the area where the strobe light is applied among the areas of the subject included in the flash image 310. Therefore, for example, it is possible to preferably generate an image in which the brightness of both the night scene and the main subject is appropriate.

尚、本実施形態では、背景画像生成処理で用いた差分情報(図6のS602で求める差分情報)と、主要被写体置き換え領域検出処理で用いた差分情報(図8のS800で求める差分情報)を別々に求める場合を例に挙げて説明した。しかしながら、これらの処理で共通の差分情報を用いても良い。例えば、主要被写体置き換え領域検出処理における図8のS800では、システム制御部101は、図6のS602と同じく非フラッシュ画像320を基準にした2つの画像間の動きベクトルを求める。具体的にシステム制御部101は、非フラッシュ画像320、330間の動きベクトルと、非フラッシュ画像320、340間の動きベクトルとを求める。このように共通の差分情報を用いることで、演算量や処理時間を短縮することが可能となる。   In the present embodiment, the difference information (difference information obtained in S602 of FIG. 6) used in the background image generation process and the difference information (difference information obtained in S800 of FIG. 8) used in the main subject replacement area detection process The case of separately obtaining is described as an example. However, common difference information may be used in these processes. For example, in S800 of FIG. 8 in the main subject replacement area detection processing, the system control unit 101 obtains a motion vector between two images based on the non-flash image 320 as in S602 of FIG. Specifically, the system control unit 101 obtains a motion vector between the non-flash images 320 and 330 and a motion vector between the non-flash images 320 and 340. By using common difference information in this manner, it is possible to reduce the amount of computation and the processing time.

また、本実施形態では、主要被写体置き換え領域検出処理(図8のS801)において、予測ベクトルを用いて動き領域の予測を行う構成を説明したが、これに限らなくても良い。例えば、複数の非フラッシュ画像320、330、340によって求めたフレーム間の差分情報の形状、大きさ、および位置を用いて、図9に示す動き差分領域予測結果907を特定しても良い。図11を参照しながら、動き領域の予測を行う方法の変形例を詳しく説明する。図11(a)、図11(b)は、それぞれ図9に示す差分領域901、902を含む差分情報1110、1120(非フラッシュ画像320、330間の差分情報、非フラッシュ画像330、340間の差分情報)を示す。   Further, in the present embodiment, the configuration for performing motion area prediction using a prediction vector in the main subject replacement area detection process (S801 in FIG. 8) has been described, but the present invention is not limited thereto. For example, the motion difference region prediction result 907 shown in FIG. 9 may be specified using the shape, size, and position of the difference information between the frames obtained by the plurality of non-flash images 320, 330, and 340. A modification of the method of performing motion area prediction will be described in detail with reference to FIG. 11A and 11B show difference information 1110 and 1120 (difference information between non-flash images 320 and 330, non-flash images 330 and 340, respectively) including difference areas 901 and 902 shown in FIG. Indicates difference information).

フラッシュ画像310、非フラッシュ画像320、330、340を取得するサンプリング周期は短いため、システム制御部101は、動いている被写体(差分領域901、902)が等速直線運動するものとするものと仮定する。この仮定の下、システム制御部101は、フラッシュ画像310、非フラッシュ画像320、330、340を取得するサンプリング周期分だけ差分領域901を等速直線運動させた差分領域1103を、図11(c)に示す動き差分領域予測結果1130とする。差分領域901、902の領域情報を用いて動き差分領域予測結果1130を求めることで、動きベクトル903、904および予測ベクトル905を求める演算処理が必要なくなり処理時間を短縮することが可能となる。   Since the sampling period for acquiring the flash image 310 and the non-flash images 320, 330, and 340 is short, the system control unit 101 assumes that the moving subject (difference regions 901 and 902) performs linear motion at constant velocity. Do. Under this assumption, the system control unit 101 causes the difference area 1103 in which the difference area 901 is linearly moved at the same speed by the sampling period for acquiring the flash image 310 and the non-flash images 320, 330, and 340, as shown in FIG. The motion difference area prediction result 1130 shown in FIG. Determining the motion difference region prediction result 1130 using the region information of the difference regions 901 and 902 eliminates the need for calculation processing for obtaining the motion vectors 903 and 904 and the prediction vector 905, and makes it possible to shorten the processing time.

また、本実施形態では、1枚のフラッシュ画像と3枚の非フラッシュ画像の計4回の撮像(ただし、フラッシュ画像のゲイン調整は含めない)する構成について説明を行ったが、撮像枚数に限りはない。撮像枚数を増やして(非フラッシュ画像の数を3以上にして)本実施形態の処理を行うことでノイズ低減効果を向上させることができる。また、ベクトルの方向、位置、および大きさを算出するための画像の枚数が増えるため、動き領域予測(図8のS801)の予測精度を高めることができる。   Further, in the present embodiment, the configuration is described in which imaging of one flash image and three non-flash images is performed a total of four times (however, gain adjustment of the flash image is not included). There is no. The noise reduction effect can be improved by performing the processing of the present embodiment by increasing the number of captured images (by setting the number of non-flash images to 3 or more). Further, since the number of images for calculating the direction, position, and size of the vector is increased, it is possible to improve the prediction accuracy of the motion area prediction (S801 in FIG. 8).

また、デジタルカメラ100の位置が三脚等で固定されている場合には、位置合わせ処理(図2のS201)を行わなくてもよい。このようにすれば、処理時間を短縮することが可能となる。   Further, when the position of the digital camera 100 is fixed by a tripod or the like, the alignment process (S201 in FIG. 2) may not be performed. In this way, the processing time can be shortened.

(第2の実施形態)
次に、第2の実施形態を説明する。第1の実施形態では、ユーザによる入力操作部115の操作やタイマ撮影等による撮影指示に伴う本撮影により取得した3枚の非フラッシュ画像320、330、340を用いる場合を例に挙げて説明した。これに対し、本実施形態では、ライブビュー用画像(プレビュー用画像)を用いて、明るさの差分情報を求めて動きベクトルを求め、求めた動きベクトルから予測ベクトルを求める。そして、予測ベクトルと、本撮影により取得した2枚の画像(フラッシュ画像および非フラッシュ画像)の差分情報とを用いて動いている被写体の領域を取り除いて主要被写体の領域を求める。そして、フラッシュ画像に含まれる主要被写体の領域における画像と非フラッシュ画像(の主要被写体の領域以外の領域)とを合成する。
Second Embodiment
Next, a second embodiment will be described. In the first embodiment, the case of using the three non-flash images 320, 330, and 340 acquired by the main photographing accompanying the photographing instruction by the operation of the input operation unit 115 by the user or the timer photographing is described as an example. . On the other hand, in the present embodiment, using the live view image (preview image), brightness difference information is obtained to obtain a motion vector, and a predicted vector is obtained from the obtained motion vector. Then, the area of the main subject is determined by removing the area of the moving subject using the predicted vector and the difference information of the two images (flash image and non-flash image) acquired by the main photographing. Then, the image in the area of the main subject included in the flash image and the non-flash image (an area other than the area of the main subject) are synthesized.

このように本実施形態と第2の実施形態とは、動いている被写体を特定するための処理の一部が主として異なる。従って、本実施形態の説明において、第1の実施形態と同一の部分については、図1〜図11に付した符号と同一の符号を付す等して詳細な説明を省略する。以下の説明では、ライブビュー用画像を必要に応じて画面表示用画像または画面表示用非フラッシュ画像と称する。また、本撮影により得られるフラッシュ画像を必要に応じて本撮影フラッシュ画像と称し、本撮影により得られる非フラッシュ画像を必要に応じて本撮影非フラッシュ画像と称し、これらを必要に応じて本撮影画像と総称する。   As described above, in the present embodiment and the second embodiment, a part of the process for identifying the moving subject is mainly different. Accordingly, in the description of the present embodiment, the same parts as those of the first embodiment will be denoted by the same reference numerals as those of the reference numerals in FIGS. In the following description, the live view image is referred to as a screen display image or a screen display non-flash image as needed. Further, a flash image obtained by the main shooting is referred to as a main shooting flash image as needed, and a non-flash image obtained by the main shooting is referred to as a main shooting non-flash image as required, and these are as required Collectively referred to as an image.

本実施形態では、ゲインが調整されたフラッシュ画像と複数の非フラッシュ画像とから背景画像を作成する処理を行わない。このため、本撮影前に取得するライブビュー用画像から求めた動きベクトルを基にしてフラッシュ画像と非フラッシュ画像とのフレーム間の動き領域の予測ベクトルを算出する。
本実施形態のデジタルカメラ100構成は、図1に示す第1の実施形態のデジタルカメラ100の構成と同じであるため、その詳細な説明を省略する。
In the present embodiment, a process of creating a background image from the flash image whose gain has been adjusted and a plurality of non-flash images is not performed. Therefore, based on the motion vector obtained from the live view image acquired before the main shooting, a predicted vector of the motion area between the flash image and the non-flash image is calculated.
The configuration of the digital camera 100 according to the present embodiment is the same as the configuration of the digital camera 100 according to the first embodiment shown in FIG.

また、本実施形態では、画面表示用画像を用いる。従って、図1に示すメモリ107は、本撮影により取得される画像データの他にカメラ処理の評価値を取得する画像や画面表示用画像を格納する。本実施形態では、本撮影により取得される画像データであるフラッシュ画像と非フラッシュ画像の他に、画面表示用画像を用いる。   In the present embodiment, a screen display image is used. Therefore, the memory 107 illustrated in FIG. 1 stores an image for acquiring an evaluation value of camera processing and an image for screen display in addition to the image data acquired by the main photographing. In the present embodiment, an image for screen display is used in addition to a flash image and a non-flash image which are image data acquired by main imaging.

図12のフローチャートを参照しながら、本実施形態のデジタルカメラ100の全体処理の一例を説明する。尚、第1の実施形態と同じ処理についての詳細な説明は省略する。図2に示すフローチャートは、デジタルカメラ100において撮影の指示がなされた際に開始される。これに対し、図12に示すフローチャートは、デジタルカメラ100において撮影の指示がなされる前に開始される。   An example of the entire process of the digital camera 100 of the present embodiment will be described with reference to the flowchart of FIG. 12. The detailed description of the same processing as that of the first embodiment is omitted. The flowchart shown in FIG. 2 is started when an instruction for photographing is given in the digital camera 100. On the other hand, the flowchart shown in FIG. 12 is started before the photographing instruction is given in the digital camera 100.

S1200において、システム制御部101は、撮影処理を行う。具体的にシステム制御部101は、ユーザまたはデジタルカメラ100のタイマ撮影等による撮影指示がなされる前には、画面表示用画像の撮像処理を続ける。その後、撮影指示がなされた後に、システム制御部101は、本撮影を行い、フラッシュ画像と非フラッシュ画像を1枚ずつ連続して撮像する。図13は、画面表示用画像と本撮影画像の一例を説明する図である。   In step S1200, the system control unit 101 performs an imaging process. Specifically, the system control unit 101 continues the imaging process of the screen display image before an imaging instruction is issued by the user or timer imaging of the digital camera 100 or the like. Thereafter, after a shooting instruction is issued, the system control unit 101 performs a main shooting and continuously captures a flash image and a non-flash image one by one. FIG. 13 is a diagram for explaining an example of a screen display image and an actual photographed image.

図13において、画面表示用非フラッシュ画像1301〜1303は、撮影指示前に撮像された画面表示用画像として非フラッシュ画像である。1枚目の画面表示用非フラッシュ画像1301、2枚目の画面表示用非フラッシュ画像1302、3枚目の画面表示用非フラッシュ画像1303の順に連続して撮像されているものとする。その後、撮影指示がなされた後で、デジタルカメラ100は、本撮影画像である本撮影フラッシュ画像1304と本撮影非フラッシュ画像1305をこの順で連続して撮像する。本撮影非フラッシュ画像1305は、第1の実施形態と異なり長時間露光し、画面表示用非フラッシュ画像1301〜1303の露光時間と異なる構成をとっても良い。また、撮影指示がなされる前に取得する画面表示用の画像は、メモリ107の容量に収まる範囲でメモリ107に複数枚保持される。本実施形態では、例えば、画面表示用非フラッシュ画像1301〜1303により、画面に表示するための画像の一例が実現される。また、例えば、本撮影フラッシュ画像1304および本撮影非フラッシュ画像1305により、撮影指示に基づいて本撮影された画像の一例が実現される。   In FIG. 13, the non-flash images for screen display 1301 to 1303 are non-flash images as the image for screen display taken before the imaging instruction. It is assumed that the first screen display non-flash image 1301, the second screen display non-flash image 1302, and the second screen display non-flash image 1303 are sequentially captured in order. Thereafter, after a shooting instruction is issued, the digital camera 100 continuously captures the main shooting flash image 1304 and the main shooting non-flash image 1305, which are main shooting images, in this order. The main non-flash image 1305 may be exposed for a long time unlike the first embodiment, and may have a configuration different from the exposure time of the non-flash images 1301 to 1303 for screen display. In addition, a plurality of images for screen display acquired before the imaging instruction is issued are held in the memory 107 in a range that fits in the capacity of the memory 107. In the present embodiment, for example, the non-flash images 1301 to 1303 for screen display realize an example of an image to be displayed on the screen. Also, for example, the main photographing flash image 1304 and the main photographing non-flash image 1305 realize an example of the main photographing image based on the photographing instruction.

次に、S1201において、システム制御部101は、本撮影フラッシュ画像1304と本撮影非フラッシュ画像1305とを合成するための主要被写体置き換え領域検出処理を行う。図14を参照しながら、本実施形態の主要被写体置き換え領域を検出する方法の一例を用いて詳しく述べる。
図14において、本撮影フラッシュ画像1410は、本撮影フラッシュ画像1304に対し、背景領域の明るさが本撮影非フラッシュ画像1305の明るさと合うようにゲインが調整された画像である。
Next, in step S1201, the system control unit 101 performs main subject replacement area detection processing for combining the main shooting flash image 1304 and the main shooting non-flash image 1305. This will be described in detail using an example of a method of detecting the main subject replacement area according to the present embodiment with reference to FIG.
In FIG. 14, the real shooting flash image 1410 is an image whose gain is adjusted so that the brightness of the background area matches the brightness of the real shooting non-flash image 1305 with respect to the real shooting flash image 1304.

第1の実施形態では本撮影された非フラッシュ画像320、330、340から動きベクトル903、904を求め、その動きベクトル903、904を用いて予測ベクトル905を求めて、動いている被写体の動き予測を行う。これに対し、本実施形態では、画面表示用非フラッシュ画像を用いて動きベクトルおよび予測ベクトルを求める。システム制御部101は、例えば、画面表示用非フラッシュ画像1301、1302間の差分領域1401を算出する。更に、システム制御部101は、差分領域1401において動きベクトル1403を算出する。同様にシステム制御部101は、画面表示用非フラッシュ画像1302、1303間の差分領域1402を算出し、差分領域1402において動きベクトル1404を算出する。差分領域1401、1402および動きベクトル1403、1404を求める方法自体は、第1の実施形態で説明した方法と同じである。   In the first embodiment, motion vectors 903 and 904 are obtained from the captured non-flash images 320, 330 and 340, and motion vectors 903 and 904 are used to obtain a prediction vector 905 to predict the motion of a moving subject. I do. On the other hand, in the present embodiment, the motion vector and the prediction vector are obtained using the non-flash image for screen display. The system control unit 101 calculates, for example, a difference area 1401 between the screen display non-flash images 1301 and 1302. Furthermore, the system control unit 101 calculates a motion vector 1403 in the difference area 1401. Similarly, the system control unit 101 calculates a difference area 1402 between the non-flash image for screen display 1302 and 1303, and calculates a motion vector 1404 in the difference area 1402. The method itself for obtaining the difference regions 1401 and 1402 and the motion vectors 1403 and 1404 is the same as the method described in the first embodiment.

次に、システム制御部101は、第1の実施形態で説明したのと同じ方法で動きベクトル1403、1404を用いて予測ベクトル1405を算出する。その後、システム制御部101は、第1の実施形態で説明したのと同じ方法で、ゲイン調整後の本撮影フラッシュ画像1410と本撮影非フラッシュ画像1305との差分情報1414と予測ベクトル1405とを基に、動き差分領域予測結果1407を算出する。最後に、システム制御部101は、第1の実施形態で説明したのと同じ方法で、差分情報1414と、動き差分領域予測結果1407とを基に、差分情報1414に含まれる差分領域1406を除去し、主要被写体置き換え領域1408を抽出する。   Next, the system control unit 101 calculates a prediction vector 1405 using the motion vectors 1403 and 1404 in the same manner as described in the first embodiment. After that, the system control unit 101 uses the difference information 1414 between the main shooting flash image 1410 after the gain adjustment and the main shooting non-flash image 1305 and the prediction vector 1405 in the same manner as described in the first embodiment. Then, the motion difference area prediction result 1407 is calculated. Finally, the system control unit 101 removes the difference area 1406 included in the difference information 1414 based on the difference information 1414 and the motion difference area prediction result 1407 in the same manner as described in the first embodiment. The main subject replacement area 1408 is extracted.

図12の説明に戻り、S1202において、システム制御部101は、S1201の処理で求めた主要被写体置き換え領域1408の検出の結果に基づいて、本撮影フラッシュ画像1304と本撮影非フラッシュ画像1305とを合成する。これらの画像の合成方法は、第1の実施形態における、フラッシュ画像310と背景画像420とを合成する処理の説明において、背景画像420を本撮影非フラッシュ画像1315に置き換えることにより実現することができるので、その詳細な説明を省略する。   Referring back to FIG. 12, in step S1202, the system control unit 101 combines the main shooting flash image 1304 and the main shooting non-flash image 1305 based on the detection result of the main subject replacement area 1408 obtained in the processing of S1201. Do. The method of combining these images can be realized by replacing the background image 420 with the real shooting non-flash image 1315 in the description of the process of combining the flash image 310 and the background image 420 in the first embodiment. Therefore, the detailed description is omitted.

以上のように本実施形態では、デジタルカメラ100は、画面表示用非フラッシュ画像1301〜1303を用いて動き差分領域予測結果1407を算出する。従って、本撮影において撮像する画像が、フラッシュ画像と非フラッシュ画像の2枚の画像であっても、動き領域を排除した主要被写体置き換え領域を抽出することができ、合成後の画像で動き領域の弊害を改善することができる。   As described above, in the present embodiment, the digital camera 100 calculates the motion difference region prediction result 1407 using the non-flash images 1301 to 1303 for screen display. Therefore, even if the image captured in the main shooting is two images of a flash image and a non-flash image, it is possible to extract the main subject replacement area excluding the moving area. It can improve the harmful effect.

本実施形態では、撮影指示が出されるまでの画面表示用非フラッシュ画像1301〜1303を複数保持し、撮影指示が出された後の本撮影フラッシュ画像1304および本撮影非フラッシュ画像1305を用いる構成を例に挙げて説明した。しかしながら、本実施形態の処理を行うことが、デジタルカメラ100におけるモード等の設定により分かっている場合、撮影指示が出される前の画面表示用非フラッシュ画像を用いて撮影指示の前に予め動きベクトル1403、1404を求めておいても良い。この構成をとることで、画面表示用非フラッシュ画像を常に保持しておく必要が無く、更に本撮影がなされたときに動きベクトルがすでに算出されているので処理速度の改善に有効である。更に、予測ベクトル1405を撮影指示の前に求めておいても良い。   In the present embodiment, a configuration is used in which a plurality of non-flash images for screen display 1301 to 1303 until the imaging instruction is output is held, and the main imaging flash image 1304 and the main imaging non-flash image 1305 after the imaging instruction is output. An example has been described. However, when it is known that the processing of the present embodiment is performed by the setting of the mode or the like in the digital camera 100, the motion vector is previously made before the photographing instruction using the non-flash image for screen display before the photographing instruction is issued. It is also possible to request 1403 and 1404. With this configuration, there is no need to always hold a non-flash image for screen display, and motion vectors are already calculated when main shooting is performed, which is effective in improving the processing speed. Furthermore, the predicted vector 1405 may be obtained before the imaging instruction.

また、本実施形態では、撮影指示が出されるまでの画面表示用非フラッシュ画像1301〜1303を複数保持し、撮影指示が出された後の本撮影フラッシュ画像1304および本撮影非フラッシュ画像1305を用いる構成を例に挙げて説明した。しかしながら、撮影指示が出された後、本撮影フラッシュ画像1304および本撮影非フラッシュ画像1305を撮像し、その後、画面表示用非フラッシュ画像を複数保持する構成をとっても良い。この構成をとることで、本施形態の処理を行わない場合には画面表示用画像を複数保持しておく必要が無くメモリの節約に有効である。
また、本実施形態においても、第1の実施形態で説明した変形例を適用することができる。
Further, in the present embodiment, a plurality of non-flash images 1301 to 1303 for screen display until the imaging instruction is issued are held, and the main imaging flash image 1304 and the main imaging non-flash image 1305 after the imaging instruction is output are used. The configuration has been described by way of example. However, after the photographing instruction is issued, the main photographing flash image 1304 and the main photographing non-flash image 1305 may be photographed, and thereafter, a plurality of screen display non-flash images may be held. By adopting this configuration, it is not necessary to hold a plurality of screen display images when processing of the present embodiment is not performed, which is effective in saving memory.
Also in the present embodiment, the modification described in the first embodiment can be applied.

(第3の実施形態)
次に、第3の実施形態を説明する。第1、第2の実施形態では、フラッシュ画像と非フラッシュ画像との差分情報の全体において差分領域の動きを求め、動きのない差分領域を、主要被写体置き換え領域として算出する例を挙げて説明した。これに対し本実施形態では、ストロボ光の適正発光距離にある被写体の領域以外の領域をマスク領域として、マスク領域については、差分領域の動きを求めない。このように本実施形態と第1、第2の実施形態とでは、動いている被写体を特定するための処理の一部が主として異なる。従って、本実施形態の説明において、第1、第2の実施形態と同一の部分については、図1〜図14に付した符号と同一の符号を付す等して詳細な説明を省略する。
Third Embodiment
Next, a third embodiment will be described. In the first and second embodiments, the movement of the difference area is obtained in the entire difference information between the flash image and the non-flash image, and the difference area without movement is calculated as the main subject replacement area. . On the other hand, in the present embodiment, the movement of the difference area is not obtained for the mask area, with the area other than the area of the subject at the proper emission distance of the strobe light as the mask area. As described above, in the present embodiment and the first and second embodiments, a part of the process for identifying the moving subject is mainly different. Therefore, in the description of the present embodiment, the same parts as those in the first and second embodiments are denoted by the same reference numerals as those in FIGS. 1 to 14, and the detailed description will be omitted.

本実施形態のデジタルカメラ100の構成は、図1に示す第1の実施形態のデジタルカメラ100の構成と同じであるため、その詳細な説明を省略する。
図15のフローチャートを参照しながら、本実施形態のデジタルカメラ100の全体処理の一例を説明する。尚、第1、第2の実施形態と同じ処理についての詳細な説明は省略する。
The configuration of the digital camera 100 according to the present embodiment is the same as the configuration of the digital camera 100 according to the first embodiment shown in FIG.
An example of the overall processing of the digital camera 100 of the present embodiment will be described with reference to the flowchart of FIG. The detailed description about the same processing as the first and second embodiments is omitted.

S1501において、システム制御部101は、本撮影フラッシュ画像1304と本撮影非フラッシュ画像1305とを合成するための主要被写体置き換え領域検出処理を行う。
本実施形態では、システム制御部101は、適正発光距離情報の領域を設定する。例えば、システム制御部101は、撮影レンズ121の絞り値(F値)とガイドナンバーから適正発光距離情報を算出すると共に、奥行き情報を算出する。適正発光距離情報は、ストロボ光が適正にとどくデジタルカメラ100からの距離を示す情報である。シーンの奥行き情報は、デジタルカメラ100から被写体までの距離を示す情報である。そして、システム制御部101は、適正発光距離情報と奥行き情報とに基づいて、ストロボ光の適正発光距離の被写体の範囲だけを、動きベクトルを求める領域とする。
In step S1501, the system control unit 101 performs main subject replacement area detection processing for combining the main shooting flash image 1304 and the main shooting non-flash image 1305.
In the present embodiment, the system control unit 101 sets an area of the appropriate light emission distance information. For example, the system control unit 101 calculates the appropriate light emitting distance information from the aperture value (F value) of the photographing lens 121 and the guide number, and calculates the depth information. The proper light emitting distance information is information indicating the distance from the digital camera 100 when the strobe light properly reaches. The depth information of the scene is information indicating the distance from the digital camera 100 to the subject. Then, based on the proper light emitting distance information and the depth information, the system control unit 101 sets only the range of the subject of the proper light emitting distance of the strobe light as the area for obtaining the motion vector.

図16を参照しながら、主要被写体置き換え領域の求め方の一例を説明する。尚、ここでは、第2の実施形態の図14を参照しながら説明した処理と同じ処理についての詳細な説明を省略する。
図16において、システム制御部101は、例えば、本撮影フラッシュ画像1410の撮像時における撮影レンズ121の絞り値(F値)とガイドナンバーから、適正発光距離情報1601を取得する。これと同時にシステム制御部101は、奥行き情報1602を算出する。奥行き情報1602の算出方法としては、以下の方法が挙げられる。
An example of how to obtain the main subject replacement area will be described with reference to FIG. Here, the detailed description of the same processing as the processing described with reference to FIG. 14 of the second embodiment will be omitted.
In FIG. 16, the system control unit 101 acquires the proper light emitting distance information 1601 from, for example, the aperture value (F value) of the photographing lens 121 and the guide number at the time of photographing of the main photographing flash image 1410. At the same time, the system control unit 101 calculates depth information 1602. As a method of calculating the depth information 1602, the following method may be mentioned.

撮像素子123が瞳分割撮像素子であれば、撮像素子123から取得される視差画像(距離取得用データ)の相関演算から算出されるデフォーカス量を用いて奥行き情報1602を算出する方法が1つ目の方法として挙げられる。この方法は、特許文献3に記載されている方法を用いて実現することができる。2つ目の方法として、合焦面を変化させて撮像した複数の画像(距離取得用データ)の相関演算から算出されるデフォーカス量を用いて奥行き情報1602を算出する方法が挙げられる。この方法は、特許文献4に記載されている方法を用いて実現することができる。撮像ユニット120が複眼構成であれば、複眼画像(距離取得用データ)の相関演算から算出されるデフォーカス量を用いて奥行き情報1602を算出する方法が3つ目の方法として挙げられる。この方法は、特許文献5に記載されている方法を用いて実現することができる。尚、どの方法も距離情報を取得するための手段であり本実施形態の構成を限定するものではない。   If the imaging device 123 is a pupil division imaging device, there is one method of calculating the depth information 1602 using the defocus amount calculated from the correlation operation of the parallax image (data for distance acquisition) acquired from the imaging device 123 It is mentioned as an eye method. This method can be realized using the method described in Patent Document 3. As a second method, there is a method of calculating depth information 1602 using a defocus amount calculated from correlation calculation of a plurality of images (data for distance acquisition) captured by changing the focal plane. This method can be realized using the method described in Patent Document 4. If the imaging unit 120 has a compound eye configuration, a third method is a method of calculating the depth information 1602 using a defocus amount calculated from correlation calculation of compound eye images (data for distance acquisition). This method can be realized using the method described in Patent Document 5. Note that each method is a means for acquiring distance information, and does not limit the configuration of the present embodiment.

本実施形態では、例えば、適正発光距離情報1601により、撮像装置からの前記ストロボ光の発光距離を示す情報の一例が実現される。また、例えば、奥行き情報1602により、前記非発光画像における被写体の撮像装置からの距離を示す情報の一例が実現される。   In the present embodiment, for example, an example of information indicating the emission distance of the strobe light from the imaging device is realized by the appropriate emission distance information 1601. Also, for example, the depth information 1602 realizes an example of information indicating the distance from the imaging device of the subject in the non-emission image.

システム制御部101は、以上のようにして求めた適正発光距離情報1601と奥行き情報1602とに対応する領域を、適正フラッシュ領域マスク1603として算出する。このマスクされた領域(適正フラッシュ領域マスク1603)が、ストロボ光が画像上で適正の光としてとどいている領域1610となる。   The system control unit 101 calculates an area corresponding to the proper light emitting distance information 1601 and the depth information 1602 obtained as described above as a proper flash area mask 1603. This masked area (appropriate flash area mask 1603) becomes an area 1610 in which the strobe light travels as appropriate light on the image.

システム制御部101は、画面表示用非フラッシュ画像1301、1302間の差分領域1401および画面表示用非フラッシュ画像1302、1303間の差分領域1402が領域1610に含まれているか否かを判定する。図14および図16に示す例では、画面表示用非フラッシュ画像1301、1302間の差分領域1401および画面表示用非フラッシュ画像1302、1303間の差分領域1402が領域1610に含まれていない。この場合、システム制御部101は、動きベクトル1403、1404、予測ベクトル1405、および動き差分領域予測結果1407の算出を行わない。そして、システム制御部101は、差分情報1414における領域1610に対応する領域を主要被写体置き換え領域1408として抽出する。このように、領域1610よりも外の動きに対しては、被写体の動き予測を行う必要を無くすことができるため、演算処理負荷を軽減することができる。   The system control unit 101 determines whether the difference area 1401 between the non-flash image for screen display 1301 and 1302 and the difference area 1402 between the non-flash image for screen display 1302 and 1303 are included in the area 1610. In the example illustrated in FIGS. 14 and 16, the difference area 1401 between the non-flash image for screen display 1301 and 1302 and the difference area 1402 between the non-flash image for screen display 1302 and 1303 are not included in the area 1610. In this case, the system control unit 101 does not calculate the motion vectors 1403 and 1404, the prediction vector 1405, and the motion difference region prediction result 1407. Then, the system control unit 101 extracts an area corresponding to the area 1610 in the difference information 1414 as a main subject replacement area 1408. As described above, it is possible to eliminate the need to perform the motion prediction of the subject with respect to the motion outside the area 1610, so that the calculation processing load can be reduced.

一方、画面表示用非フラッシュ画像間の差分領域が領域1610に含まれている場合、システム制御部101は、当該差分領域について、第2の実施形態で説明したようにして、動きベクトル、予測ベクトル、および動き差分領域予測結果の算出を行う。そして、システム制御部101は、第1および第2の実施形態で説明したように、動き差分領域予測結果に基づいて、領域1610における動き領域を特定し、領域1610から動き領域を除く領域を主要被写体置き換え領域1408として抽出する。   On the other hand, when the difference area between the non-flash images for screen display is included in the area 1610, the system control unit 101 causes the motion vector and the prediction vector to be the difference area as described in the second embodiment. , And calculation of the motion difference area prediction result. Then, as described in the first and second embodiments, the system control unit 101 identifies the motion area in the area 1610 based on the motion difference area prediction result, and mainly determines the area excluding the motion area from the area 1610. A subject replacement area 1408 is extracted.

以上の処理によれば、動きベクトルを算出する画像領域が狭くなるため、演算処理負荷を軽減することができる。また更に、フラッシュ画像の適正発光距離外の領域を合成することを防ぐことができ、ストロボ光の有効領域に絞ってフラッシュ画像を置き換えることができる。   According to the above-described processing, the image processing area for calculating the motion vector is narrowed, so that the calculation processing load can be reduced. Furthermore, it is possible to prevent the area outside the proper light emitting distance of the flash image from being synthesized, and the flash image can be replaced by focusing on the effective area of the strobe light.

また、奥行き情報1602ではなく、画像の位置情報としてストロボ光の発光中心位置からの距離が近い領域だけを、フラッシュ画像と非フラッシュ画像の比較処理領域として、フラッシュ画像を合成する領域に設定しても良い。これは、ストロボ光の発光中心位置から離れるほど目立ちにくい領域になるため、フラッシュ画像に置き換える領域を限定し、処理負荷をより軽減することができる。
尚、本実施形態では、第2の実施形態に基づく形態(画面表示用非フラッシュ画像を用いる形態)を例に挙げて説明したが、第1の実施形態に基づく形態(本撮影による非フラッシュ画像を用いる形態)であっても良い。また、本実施形態においても、第1、第2の実施形態で変形例を適用することができる。
Also, not the depth information 1602 but only the area near the distance from the light emission center position of the strobe light as the position information of the image is set as the area where the flash image is synthesized as the comparison processing area of the flash image and the non-flash image. Also good. This becomes an area that becomes less noticeable as it moves away from the flash light emission center position, so the area to be replaced with the flash image can be limited, and the processing load can be further reduced.
In the present embodiment, the form (the form using the non-flash image for screen display) has been described as an example based on the second embodiment, but the form (the non-flash image according to the main photographing) according to the first embodiment In the form of using. Also in the present embodiment, the modification can be applied to the first and second embodiments.

尚、前述した実施形態は、何れも本発明を実施するにあたっての具体化の例を示したものに過ぎず、これらによって本発明の技術的範囲が限定的に解釈されてはならないものである。すなわち、本発明はその技術思想、又はその主要な特徴から逸脱することなく、様々な形で実施することができる。   The embodiments described above are merely examples of implementation for carrying out the present invention, and the technical scope of the present invention should not be interpreted in a limited manner by these. That is, the present invention can be implemented in various forms without departing from the technical concept or the main features thereof.

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

100:デジタルカメラ、101:システム制御部、113:ストロボ   100: digital camera, 101: system control unit, 113: strobe

Claims (19)

ストロボ光が発光された状態で撮像された発光画像と、ストロボ光が発光されていない状態で撮像された非発光画像とを取得する取得手段と、
複数の前記非発光画像の画素情報の変化に基づいて、前記発光画像において動きのある被写体の領域を検出する検出手段と、を有することを特徴とする画像処理装置。
An acquisition unit configured to acquire a light emission image captured in a state in which the strobe light is emitted and a non-emission image captured in a state in which the strobe light is not emitted;
An image processing apparatus, comprising: detection means for detecting an area of a subject having a motion in the light emission image based on a change in pixel information of the plurality of non-light emission images.
前記発光画像と、前記非発光画像に基づく画像とを合成する合成手段を更に有することを特徴とする請求項1に記載の画像処理装置。   The image processing apparatus according to claim 1, further comprising a combination unit configured to combine the light emission image and an image based on the non-light emission image. 前記発光画像と前記複数の非発光画像とを合成した画像を、前記非発光画像に基づく画像として生成する生成手段を更に有することを特徴とする請求項2に記載の画像処理装置。   The image processing apparatus according to claim 2, further comprising a generation unit configured to generate an image obtained by combining the light emission image and the plurality of non-light emission images as an image based on the non-light emission image. 前記生成手段は、前記発光画像および前記複数の発光画像のうち基準となる画像と、前記発光画像および前記複数の発光画像のうち前記基準となる画像と異なる画像とを合成し、合成した画像と、前記基準となる画像と異なる画像のうち合成していない画像とを合成することを、前記発光画像と前記複数の発光画像とを合成するまで繰り返し行うことを特徴とする請求項3に記載の画像処理装置。   The generation means combines an image serving as a reference among the light emission image and the plurality of light emission images, and an image obtained by combining the light emission image and an image different from the image serving as the reference among the plurality of light emission images The method according to claim 3, wherein combining the reference image and an image not synthesized among the different images is repeated until the light emission image and the plurality of light emission images are combined. Image processing device. 前記生成手段は、前記基準となる画像の画素情報と、前記基準となる画像と異なる画像の画素情報との差分に応じて、既に合成されている画像と、当該基準となる画像と異なる画像とを合成する割合を決定することを特徴とする請求項4に記載の画像処理装置。   The generation means is configured to generate an image which has already been synthesized according to a difference between pixel information of the reference image and pixel information of an image different from the reference image, and an image different from the reference image. The image processing apparatus according to claim 4, wherein a ratio of combining is determined. 前記検出手段は、前記発光画像の画素情報と前記複数の非発光画像のうちの1つの前記非発光画像の画素情報との差分を示す画像である第1の差分画像を導出することと、前記複数の非発光画像のうちの2つの非発光画像の画素情報の差分を示す画像である第2の差分画像を少なくとも1つ導出することと、前記第2の差分画像に基づいて、前記第1の差分画像から、動きのある被写体の領域を検出することとを少なくとも行うことを特徴とする請求項1〜5の何れか1項に記載の画像処理装置。   The detection means derives a first difference image which is an image showing a difference between pixel information of the light emission image and pixel information of the non-light emission image of one of the plurality of non-light emission images; Deriving at least one second difference image, which is an image indicating a difference between pixel information of two non-emission images among the plurality of non-emission images, and, based on the second difference image, The image processing apparatus according to any one of claims 1 to 5, wherein at least detecting an area of a subject having a motion is performed from the difference image of. 前記発光画像の背景の領域の明るさが前記非発光画像の明るさに近づくように前記発光画像の明るさを調整する調整手段を更に有し、
前記検出手段は、前記調整手段により明るさが調整された前記発光画像の画素情報と前記複数の非発光画像のうちの1つの前記非発光画像の画素情報との差分を示す画像を前記第1の差分画像として導出することを特徴とする請求項6に記載の画像処理装置。
The light emission image further includes an adjustment unit that adjusts the brightness of the light emission image so that the brightness of the region of the background of the light emission image approaches the brightness of the non-light emission image.
The detection means is an image showing the difference between the pixel information of the light emission image whose brightness has been adjusted by the adjustment means and the pixel information of the non-light emission image of one of the plurality of non-light emission images. 7. The image processing apparatus according to claim 6, wherein the image processing apparatus is derived as a difference image of.
前記検出手段は、2つの前記非発光画像の画素情報の差分に基づいて当該2つの前記非発光画像における被写体の動きを示す動きベクトルを導出し、導出した動きベクトルに基づいて、前記発光画像において動きのある被写体の領域を検出することを特徴とする請求項1〜7の何れか1項に記載の画像処理装置。   The detection means derives a motion vector indicating a motion of an object in the two non-emission images based on a difference between pixel information of the two non-emission images, and the emission image is generated in the emission image based on the derived motion vector The image processing apparatus according to any one of claims 1 to 7, wherein an area of a moving subject is detected. 前記検出手段は、前記2つの非発光画像の領域であって、当該2つの非発光画像の画素情報に閾値を上回る差分がある領域の大きさに応じて、当該2つの非発光画像における被写体の動きを示す動きベクトルを検出する範囲を変更することを特徴とする請求項8に記載の画像処理装置。   The detection means is an area of the two non-emission images, and the subject in the two non-emission images according to the size of the area where the pixel information of the two non-emission images has a difference exceeding the threshold. The image processing apparatus according to claim 8, wherein a range in which a motion vector indicating a motion is detected is changed. 前記検出手段は、前記動きベクトルに基づいて、前記発光画像と前記複数の非発光画像のうちの1つの前記非発光画像との間における被写体の動きを予測する予測ベクトルを導出し、当該予測ベクトルに基づいて、前記発光画像において動きのある被写体の領域を検出することを特徴とする請求項8または9に記載の画像処理装置。   The detection means derives, based on the motion vector, a prediction vector for predicting the movement of the subject between the light emission image and the non-light emission image of one of the plurality of non-light emission images, and the prediction vector The image processing apparatus according to claim 8, wherein an area of a subject having a motion is detected in the light emission image based on the image. 前記検出手段は、前記発光画像の画素情報と前記複数の非発光画像のうちの1つの前記非発光画像の画素情報との差分を示す第1の差分画像と、前記予測ベクトルとに基づいて、前記発光画像において動きのある被写体の領域を検出することを特徴とする請求項10に記載の画像処理装置。   The detection means is based on a first difference image indicating a difference between pixel information of the light emission image and pixel information of the non-light emission image of one of the plurality of non-light emission images, and the prediction vector. 11. The image processing apparatus according to claim 10, wherein an area of a subject having a motion in the light emission image is detected. 前記複数の非発光画像の数は、3以上であることを特徴とする請求項1〜11の何れか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 11, wherein the number of the plurality of non-light emitting images is three or more. 前記複数の非発光画像の位置を合わせる位置合わせ手段を更に有することを特徴とする請求項1〜12の何れか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 12, further comprising: alignment means for aligning the positions of the plurality of non-emission images. 前記非発光画像は、画面に表示するための画像であり、
前記発光画像は、撮影指示に基づいて本撮影された画像であることを特徴とする請求項1〜13の何れか1項に記載の画像処理装置。
The non-emission image is an image to be displayed on a screen,
The image processing apparatus according to any one of claims 1 to 13, wherein the light emission image is an image that is actually photographed based on a photographing instruction.
前記非発光画像と前記発光画像は、撮影指示に基づいて本撮影された画像であることを特徴とする請求項1〜12の何れか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 12, wherein the non-light emitting image and the light emitting image are images that have been captured based on a shooting instruction. 前記検出手段は、撮像装置からの前記ストロボ光の発光距離を示す情報と、前記非発光画像における被写体の撮像装置からの距離を示す情報とに基づいて、前記発光画像において動きのある被写体の領域を検出する範囲を決定することを特徴とする請求項1〜15の何れか1項に記載の画像処理装置。   The detection means is an area of a subject having a motion in the light emission image based on information indicating a light emission distance of the strobe light from the imaging device and information indicating a distance from the imaging device of the subject in the non-light emission image. The image processing apparatus according to any one of claims 1 to 15, wherein a range in which to detect is determined. 前記画素情報は、明るさまたは色差を示す情報であることを特徴とする請求項1〜16の何れか1項に記載の画像処理装置。   The image processing apparatus according to any one of claims 1 to 16, wherein the pixel information is information indicating brightness or a color difference. ストロボ光が発光された状態で撮像された発光画像と、ストロボ光が発光されていない状態で撮像された非発光画像とを取得する取得工程と、
複数の前記非発光画像の画素情報の変化に基づいて、前記発光画像において動きのある被写体の領域を検出する検出工程と、を有することを特徴とする画像処理方法。
Acquiring an emission image captured in a state in which the strobe light is emitted and a non-emission image captured in a state in which the strobe light is not emitted;
A detection step of detecting an area of a subject having a motion in the light emission image based on a change in pixel information of the plurality of non-light emission images.
請求項1〜17の何れか1項に記載の画像処理装置の各手段としてコンピュータを機能させるためのプログラム。   The program for functioning a computer as each means of the image processing apparatus in any one of Claims 1-17.
JP2017223680A 2017-11-21 2017-11-21 Image processing equipment, image processing methods, and programs Active JP6995582B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017223680A JP6995582B2 (en) 2017-11-21 2017-11-21 Image processing equipment, image processing methods, and programs

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017223680A JP6995582B2 (en) 2017-11-21 2017-11-21 Image processing equipment, image processing methods, and programs

Publications (2)

Publication Number Publication Date
JP2019096995A true JP2019096995A (en) 2019-06-20
JP6995582B2 JP6995582B2 (en) 2022-01-14

Family

ID=66972140

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017223680A Active JP6995582B2 (en) 2017-11-21 2017-11-21 Image processing equipment, image processing methods, and programs

Country Status (1)

Country Link
JP (1) JP6995582B2 (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017201455A (en) * 2016-05-02 2017-11-09 株式会社モルフォ Image synthesizer, image synthesis method, image synthesis program and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017201455A (en) * 2016-05-02 2017-11-09 株式会社モルフォ Image synthesizer, image synthesis method, image synthesis program and storage medium

Also Published As

Publication number Publication date
JP6995582B2 (en) 2022-01-14

Similar Documents

Publication Publication Date Title
US8947557B2 (en) Photographing apparatus and method for dynamic range adjustment and stereography
KR101605419B1 (en) Photographing apparatus and method of photographing
JP4923005B2 (en) Digital still camera and control method thereof
US20150003676A1 (en) Image processing apparatus for performing object recognition focusing on object motion, and image processing method therefor
JP2014044345A (en) Imaging apparatus
JP6518452B2 (en) Imaging apparatus and imaging method
JP6391304B2 (en) Imaging apparatus, control method, and program
JP2017129828A (en) Imaging device and imaging method
TWI477887B (en) Image processing device, image processing method and recording medium
US8040380B2 (en) Image-taking apparatus
JP2020017807A (en) Image processing apparatus, image processing method, and imaging apparatus
JP6995582B2 (en) Image processing equipment, image processing methods, and programs
JP6210836B2 (en) IMAGING DEVICE, IMAGING CONTROL DEVICE, ITS CONTROL METHOD, AND PROGRAM
JP4888829B2 (en) Movie processing device, movie shooting device, and movie shooting program
JP7134601B2 (en) Image processing device, image processing method, imaging device, and imaging device control method
JP5962974B2 (en) Imaging apparatus, imaging method, and program
JP5030883B2 (en) Digital still camera and control method thereof
JP2017041857A (en) Image processing system, control method of the same, program, and imaging apparatus
JP2009139423A (en) Imaging apparatus and subject distance calculating method
JP6223502B2 (en) Image processing apparatus, image processing method, program, and storage medium storing the same
JP2015232620A (en) Imaging device, control method and program
JP6087617B2 (en) Imaging apparatus and control method thereof
JP2005064749A (en) Camera
JP2018107614A (en) Moving image reproducer, imaging apparatus, moving image reproducing method, and program
JP2003319235A (en) Photographing device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200909

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210713

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210907

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20211102

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: 20211116

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20211215

R151 Written notification of patent or utility model registration

Ref document number: 6995582

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151