JP2014220717A - Image processing apparatus and method - Google Patents

Image processing apparatus and method Download PDF

Info

Publication number
JP2014220717A
JP2014220717A JP2013099718A JP2013099718A JP2014220717A JP 2014220717 A JP2014220717 A JP 2014220717A JP 2013099718 A JP2013099718 A JP 2013099718A JP 2013099718 A JP2013099718 A JP 2013099718A JP 2014220717 A JP2014220717 A JP 2014220717A
Authority
JP
Japan
Prior art keywords
image
main subject
region
area
pixel value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2013099718A
Other languages
Japanese (ja)
Inventor
貴幸 原
Takayuki Hara
貴幸 原
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 JP2013099718A priority Critical patent/JP2014220717A/en
Publication of JP2014220717A publication Critical patent/JP2014220717A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformation in the plane of the image

Abstract

PROBLEM TO BE SOLVED: To apply high-dynamic combination on plural images photographed with different exposures, without giving discomfort even if there is an occlusion region.SOLUTION: The image processing apparatus comprises: input means that receives a first image photographed with exposure adjusted for a main subject and a second image photographed with exposure different from the exposure for the first image; detecting means that detects a non-common region representing different subjects in the first and second images; and combining means that combines the first and second images. The combining means uses a pixel value of the first image for a region of the main subject in a common region which is a region excluding the non-common region, uses a pixel value of the second image for a region which is not the main subject in the first image, uses a pixel value of the first image for the region of the main subject in the first image, and uses a pixel value obtained when the brightness of the first image is matched to the brightness of the second image for a region which is not the main subject in the first image.

Description

本発明は、画像処理装置及び方法に関し、更に詳しくは、異なる露出で撮影された複数枚の画像を合成して、ダイナミックレンジを拡大する画像処理装置及び方法に関する。   The present invention relates to an image processing apparatus and method, and more particularly, to an image processing apparatus and method for expanding a dynamic range by combining a plurality of images taken at different exposures.

露出の異なる複数枚の撮影画像の階調を補正して合成することにより、ダイナミックレンジの広い画像を得るハイダイナミックレンジ合成(HDR)が例えば特許文献1に提案されている。HDRでは、複数の画像間で、画像内の被写体像を位置合わせしてから合成する。   For example, Patent Document 1 proposes high dynamic range synthesis (HDR) that obtains an image with a wide dynamic range by correcting and synthesizing gradations of a plurality of captured images with different exposures. In HDR, a subject image in an image is aligned between a plurality of images and then combined.

特開2012−19337号公報JP 2012-19337 A

しかしながら、被写体の変形や動き、撮影カメラの手ブレ等により、撮影した複数の画像のうち一部の画像にのみ結像し、残りの画像には結像していない領域(以後、オクルージョン領域と記載)ができる場合がある。一例として、図2(a)に示すような第1の画像300と、第2の画像301とを合成する場合に、位置合わせして重ねたイメージを図2(b)に示す。この例では、第1の画像300の主要被写体である人物像310が、第2の画像301を撮影するまでの間に動いてしまい、第2の画像の人物像311のように、人物像310よりも大きくなってしまっている。この影響により、第1の画像と第2の画像とで異なる被写体を写した非共通領域であるオクルージョン領域が発生する。   However, due to deformation or movement of the subject, camera shake, etc., an image is formed only on some of the captured images and is not formed on the remaining images (hereinafter referred to as an occlusion region). Description) may be possible. As an example, FIG. 2B shows an image that is aligned and overlapped when the first image 300 as shown in FIG. 2A and the second image 301 are synthesized. In this example, the person image 310 that is the main subject of the first image 300 moves until the second image 301 is photographed, and a person image 310 like the person image 311 of the second image 301. It has become bigger than. Due to this influence, an occlusion area that is a non-common area in which different subjects are captured in the first image and the second image is generated.

オクルージョン領域が存在するとうまく合成できないという問題があるが、特許文献1では動きベクトルの信頼度を用いることにより、オクルージョン領域の存在を検知し、複数の画像間の合成比率を変えることによって対処している。   Although there is a problem that if the occlusion area exists, the composition cannot be performed well. However, in Patent Document 1, the existence of the occlusion area is detected by using the reliability of the motion vector, and the composition ratio between a plurality of images is changed. Yes.

しかしながら、オクルージョン領域を有する画像において、主要被写体と非主要被写体との距離の影響などにより、主要被写体あるいは非主要被写体を基準に位置合わせすると、もう一方(非主要被写体あるいは主要被写体)に位置ズレが残る。そのため、単純に合成すると主要被写体の輪郭部分が二重になってしまうという問題がある。   However, in an image having an occlusion area, if the main subject or the non-main subject is aligned based on the influence of the distance between the main subject and the non-main subject, etc., the misalignment occurs on the other (non-main subject or main subject). Remains. Therefore, there is a problem that the outline of the main subject is doubled if simply combined.

また、オクルージョン領域の像が飽和(白とび)または黒潰れしている場合には、合成比率を変えても白とびや黒潰れが現れてしまい、出力画像としては違和感のあるものとなるという問題があった。   In addition, when the image of the occlusion area is saturated (overexposed) or blackout, even if the composition ratio is changed, overexposure or underexposure appears, and the output image is uncomfortable. was there.

本発明は上記問題点を鑑みてなされたものであり、オクルージョン領域があっても違和感なく、異なる露出で撮影された複数枚の画像をハイダイナミックレンジ合成できるようにすることを目的とする。   The present invention has been made in view of the above problems, and an object of the present invention is to enable high dynamic range composition of a plurality of images photographed at different exposures without feeling uncomfortable even if there is an occlusion area.

上記目的を達成するために、本発明の画像処理装置は、主要被写体に露出を合わせて撮影した第1の画像と、前記第1の画像とは異なる露出で撮影した第2の画像を入力する入力手段と、前記第1の画像と前記第2の画像において、互いに異なる被写体を表す非共通領域を検出する検出手段と、前記第1の画像と前記第2の画像を合成する合成手段とを有し、前記合成手段は、前記非共通領域を除く領域である共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、前記共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第2の画像の画素値を用い、前記非共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、前記非共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第1の画像の輝度を前記第2の画像の輝度に合わせた画素値を用いて、前記第1の画像と前記第2の画像を合成する第1の合成処理を行うことを特徴とする。   In order to achieve the above object, an image processing apparatus according to the present invention inputs a first image taken with exposure of a main subject and a second image taken with an exposure different from the first image. Input means; detection means for detecting non-common areas representing different subjects in the first image and the second image; and synthesis means for synthesizing the first image and the second image. And the compositing means uses a pixel value of the first image in the first image in the common image that is a region excluding the non-common region, and uses the pixel value of the first image in the common region. The region of the first image that is not the main subject uses the pixel value of the second image, and of the non-common region, the region of the main subject of the first image is the region of the first image. Using the pixel value, the first of the non-common areas. A region that is not the main subject in the image is a first that synthesizes the first image and the second image using a pixel value that matches the luminance of the first image with the luminance of the second image. A synthesis process is performed.

オクルージョン領域があっても違和感なく、異なる露出で撮影された複数枚の画像をハイダイナミックレンジ合成することができる。   Even if there is an occlusion area, it is possible to synthesize a plurality of images taken at different exposures with a high dynamic range without feeling uncomfortable.

本発明の第1及び第2の実施形態における画像処理装置の概略構成を示すブロック図。FIG. 2 is a block diagram showing a schematic configuration of an image processing apparatus according to first and second embodiments of the present invention. オクルージョン領域の説明図Illustration of occlusion area オクルージョン領域の検出方法の説明図。Explanatory drawing of the detection method of an occlusion area | region. 第1の実施形態におけるオクルージョン領域の補正例を示す説明図。Explanatory drawing which shows the example of correction | amendment of the occlusion area | region in 1st Embodiment. 第1の実施形態における別のオクルージョン領域の補正例を示す説明図。Explanatory drawing which shows the example of correction | amendment of another occlusion area | region in 1st Embodiment. オクルージョン領域の別の検出方法の説明図。Explanatory drawing of another detection method of an occlusion area | region. 第2の実施形態における特徴点の配置図。FIG. 10 is a layout diagram of feature points in the second embodiment. 特徴点以外の点の移動の説明図。Explanatory drawing of the movement of points other than a feature point. 重み係数Wの説明図。Explanatory drawing of the weighting coefficient W. FIG. 変形に伴う画像上の任意の点の移動の説明図。Explanatory drawing of the movement of the arbitrary points on the image accompanying a deformation | transformation. 第3の実施形態における画像処理装置の概略構成を示すブロック図。The block diagram which shows schematic structure of the image processing apparatus in 3rd Embodiment.

以下、添付図面を参照して本発明を実施するための最良の形態を詳細に説明する。   The best mode for carrying out the present invention will be described below in detail with reference to the accompanying drawings.

<第1の実施形態>
図1は、第1の実施形態における画像処理装置の概略構成を示すブロック図である。図1に示す画像処理装置において、第1の入力端子100から第1の画像が、また、第2の入力端子102から第2の画像が入力し、位置合わせ部104に入力される。
<First Embodiment>
FIG. 1 is a block diagram illustrating a schematic configuration of an image processing apparatus according to the first embodiment. In the image processing apparatus illustrated in FIG. 1, the first image is input from the first input terminal 100 and the second image is input from the second input terminal 102 and is input to the alignment unit 104.

本第1の実施形態において、第1の画像は、主要被写体が適正な露光で撮影されるように露出制御して撮影した画像である。例えば、ポートレート撮影モードの場合、撮影対象となる人物を主要被写体として、顔検出等を用いて該人物にあわせるようにAE(Automatic Exposure)制御を行う。この時、主要被写体以外の領域(以下、「非主要被写体」と呼ぶ。)は、白とびや黒潰れする場合がある。   In the first embodiment, the first image is an image shot with exposure control so that the main subject is shot with appropriate exposure. For example, in the portrait photography mode, AE (Automatic Exposure) control is performed using a person to be photographed as a main subject and matching the person using face detection or the like. At this time, an area other than the main subject (hereinafter referred to as “non-main subject”) may be overexposed or blackout.

一方、第2の画像は、非主要被写体が適正な露光で撮影されるように露出制御して撮影した画像である。第1の画像の非主要被写体領域が白とびしているようなケースでは、第2の画像の主要被写体領域は暗く写っており、黒潰れする場合がある。逆に、第1の画像の非主要被写体領域が黒潰れしているようなケースでは、第2の画像の主要被写体領域は明るく写っており、白とびする場合がある。   On the other hand, the second image is an image shot with exposure control so that the non-main subject is shot with appropriate exposure. In a case where the non-main subject area of the first image is overexposed, the main subject area of the second image appears dark and may be blackened. On the other hand, in the case where the non-main subject area of the first image is blacked out, the main subject area of the second image appears bright and may be overexposed.

位置合わせ部104は、このように露出が異なる2枚の画像を入力して、両画像に結像している同一の被写体が重なるように位置合わせを行う。位置合わせは一般的な技術であり、例えば特許文献1にも記載があるので、ここでは説明を省略する。位置合わせ時には、第1の画像と第2の画像のどちらか一方だけを動かしても良いし、両方動かしても構わない。   The alignment unit 104 inputs two images with different exposures as described above, and performs alignment so that the same subject formed on both images overlap. The alignment is a common technique, and is described in, for example, Patent Document 1 and therefore will not be described here. At the time of alignment, only one of the first image and the second image may be moved, or both may be moved.

第1の切り出し部101は、位置合わせ部104によって第2の画像と位置合わせされた第1の画像を入力し、入力した第1の画像から主要被写体領域を抽出して主要被写体領域を示す第1の切り出し情報を出力する。また、第2の切り出し部103は、位置合わせ部104によって第1の画像と位置合わせされた第2の画像を入力し、入力した第2の画像から非主要被写体領域を抽出して非主要被写体領域を示す第2の切り出し情報を出力する。   The first cutout unit 101 inputs the first image aligned with the second image by the alignment unit 104, extracts the main subject region from the input first image, and indicates the main subject region. 1 cutout information is output. In addition, the second cutout unit 103 inputs the second image aligned with the first image by the alignment unit 104, extracts a non-main subject area from the input second image, and extracts the non-main subject. Second cutout information indicating the area is output.

オクルージョン領域検出部105は、第1の切り出し情報と第2の切り出し情報とに基づいて、オクルージョン領域(非共通領域)を求める。そして、補正部106において、検出されたオクルージョン領域の画素値に対してゲイン補正により補正を掛ける。合成部107では、第1の画像と第2の画像とを合成することによって、合成画像を生成する。なお、ここで行われる補正処理及び合成処理に関しては、詳細に後述する。   The occlusion area detection unit 105 obtains an occlusion area (non-common area) based on the first cutout information and the second cutout information. Then, the correction unit 106 corrects the detected pixel value of the occlusion area by gain correction. The synthesizing unit 107 generates a synthesized image by synthesizing the first image and the second image. The correction process and the synthesis process performed here will be described in detail later.

次に、本第1の実施形態においてオクルージョン領域を求める方法について説明する。第1の切り出し部101は、第1の切り出し情報として第1の画像から主要被写体領域の輪郭情報(第1の輪郭情報)を抽出する。また、第2の切り出し部103は、第2の切り出し情報として第2の画像から非主要被写体領域の輪郭情報(第2の輪郭情報)を抽出する。オクルージョン領域検出部105は、抽出した主要被写体領域の輪郭情報と非主要被写体領域の輪郭情報との位置のずれから、オクルージョン領域を検出する。   Next, a method for obtaining an occlusion area in the first embodiment will be described. The first cutout unit 101 extracts outline information (first outline information) of the main subject region from the first image as the first cutout information. The second cutout unit 103 extracts contour information (second contour information) of the non-main subject region from the second image as the second cutout information. The occlusion area detection unit 105 detects an occlusion area from the positional deviation between the extracted outline information of the main subject area and the outline information of the non-main subject area.

ここで、図3を参照して、第1の画像と第2の画像が図2に示す画像である場合を例にとって説明する。図3(a)は、第1の切り出し部101により図2(a)に示す第1の画像300から抽出した主要被写体領域の輪郭情報400と、第2の切り出し部103により第2の画像301から抽出した非主要被写体領域の輪郭情報401とを示す図である。   Here, with reference to FIG. 3, a case where the first image and the second image are the images shown in FIG. 2 will be described as an example. 3A shows the outline information 400 of the main subject region extracted from the first image 300 shown in FIG. 2A by the first cutout unit 101, and the second image 301 by the second cutout unit 103. FIG. FIG. 6 is a diagram showing contour information 401 of a non-main subject region extracted from

図3(b)は、主要被写体領域の輪郭情報400と、非主要被写体領域の輪郭情報401とを重ねあわせた状態を示す。オクルージョン領域検出部105は、主要被写体領域の輪郭情報400上の特徴点403と、その特徴点403に対応する非主要被写体領域の輪郭情報401上の特徴点とを求め、対応する特徴点403の位置ずれ分をオクルージョン領域とする。複数の特徴点を求め、各特徴点間を補間することによって、オクルージョン領域の輪郭情報を形成する。   FIG. 3B shows a state in which the contour information 400 of the main subject region and the contour information 401 of the non-main subject region are overlapped. The occlusion area detection unit 105 obtains a feature point 403 on the outline information 400 of the main subject area and a feature point on the outline information 401 of the non-main subject area corresponding to the feature point 403, and sets the corresponding feature point 403. The misalignment area is taken as the occlusion area. The contour information of the occlusion area is formed by obtaining a plurality of feature points and interpolating between the feature points.

補正部106は、上述したようにしてオクルージョン領域検出部105によって検出されたオクルージョン領域の輪郭情報を基に、ゲイン補正によってオクルージョン領域を補正する。   The correction unit 106 corrects the occlusion region by gain correction based on the contour information of the occlusion region detected by the occlusion region detection unit 105 as described above.

オクルージョン領域の内、第1の画像上で主要被写体領域である部分については、出力画像のオクルージョン領域の画素値として位置合わせされた第1の画像の画素値を出力する。   For the portion of the occlusion area which is the main subject area on the first image, the pixel value of the first image aligned as the pixel value of the occlusion area of the output image is output.

一方、オクルージョン領域の内、第1の画像上で非主要被写体領域である部分については、出力画像の該オクルージョン領域の画素値として、位置合わせされた第1の画像にゲインを掛けた画素値を出力する。掛けるゲインは、第1の画像の露出を第2の画像の露出へ合わせるように、第1の画像の露出と、第2の画像の露出との露出段差により求めたゲインとする。例えば、第1の画像と第2の画像が図2に示す画像の場合、オクルージョン領域の内、領域303には、第1の画像300では背景(人物像310以外)が写り、第2の画像301では人物像310の一部分が写っている。この場合、本第1の実施形態では、図4に示すように、背景画像は、領域303以外(点線の外側)では第2の画像301を利用し、領域303内(点線の内側)では第1の画像301の画素値をゲイン調整して利用する。このように合成処理(第1の合成処理)を行うことで、自然な結果を得ることができる。   On the other hand, for a portion that is a non-main subject area on the first image in the occlusion area, a pixel value obtained by multiplying the aligned first image by a gain is used as the pixel value of the occlusion area of the output image. Output. The gain to be multiplied is a gain obtained from an exposure step between the exposure of the first image and the exposure of the second image so that the exposure of the first image matches the exposure of the second image. For example, if the first image and the second image are the images shown in FIG. 2, the background (other than the person image 310) appears in the first image 300 in the region 303 in the occlusion region, and the second image In 301, a part of the person image 310 is shown. In this case, in the first embodiment, as shown in FIG. 4, the background image uses the second image 301 outside the region 303 (outside the dotted line) and the second image 301 inside the region 303 (inside the dotted line). The pixel value of one image 301 is used after gain adjustment. By performing the synthesis process (first synthesis process) in this way, natural results can be obtained.

また、例えば、図5(a)に示すように、第1の画像600の人物像610が、第2の画像601の人物像611よりも大きい場合も、オクルージョン領域の内、図5(b)に示す第1の画像で背景画像である領域603を同様にして補正する。このようにすることで、図5(c)に示すような自然な画像を得ることができる。   Further, for example, as shown in FIG. 5A, even when the human image 610 of the first image 600 is larger than the human image 611 of the second image 601, FIG. The area 603 which is the background image in the first image shown in FIG. By doing so, a natural image as shown in FIG. 5C can be obtained.

なお、オクルージョン領域の検出には、輪郭情報だけでなく、図6に示すように画素値(例えば輝度)の差分画像を用いても構わない。まず、図6(a)に示すように、第2の画像301に対して、第1の画像撮影時と第2の画像撮影時の露出段差分を埋めるようにゲインを掛ける。例えば、第1の画像300に対して、第2の画像301が1段分暗いのであれば、第2の画像301に1段分明るくするために2倍ゲインを掛ける。そして、同等の輝度レベルになった第1の画像300と、ゲイン補正後の第2の画像320との輝度差分をとることによって(図6(b))、オクルージョン領域321を求める(図6(c))。   For detection of the occlusion area, not only contour information but also a differential image of pixel values (for example, luminance) as shown in FIG. 6 may be used. First, as shown in FIG. 6A, a gain is applied to the second image 301 so as to fill an exposure step between the first image shooting and the second image shooting. For example, if the second image 301 is darker than the first image 300 by one step, a double gain is multiplied to make the second image 301 brighter by one step. Then, by obtaining the luminance difference between the first image 300 having the same luminance level and the second image 320 after gain correction (FIG. 6B), an occlusion region 321 is obtained (FIG. 6 ( c)).

上記のように本第1の実施形態によれば、合成する画像間にオクルージョン領域があっても、比較的シンプルな構成でハイダイナミックレンジ合成を実現することができ、例えば回路化する場合に、小規模な回路で実現することができる。   As described above, according to the first embodiment, even if there is an occlusion region between images to be synthesized, high dynamic range synthesis can be realized with a relatively simple configuration. It can be realized with a small circuit.

<第2の実施形態>
上述した第1の実施形態で説明した方法では、第2の入力画像の代わりに出力する第1の入力画像のオクルージョン領域に白飛びまたは黒潰れがある場合には対応できない。本第2の実施形態では、そのようなケースに対応する方法について説明する。
<Second Embodiment>
The method described in the first embodiment described above cannot cope with a case where the occlusion area of the first input image to be output instead of the second input image has whiteout or blackout. In the second embodiment, a method corresponding to such a case will be described.

本第2の実施形態における補正部106は、オクルージョン領域検出部105によって検出された、オクルージョン領域の輪郭情報を基に、非主要被写体領域を変形・変倍することによってオクルージョン領域を補正する。具体的な実現方法について、以下に説明する。   The correction unit 106 according to the second embodiment corrects the occlusion area by deforming / magnifying the non-main subject area based on the contour information of the occlusion area detected by the occlusion area detection unit 105. A specific implementation method will be described below.

上述した第1の実施形態では、オクルージョン領域を求める際に、図3のように第1の画像の主要被写体領域の輪郭情報400上の特徴点と、第2の画像の非主要被写体領域の輪郭情報401上の特徴点403との対応関係を利用した。本第2の実施形態における後述する変形・変倍による補正では、これらの特徴点を利用する。   In the first embodiment described above, when the occlusion area is obtained, the feature points on the outline information 400 of the main subject area of the first image and the outline of the non-main subject area of the second image as shown in FIG. A correspondence relationship with the feature point 403 on the information 401 is used. In the correction by deformation / magnification described later in the second embodiment, these feature points are used.

更に、これら特徴点に加え、画像の上下左右端にも所定の間隔で特徴点を配置し、これらの移動ベクトルを0とする。例えば、図7の上下左右端の特徴点700のように配置する。これら上下左右端の特徴点700は、後で述べる座標移動量の計算にそのまま使うが、全ての上下左右端の特徴点700の移動ベクトルは0とする。   Further, in addition to these feature points, feature points are also arranged at predetermined intervals on the upper, lower, left and right edges of the image, and these movement vectors are set to zero. For example, the feature points 700 at the top, bottom, left and right ends in FIG. 7 are arranged. These feature points 700 at the upper, lower, left and right ends are used as they are in the calculation of the coordinate movement amount, which will be described later.

第1の画像の各特徴点から第2の画像の対応する特徴点への移動ベクトルを求める。図7に示す例では、第1の画像300上の特徴点403と、第2の画像301上の特徴点702が対応しているが、この場合、移動ベクトル701分、縮小している。また、第1の画像300上の特徴点703と、第2の画像301上の特徴点704とが対応しているが、移動ベクトル705分、縮小している。同様に全ての特徴点の移動ベクトルを求める。なお、求めた移動ベクトル内、最大のベクトルの大きさ(座標移動量)が所定の大きさを超える場合には、変形・変倍による補正を行わない。   A movement vector from each feature point of the first image to a corresponding feature point of the second image is obtained. In the example shown in FIG. 7, the feature point 403 on the first image 300 and the feature point 702 on the second image 301 correspond to each other, but in this case, the feature point 403 is reduced by the movement vector 701. A feature point 703 on the first image 300 and a feature point 704 on the second image 301 correspond to each other, but are reduced by the movement vector 705. Similarly, the movement vectors of all feature points are obtained. Note that, when the magnitude of the maximum vector (coordinate movement amount) in the obtained movement vector exceeds a predetermined magnitude, correction by deformation / magnification is not performed.

図8に示すように、第2の画像上の非主要被写体領域の輪郭情報401における任意の点Pは、出力画像上の点Qへ出力される。この時、点Pから点Qへの座標移動量は次の式(1)にて求められる。   As shown in FIG. 8, an arbitrary point P in the contour information 401 of the non-main subject area on the second image is output to a point Q on the output image. At this time, the coordinate movement amount from the point P to the point Q is obtained by the following equation (1).

式(1)のスカラー係数W(n)は、点Pと特徴点nとのノルム(norm)に応じて、ノルムが小さいほど大きな値になる重みであり、その荷重平均によって移動量が決定される。また、kは全特徴点を表す。ノルムは、例えばユークリッドノルム等を用いて、図9のような重みテーブルを利用する。この変形方法によって、図10に示すように、画像上の任意の点1100が、式(1)による移動ベクトル計算により求められた移動ベクトル1101に従って移動先の点1102へ移動することにより、画像が変形・変倍される。   The scalar coefficient W (n) in equation (1) is a weight that increases as the norm decreases according to the norm between the point P and the feature point n, and the amount of movement is determined by the load average. The K represents all feature points. As the norm, for example, a weight table as shown in FIG. 9 is used using the Euclidean norm or the like. By this deformation method, as shown in FIG. 10, an arbitrary point 1100 on the image moves to the destination point 1102 according to the movement vector 1101 obtained by the movement vector calculation by the equation (1), so that the image becomes Deformed and scaled.

なお、実現にあたっては、写像関係を逆転した点Qから点Pを求める方法でも構わない。各特徴点の移動ベクトルの方向を180度反転し、同様の方法で求めればよい。   In realization, a method of obtaining the point P from the point Q obtained by reversing the mapping relationship may be used. What is necessary is just to obtain | require by the same method, reversing the direction of the movement vector of each feature point 180 degree | times.

そして、第1の画像の主要被写体領域の画素値と、上述したようにして変形変倍処理された第2の画像の非主要被写体領域の画素値とを合成する(第2の合成処理)。   Then, the pixel value of the main subject area of the first image and the pixel value of the non-main subject area of the second image subjected to the deformation scaling process as described above are synthesized (second synthesis process).

上記の通り本第2の実施形態によれば、オクルージョン領域において、白飛びまたは黒潰れしている画素(飽和画素及び黒潰れ画素)が多数含まれていても、ハイダイナミックレンジ合成されたより自然な出力画像を得ることができる。   As described above, according to the second embodiment, even if the occlusion area includes a large number of overexposed or underexposed pixels (saturated pixels and underexposed pixels), it is more natural for high dynamic range synthesis. An output image can be obtained.

<第3の実施形態>
次に、本発明の第3の実施形態について説明する。図11は、第3の実施形態における画像処理装置の構成を示すブロック図である。基本的な構成は図1を参照して説明したもの同様であるが、図1に示す構成とは補正処理選定部206が追加されている点が異なる。
<Third Embodiment>
Next, a third embodiment of the present invention will be described. FIG. 11 is a block diagram illustrating a configuration of an image processing apparatus according to the third embodiment. The basic configuration is the same as that described with reference to FIG. 1, but is different from the configuration shown in FIG. 1 in that a correction processing selection unit 206 is added.

補正処理選定部206は、オクルージョン領域の状態に応じて補正処理を選定する。まず、第1の画像のオクルージョン領域の内、第1の画像上で非主要被写体領域である部分の画素を調べ、白とび画素(飽和画素)及び黒潰れ画素の占める割合が所定の割合を超えている場合は、第2の実施形態で説明した補正処理を選択する。一方、飽和画素及び黒潰れ画素の占める割合が所定の割合を超えていない場合は、第1の実施形態で説明した補正処理を選択する。即ち、飽和画素及び黒潰れ画素の占める割合に応じて、第1の実施形態で説明した補正処理を行って画像を合成する第1の合成処理と、第2の実施形態で説明した補正処理を行って画像を合成する第2の合成処理とを選択的に行う。   The correction process selection unit 206 selects a correction process according to the state of the occlusion area. First, in the occlusion area of the first image, the pixel of the portion that is a non-main subject area on the first image is examined, and the ratio of overexposed pixels (saturated pixels) and blackout pixels exceeds a predetermined ratio If so, the correction processing described in the second embodiment is selected. On the other hand, when the ratio of the saturated pixels and the blackout pixels does not exceed the predetermined ratio, the correction process described in the first embodiment is selected. That is, the first combining process for combining the images by performing the correction process described in the first embodiment and the correction process described in the second embodiment according to the ratio of the saturated pixels and the blackout pixels. And a second combining process for combining the images.

この判定は、画像上に複数存在する個々のオクルージョン領域について独立して判定してもいいし、全体をひとまとめにして判定しても構わない。   This determination may be performed independently for a plurality of individual occlusion areas existing on the image, or may be determined collectively as a whole.

本第3の実施形態によれば、オクルージョン領域において、白飛びまたは黒潰れしている画素の多少に応じて、より自然な出力画像を得ることができる。   According to the third embodiment, a more natural output image can be obtained according to the number of whiteout or blackout pixels in the occlusion area.

<他の実施形態>
また、本発明は、以下の処理を実行することによっても実現される。即ち、上述した実施形態の機能を実現するソフトウェア(プログラム)を、ネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。
<Other embodiments>
The present invention can also be realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various storage media, and a computer (or CPU, MPU, etc.) of the system or apparatus reads the program. It is a process to be executed.

Claims (12)

主要被写体に露出を合わせて撮影した第1の画像と、前記第1の画像とは異なる露出で撮影した第2の画像を入力する入力手段と、
前記第1の画像と前記第2の画像において、互いに異なる被写体を表す非共通領域を検出する検出手段と、
前記第1の画像と前記第2の画像を合成する合成手段とを有し、
前記合成手段は、
前記非共通領域を除く領域である共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、
前記共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第2の画像の画素値を用い、
前記非共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、
前記非共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第1の画像の輝度を前記第2の画像の輝度に合わせた画素値を用いて、
前記第1の画像と前記第2の画像を合成する第1の合成処理を行うことを特徴とする画像処理装置。
An input means for inputting a first image photographed with exposure adjusted to a main subject and a second image photographed with an exposure different from the first image;
Detecting means for detecting non-common areas representing different subjects in the first image and the second image;
Combining means for combining the first image and the second image;
The synthesis means includes
Of the common area that is an area excluding the non-common area, the area of the main subject in the first image uses the pixel value of the first image,
Of the common area, the area that is not the main subject in the first image uses the pixel value of the second image,
Among the non-common areas, the area of the main subject in the first image uses the pixel value of the first image,
Of the non-common area, an area that is not the main subject in the first image uses a pixel value that matches the luminance of the first image with the luminance of the second image,
An image processing apparatus that performs a first combining process for combining the first image and the second image.
前記合成手段は、更に、前記第2の画像における前記主要被写体の特徴点が前記第1の画像における前記主要被写体の特徴点の位置に移動するように、前記第2の画像に対して変形変倍処理を行い、前記第1の画像において前記主要被写体の領域は、前記第1の画像の画素値を用い、前記第1の画像において前記主要被写体ではない領域は、前記変形変倍処理した第2の画像の画素値を用いて、前記第1の画像と前記第2の画像を合成する第2の合成処理と、前記第1の合成処理とを選択的に行い、
前記非共通領域の内、前記第1の画像で前記主要被写体ではない領域に含まれる飽和画素及び黒潰れ画素が、予め決められた割合を越えている場合に前記第2の合成処理を行い、前記予め決められた割合を越えていない場合に前記第1の合成処理を行うように選択する選択手段を更に有することを特徴とする請求項1に記載の画像処理装置。
The synthesizing unit further deforms and changes the second image so that the feature point of the main subject in the second image moves to the position of the feature point of the main subject in the first image. In the first image, the region of the main subject uses the pixel value of the first image, and the region that is not the main subject in the first image undergoes the deformation scaling process. A second combining process for combining the first image and the second image using the pixel values of the second image and the first combining process;
When the saturation pixel and the blackout pixel included in the region that is not the main subject in the first image in the non-common region exceed a predetermined ratio, the second synthesis process is performed, The image processing apparatus according to claim 1, further comprising selection means for selecting to perform the first composition processing when the predetermined ratio is not exceeded.
前記検出手段は、
前記第1の画像から主要被写体の領域の第1の輪郭情報を切り出す第1の切り出し手段と、
前記第2の画像から非主要被写体の領域の第2の輪郭情報を切り出す第2の切り出し手段と、
前記第1の輪郭情報と前記第2の輪郭情報との位置ずれ分の領域を、前記非共通領域として抽出する抽出手段と
を有することを特徴とする請求項1または2に記載の画像処理装置。
The detection means includes
First cutout means for cutting out the first contour information of the area of the main subject from the first image;
Second cutout means for cutting out the second contour information of the area of the non-main subject from the second image;
3. The image processing apparatus according to claim 1, further comprising an extraction unit that extracts a region corresponding to a positional deviation between the first contour information and the second contour information as the non-common region. .
前記検出手段は、前記第2の画像の画素値に、前記第1の画像を撮影したときの露出と、前記第2の画像を撮影したときの露出との露出段差を無くすように求められたゲインを掛けて得られたゲイン補正後の第2の画像と、前記第1の画像との輝度差分を取ることによって、前記非共通領域を検出することを特徴とする請求項1または2に記載の画像処理装置。   The detection means is required to eliminate an exposure step between an exposure when the first image is captured and an exposure when the second image is captured in the pixel value of the second image. The non-common area is detected by taking a luminance difference between the second image after gain correction obtained by multiplying the gain and the first image. Image processing apparatus. 主要被写体に露出を合わせて撮影した第1の画像と、前記主要被写体以外に露出を合わせて撮影した第2の画像を入力する入力手段と、
前記第1の画像と前記第2の画像を合成する合成手段とを有し、
前記合成手段は、前記第2の画像における前記主要被写体の特徴点が前記第1の画像における前記主要被写体の特徴点の位置に移動するように、前記第2の画像の非主要被写体の領域に対して変形変倍処理を行い、前記第1の画像において前記主要被写体の領域は、前記第1の画像の画素値を用い、前記第1の画像において前記主要被写体ではない領域は、前記変形変倍処理した第2の画像の画素値を用いて、前記第1の画像と前記第2の画像を合成することを特徴とする画像処理装置。
Input means for inputting a first image taken with exposure adjusted to the main subject and a second image taken with exposure adjusted other than the main subject;
Combining means for combining the first image and the second image;
The synthesizing unit is configured to apply the feature point of the main subject in the second image to the non-main subject region of the second image so that the feature point of the main subject moves to the position of the feature point of the main subject in the first image. A deformation scaling process is performed on the first image, and the region of the main subject in the first image uses the pixel value of the first image, and the region that is not the main subject in the first image An image processing apparatus that combines the first image and the second image using pixel values of the second image that has been subjected to the double processing.
前記変形変倍処理に伴う前記第2の画像の画素の座標移動量が予め決められた大きさを越える場合に、前記合成手段は合成を行わないことを特徴とする請求項5に記載の画像処理装置。   6. The image according to claim 5, wherein when the coordinate movement amount of the pixel of the second image accompanying the deformation scaling process exceeds a predetermined size, the synthesizing unit does not perform synthesis. Processing equipment. 前記第1の画像と、前記第2の画像の位置合わせを行う位置合わせ手段を更に有し、
前記検出手段は、前記位置合わせ手段により位置合わせされた前記第1の画像と前記第2の画像を用いて非共通領域を検出し、
前記合成手段は、前記位置合わせ手段により位置合わせされた前記第1の画像と前記第2の画像を合成する
ことを特徴とする請求項1乃至6のいずれか1項に記載の画像処理装置。
An alignment unit for aligning the first image and the second image;
The detection means detects a non-common area using the first image and the second image aligned by the alignment means,
The image processing apparatus according to claim 1, wherein the synthesizing unit synthesizes the first image and the second image aligned by the alignment unit.
入力手段が、主要被写体に露出を合わせて撮影した第1の画像と、前記第1の画像とは異なる露出で撮影した第2の画像を入力する入力工程と、
検出手段が、前記第1の画像と前記第2の画像において、互いに異なる被写体を表す非共通領域を検出する検出工程と、
合成手段が、前記第1の画像と前記第2の画像を合成する合成工程とを有し、
前記合成工程では、
前記非共通領域を除く領域である共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、
前記共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第2の画像の画素値を用い、
前記非共通領域のうち、前記第1の画像で前記主要被写体の領域は前記第1の画像の画素値を用い、
前記非共通領域のうち、前記第1の画像で前記主要被写体ではない領域は前記第1の画像の輝度を前記第2の画像の輝度に合わせた画素値を用いて、
前記第1の画像と前記第2の画像を合成する第1の合成処理を行うことを特徴とする画像処理方法。
An input step in which the input means inputs a first image shot with a main subject adjusted for exposure, and a second image shot with an exposure different from the first image;
A detecting step for detecting a non-common area representing different subjects in the first image and the second image;
A synthesis means comprising a synthesis step of synthesizing the first image and the second image;
In the synthesis step,
Of the common area that is an area excluding the non-common area, the area of the main subject in the first image uses the pixel value of the first image,
Of the common area, the area that is not the main subject in the first image uses the pixel value of the second image,
Among the non-common areas, the area of the main subject in the first image uses the pixel value of the first image,
Of the non-common area, an area that is not the main subject in the first image uses a pixel value that matches the luminance of the first image with the luminance of the second image,
An image processing method comprising performing a first combining process for combining the first image and the second image.
前記合成工程では、更に、前記第2の画像における前記主要被写体の特徴点が前記第1の画像における前記主要被写体の特徴点の位置に移動するように、前記第2の画像に対して変形変倍処理を行い、前記第1の画像において前記主要被写体の領域は、前記第1の画像の画素値を用い、前記第1の画像において前記主要被写体ではない領域は、前記変形変倍処理した第2の画像の画素値を用いて、前記第1の画像と前記第2の画像を合成する第2の合成処理と、前記第1の合成処理とを選択的に行い、
選択手段が、前記非共通領域の内、前記第1の画像で前記主要被写体ではない領域に含まれる飽和画素及び黒潰れ画素が、予め決められた割合を越えている場合に前記第2の合成処理を行い、前記予め決められた割合を越えていない場合に前記第1の合成処理を行うように選択する選択工程を更に有することを特徴とする請求項8に記載の画像処理方法。
In the synthesizing step, the second image is further deformed and changed so that the feature point of the main subject in the second image moves to the position of the feature point of the main subject in the first image. In the first image, the region of the main subject uses the pixel value of the first image, and the region that is not the main subject in the first image undergoes the deformation scaling process. A second combining process for combining the first image and the second image using the pixel values of the second image and the first combining process;
When the selection unit includes a saturation pixel and a blackout pixel included in a region that is not the main subject in the first image in the non-common region, the second synthesis is performed. 9. The image processing method according to claim 8, further comprising a selection step of performing processing and selecting to perform the first synthesis processing when the predetermined ratio is not exceeded.
入力手段が、主要被写体に露出を合わせて撮影した第1の画像と、前記主要被写体以外に露出を合わせて撮影した第2の画像を入力する入力工程と、
合成手段が、前記第1の画像と前記第2の画像を合成する合成工程とを有し、
前記合成工程では、前記第2の画像における前記主要被写体の特徴点が前記第1の画像における前記主要被写体の特徴点の位置に移動するように、前記第2の画像の非主要被写体の領域に対して変形変倍処理を行い、前記第1の画像において前記主要被写体の領域は、前記第1の画像の画素値を用い、前記第1の画像において前記主要被写体ではない領域は、前記変形変倍処理した第2の画像の画素値を用いて、前記第1の画像と前記第2の画像を合成することを特徴とする画像処理方法。
An input step in which the input means inputs a first image taken with exposure adjusted to the main subject and a second image taken with exposure adjusted to other than the main subject;
A synthesis means comprising a synthesis step of synthesizing the first image and the second image;
In the synthesizing step, the feature point of the main subject in the second image is moved to the position of the feature point of the main subject in the first image. A deformation scaling process is performed on the first image, and the region of the main subject in the first image uses the pixel value of the first image, and the region that is not the main subject in the first image An image processing method comprising combining the first image and the second image using pixel values of the second image that has been doubled.
コンピュータに、請求項8乃至10のいずれか1項に記載の画像処理方法の各工程を実行させるためのプログラム。   A program for causing a computer to execute each step of the image processing method according to any one of claims 8 to 10. 請求項11に記載のプログラムを格納したコンピュータが読み取り可能な記憶媒体。   A computer-readable storage medium storing the program according to claim 11.
JP2013099718A 2013-05-09 2013-05-09 Image processing apparatus and method Pending JP2014220717A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013099718A JP2014220717A (en) 2013-05-09 2013-05-09 Image processing apparatus and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013099718A JP2014220717A (en) 2013-05-09 2013-05-09 Image processing apparatus and method

Publications (1)

Publication Number Publication Date
JP2014220717A true JP2014220717A (en) 2014-11-20

Family

ID=51938785

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013099718A Pending JP2014220717A (en) 2013-05-09 2013-05-09 Image processing apparatus and method

Country Status (1)

Country Link
JP (1) JP2014220717A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017122954A (en) * 2016-01-04 2017-07-13 富士ゼロックス株式会社 Management device, management system, and management program
JP2019047336A (en) * 2017-09-01 2019-03-22 キヤノン株式会社 Image processing apparatus, imaging device, image processing method, and program
US10382710B2 (en) 2015-08-05 2019-08-13 Canon Kabushiki Kaisha Image processing apparatus, image capturing apparatus, and non-transitory computer-readable storage medium

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10382710B2 (en) 2015-08-05 2019-08-13 Canon Kabushiki Kaisha Image processing apparatus, image capturing apparatus, and non-transitory computer-readable storage medium
JP2017122954A (en) * 2016-01-04 2017-07-13 富士ゼロックス株式会社 Management device, management system, and management program
JP2019047336A (en) * 2017-09-01 2019-03-22 キヤノン株式会社 Image processing apparatus, imaging device, image processing method, and program
US10832386B2 (en) 2017-09-01 2020-11-10 Canon Kabushiki Kaisha Image processing apparatus, image processing method, and storage medium
JP7057079B2 (en) 2017-09-01 2022-04-19 キヤノン株式会社 Image processing device, image pickup device, image processing method, and program

Similar Documents

Publication Publication Date Title
US10306141B2 (en) Image processing apparatus and method therefor
CN106797437B (en) High dynamic range image synthesis using multiple images
JP5398156B2 (en) WHITE BALANCE CONTROL DEVICE, ITS CONTROL METHOD, AND IMAGING DEVICE
CN108668093B (en) HDR image generation method and device
EP2704423B1 (en) Image processing apparatus, image processing method, and image processing program
US9542734B2 (en) Information processing apparatus, image processing method, and storage medium that determine tone characteristics for respective object signals
US20120008005A1 (en) Image processing apparatus, image processing method, and computer-readable recording medium having image processing program recorded thereon
WO2013054446A1 (en) Image compositing device, image compositing method, image compositing program, and recording medium
JP2013031174A (en) Apparatus and method for generating high dynamic range image from which ghost blur is removed using multi-exposure fusion base
US10699377B2 (en) Method, device, and camera for blending a first and a second image having overlapping fields of view
US10269128B2 (en) Image processing device and method, and recording medium
JP2011109638A (en) Image processing apparatus and image processing method
JP2014155001A (en) Image processing apparatus and image processing method
JP2014154108A (en) Image processing device
JP2017011327A (en) Image processing apparatus, image processing method, and program
JP2015144475A (en) Imaging apparatus, control method of the same, program and storage medium
JP2010278890A (en) Image forming apparatus, and image forming method
JP2014220717A (en) Image processing apparatus and method
JP7133979B2 (en) Image processing device, image processing method, image processing program, and storage medium
WO2017168528A1 (en) Image processing apparatus, image processing method, and image processing program
JP2004140692A (en) Image correcting device and image correcting method
JP6173027B2 (en) Image processing apparatus and image processing method
JP6554009B2 (en) IMAGE PROCESSING APPARATUS, CONTROL METHOD THEREOF, PROGRAM, AND RECORDING MEDIUM
JP5541956B2 (en) Image composition method, image composition program, and image composition apparatus
JP2005295302A (en) Camera image processing device