JP2009237927A - Image composition method and device - Google Patents

Image composition method and device Download PDF

Info

Publication number
JP2009237927A
JP2009237927A JP2008083619A JP2008083619A JP2009237927A JP 2009237927 A JP2009237927 A JP 2009237927A JP 2008083619 A JP2008083619 A JP 2008083619A JP 2008083619 A JP2008083619 A JP 2008083619A JP 2009237927 A JP2009237927 A JP 2009237927A
Authority
JP
Japan
Prior art keywords
image
color average
pixel
particle size
background image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2008083619A
Other languages
Japanese (ja)
Other versions
JP4797039B2 (en
Inventor
Norihiko Maeda
典彦 前田
Ikuo Harada
育生 原田
Takashi Aoki
孝 青木
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.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2008083619A priority Critical patent/JP4797039B2/en
Publication of JP2009237927A publication Critical patent/JP2009237927A/en
Application granted granted Critical
Publication of JP4797039B2 publication Critical patent/JP4797039B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Processing Or Creating Images (AREA)
  • Image Processing (AREA)
  • Studio Circuits (AREA)
  • Processing Of Color Television Signals (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To enable an image composition device, which obtains a composite image by compositing acomposition image having transmission information with a background image, to obtain a result having reality while reducing computational loads. <P>SOLUTION: This image composition device includes: a color average image generator 18 for generating a plurality of color average images B<SB>0</SB>to B<SB>3</SB>different in grainsize from a background image Go by performing blurring processing; a background blurring processor 15 for selecting a weighting coefficient corresponding to transmission information Oa of each pixel of the pixel in a composite image O and calculating a weighting sum of pixel values of the plurality of average color images B<SB>0</SB>to B<SB>3</SB>in pixels corresponding to the pixel to thereby generate a blurred background image Gb with the weighting sum defined as a pixel value; and an image composition processor 16 for compositing the composite image O with the blurred background image Gb in accordance with the transmission information Oa by α blending to obtain a composition result image M. <P>COPYRIGHT: (C)2010,JPO&INPIT

Description

本発明は、拡張現実感(AR;Augumented Reality)、複合現実感(MR;Mixed Reality)を実現する技術に関し、特に、カメラなどの撮像装置によって撮影される現実世界の撮影画像に対し、CG(コンピュータグラフィクス(computer graphics)技術を用いて生成された仮想物体、あるいは事前に撮影された実物体を重畳合成して表示する、画像合成方法及び装置に関する。   The present invention relates to a technology for realizing augmented reality (AR) and mixed reality (MR), and in particular, for a real-world captured image captured by an imaging device such as a camera, CG ( The present invention relates to an image composition method and apparatus for superimposing and displaying a virtual object generated using computer graphics technology or a real object photographed in advance.

現実世界の撮影画像に対して、その撮影画像には元来存在していない仮想物体などの物体があたかもそこに存在するかのように合成する技術がある。この場合、現実世界の撮影画像が背景画像として使用され、その背景画像に対して、仮想物体などの物体の画像(合成画像と呼ぶ)が手前側に重ね合わされることになる。背景画像に対して合成したい物体がCGにより生成した物体である場合も、現実世界の物体であって事前撮影により得られたものである場合も、ガラスやプラスチックなどからなる物体のように、光が透過する物体を合成画像として背景画像に合成した場合がある。そのような場合には、合成したい物体における光の透過度合を表す方法として、α(アルファ)値、αマスクなどが知られている。市販の画像編集用ソフトウェアなどにおいても、αマスクやαチャネルなどが一般的に使用可能となっている。   There is a technique for synthesizing an object such as a virtual object that does not originally exist in a captured image as if the object exists in the captured image in the real world. In this case, a captured image of the real world is used as a background image, and an image of an object such as a virtual object (referred to as a composite image) is superimposed on the background image. Whether the object to be synthesized with the background image is an object generated by CG or a real-world object obtained by pre-photographing, an object like glass or plastic There is a case where an object through which is transmitted is combined with a background image as a combined image. In such a case, an α (alpha) value, an α mask, and the like are known as a method for expressing the light transmittance of an object to be synthesized. In commercially available image editing software and the like, an α mask, an α channel, and the like can generally be used.

本件の出願人による特許文献1(特許第4007160号「画像処理方法及びその装置、並びに画像処理プログラムとこの画像処理プログラムを記録した記録媒体」)には、αマスクが設定された画像(合成画像)を背景画像に対して合成する際に、よりよい合成結果を得るための方法が示されている。その概要は、合成画像での透明度が高い部分については、背景画像をぼかさずに合成し、合成画像での透明度が低い部分については、背景画像をぼかして合成するというものである。図9は、特許文献1に示された画像合成の例を示しており、透過情報を有する合成画像Oとして飲料水用ペットボトルの画像を用い、これを背景画像Goに合成した場合を示している。合成画像Oは、各画素(ピクセル)ごとの色彩を示す色彩情報Ocと、αマスクとして各画素ごとの不透明度を示す不透明度情報Oaとから構成されている。不透明度情報(αマスク)Oaにおいて、白い部分は不透明度が高い部分である。このような合成画像Oを背景画像Goに対して合成した結果、合成結果画像Mが生成する。ペットボトルにおける透明部分が、合成結果画像Mにおいても背景画像が見える領域として表現されている。   Patent Document 1 (Patent No. 4007160 “Image processing method and apparatus, and image processing program and recording medium on which the image processing program is recorded”) by the applicant of the present application has an image (composite image) in which an α mask is set. ) Is synthesized with a background image, a method for obtaining a better synthesis result is shown. The outline is that a portion with high transparency in the composite image is combined without blurring the background image, and a portion with low transparency in the composite image is combined with the background image blurred. FIG. 9 shows an example of image composition shown in Patent Document 1, and shows a case where an image of a drinking water plastic bottle is used as a composite image O having transmission information and is synthesized with a background image Go. Yes. The composite image O includes color information Oc indicating the color of each pixel (pixel) and opacity information Oa indicating the opacity of each pixel as an α mask. In the opacity information (α mask) Oa, the white portion is a portion with high opacity. As a result of combining such a combined image O with the background image Go, a combined result image M is generated. The transparent portion in the plastic bottle is expressed as a region where the background image can be seen in the synthesis result image M.

図10及び図11は、透過情報を有する合成画像としてガラス製などが想定されたティーポットの画像を用い、縞模様を有する机の画像である背景画像上にこのような合成画像を合成した例を示している。図10に示したものでは、αマスクに基づいて単純に合成画像を背景画像に合成しているので、ティーポット下部に背景画像の縞模様がはっきりと見えているため、リアリティに欠けている。そこで特許文献1では、(1)式を用いることによって透明度が低い部分について背景画像をぼかして合成することにより、図11に示すような結果が実現できることが示されている。   10 and 11 show an example in which such a synthesized image is synthesized on a background image, which is an image of a desk having a striped pattern, using a teapot image assumed to be made of glass or the like as a synthesized image having transmission information. Show. In the case shown in FIG. 10, since the composite image is simply combined with the background image based on the α mask, the striped pattern of the background image is clearly seen at the lower part of the teapot, and lacks reality. Therefore, Patent Document 1 shows that the result shown in FIG. 11 can be realized by blurring and synthesizing the background image for the portion with low transparency by using the expression (1).

Figure 2009237927
Figure 2009237927

ここでx,yは各画像における座標値であり、PS(x,y)は合成結果画像での画素(x,y)における画素値であり、PC(x,y)は色彩画像(色彩情報Ocからなる画像)上での画素値であり、PT(x,y)は透明度画像(画素ごとに1から不透明度情報Oaを引いた画像)における画素値であり、PZが背景画像Goにおける画素値である。また、Kは、ぼかしを計算するために採用する隣接画素の最大範囲を示す定数であり、kはk=K×PT(x,y)で与えられる。 Here, x and y are coordinate values in each image, PS (x, y) is a pixel value at pixel (x, y) in the combined result image, and PC (x, y) is a color image (color information). Oc), and PT (x, y) is a pixel value in a transparency image (an image obtained by subtracting opacity information Oa from 1 for each pixel), and PZ is a pixel in the background image Go. Value. K is a constant indicating the maximum range of adjacent pixels used for calculating blur, and k is given by k = K × PT (x, y).

図11に示した合成結果画像では、ティーポット下部の領域において背景画像の縞模様がぼけたように表現されるため、ヒトの視覚的に「あたかも反射している」という錯覚を与え、これにより光沢感を表現することに成功している。
特許第4007160号明細書
In the synthesized result image shown in FIG. 11, the striped pattern of the background image is expressed as blurred in the region below the teapot, so that an illusion that the image is “reflected” is given to the human eye. It has succeeded in expressing a feeling.
Japanese Patent No. 4007160

しかしながら、上述した特許文献1に記載の方法は、画素ごとに「ぼかし」の処理を実行するので、演算に時間がかかる、という課題がある。   However, the method described in Patent Document 1 described above has a problem that it takes time to perform the calculation because the process of “blurring” is performed for each pixel.

(1)式での処理を概念的に図解したものが図12である。ここでは、合成における画素単位の計算において、以下のような事項が指摘できる。   FIG. 12 conceptually illustrates the processing in equation (1). Here, the following matters can be pointed out in the calculation of the pixel unit in the composition.

(1)背景画像のぼかし処理は、不透明度に応じた面積の色平均を求めることによって実施される。したがって、合成画像の不透明度(あるいは透明度)のマスクが確定していないと、ぼかし処理の計算を始めることができない。   (1) The background image blurring process is performed by obtaining a color average of areas according to opacity. Therefore, the blur calculation cannot be started unless the mask of the opacity (or transparency) of the composite image is determined.

(2)不透明度マスクにおいて、不透明度の高い領域が多い場合、色の平均を求める画素面積が大きくなる。そのような画素面積の色平均の算出が、何度も繰り返されるため、計算量が大きくなる。つまり、合成画像の不透明マスクに関して、不透明な領域の割合が多い場合は計算時間が大きくなり、不透明な領域の割合が少ない場合は計算時間が小さくなり、計算処理時間に大きなバラつきが生じる。特に、動画カメラで捕らえた背景画像に、リアルタイムで合成処理を実施する場合、この計算時間に応じて、フレームレートが一定しない状況が顕著に現れる。   (2) In the opacity mask, when there are many regions with high opacity, the pixel area for obtaining the average color becomes large. Since the calculation of the color average of the pixel area is repeated many times, the calculation amount increases. That is, regarding the opaque mask of the composite image, the calculation time increases when the ratio of the opaque area is large, and the calculation time decreases when the ratio of the opaque area is small, resulting in a large variation in the calculation processing time. In particular, when a synthesis process is performed in real time on a background image captured by a video camera, a situation in which the frame rate is not constant appears significantly according to the calculation time.

(3)隣り合う画素に関しては、背景画像の色平均を求める計算処理において、共通である領域に関しても、それぞれ独立に色平均を求める計算が実施され、結果として無駄な計算が多く含まれる。   (3) In the calculation process for obtaining the color average of the background image for adjacent pixels, the calculation for obtaining the color average is performed independently for each common region, and as a result, many unnecessary calculations are included.

本発明の目的は、特許文献1に示される手法の効果を活かしつつ、計算処理を簡略化することができる画像合成方法及び装置を提供することにある。具体的には、下記の事項を達成することにある。   An object of the present invention is to provide an image synthesizing method and apparatus capable of simplifying calculation processing while taking advantage of the technique disclosed in Patent Document 1. Specifically, it is to achieve the following items.

(1)不透明マスクが確定していなくても、背景画像のぼかし処理計算が開始できる、
(2)不透明領域の大小に関わらず、計算に要する時間を均一化する、
(3)色平均を求める際に、同じ部分で重複するような計算を発生させない。
(1) Even if the opaque mask is not fixed, the background image blurring calculation can be started.
(2) The time required for calculation is made uniform regardless of the size of the opaque region.
(3) When calculating the color average, the calculation which overlaps in the same part is not generated.

本発明の画像合成方法は、透過情報を有する合成画像を背景画像に合成して合成結果画像を得る画像合成方法であって、ぼかし処理を行うことによって背景画像から粒度が異なる複数の色平均画像を生成する色平均画像生成段階と、合成画像における画素ごとに、その画素の透過情報に応じた重み付け係数を選択してその画素に対応する画素における複数の色平均画像の画素値の重み付け和を求めることにより、重み付け和を画素値とするぼかし済み背景画像を生成し、αブレンンディングにより透過情報に応じて合成画像をぼかし済み背景画像に合成して合成結果画像を得る。   The image composition method of the present invention is an image composition method for obtaining a composite result image by compositing a composite image having transmission information with a background image, and a plurality of color average images having different particle sizes from the background image by performing blurring processing For each pixel in the composite image, a weighting coefficient corresponding to the transmission information of the pixel is selected, and a weighted sum of pixel values of a plurality of color average images in the pixel corresponding to the pixel is calculated. As a result, a blurred background image having a weighted sum as a pixel value is generated, and the synthesized image is synthesized with the blurred background image according to the transmission information by α blending to obtain a synthesized result image.

本発明の画像合成装置は、透過情報を有する合成画像を背景画像に合成して合成結果画像を得る画像合成方法であって、ぼかし処理を行うことによって背景画像から粒度が異なる複数の色平均画像を生成する色平均画像生成手段と、合成画像における画素ごとに、その画素の透過情報に応じた重み付け係数を選択してその画素に対応する画素における複数の色平均画像の画素値の重み付け和を求めることにより、重み付け和を画素値とするぼかし済み背景画像を生成する背景画像ぼかし処理手段と、αブレンンディングにより透過情報に応じて合成画像をぼかし済み背景画像に合成して合成結果画像を得る画像合成処理手段と、を有する。   An image composition apparatus according to the present invention is an image composition method for obtaining a composite result image by compositing a composite image having transmission information with a background image, and a plurality of color average images having different particle sizes from the background image by performing blurring processing For each pixel in the composite image, a weighting coefficient corresponding to the transmission information of the pixel is selected, and a weighted sum of pixel values of a plurality of color average images in the pixel corresponding to the pixel is calculated. By obtaining a background image blur processing unit that generates a blurred background image having a weighted sum as a pixel value, and synthesizing the synthesized image with the blurred background image according to the transmission information by α blending, a synthesized result image is obtained. Image composition processing means.

本発明は、上述した構成を採用することにより、(1)不透明マスクが確定していなくても、背景画像のぼかし処理計算が開始でき、(2)不透明領域の大小に関わらず、計算に要する時間を均一化することができ、(3)色平均を求める際に、同じ部分で重複するような計算の発生を防止でき、これにより、計算処理を軽減しつつリアリティのある合成結果画像が得られるようになる、という効果を有する。   According to the present invention, by adopting the above-described configuration, (1) even if an opaque mask is not determined, background image blurring calculation can be started, and (2) calculation is required regardless of the size of the opaque region. The time can be equalized, and (3) when calculating the color average, it is possible to prevent the occurrence of calculations that overlap in the same part, thereby obtaining a realistic composite result image while reducing the calculation process. Has the effect of becoming

次に、本発明の好ましい実施の形態について、図面を参照して説明する。   Next, a preferred embodiment of the present invention will be described with reference to the drawings.

一般に画像に対する「ぼかし」処理は、画像を構成する画素ごとに、その画素を対象画素として、対象画素の近傍の所定範囲内にある画素の色平均(画素値平均)を求めてその対象画素の画素値とする処理である。上述した特許文献1に記載のものでは、背景画像においてぼかし処理をする際に、ぼかし処理において平均化の対象となる画素の範囲を、合成画像における対応する画素の不透明度情報(あるいは透明度情報)に応じて定めていた。このやり方では、背景画像における画素ごとに、平均化対象の範囲の広さを変えながらぼかし処理を行わなければならないので、必要な演算処理量が膨大なものとなっている。   In general, the “blurring” process for an image is performed by calculating the color average (pixel value average) of pixels within a predetermined range in the vicinity of the target pixel for each pixel constituting the image, using the pixel as the target pixel. This is a process for obtaining a pixel value. In the above-described patent document 1, when performing blurring processing on a background image, the range of pixels to be averaged in blurring processing is set as opacity information (or transparency information) of corresponding pixels in the composite image. It was decided according to. In this method, blurring processing must be performed for each pixel in the background image while changing the size of the range to be averaged, so that a large amount of calculation processing is required.

そこで本実施形態では、ぼかし処理における「粒度」の概念を導入する。粒度とは、ぼかし処理においてどれだけの範囲の画素の画素値の平均(色平均)を求めるかを示すものであるが、さらに本実施形態では、ぼかし処理がなされた画像におけるその範囲(この範囲のことを「粒度範囲」と呼ぶ)内の画素の画素値はすべて同じであるものとする。すなわち、ある粒度がm×m画素の大きさに対応するものであるとすれば、粒度範囲はm×m画素となり、その粒度でぼかし処理がなされた画像は、それぞれがm×m画素の大きさである領域に分割されているとともに、m×m画素の大きさの各領域ごとにその領域内の画素の画素値はすべて同じであって、もとの画像におけるその領域内の画素の画素値の平均となっている。またnを0以上の整数として、粒度のレベルのことを粒度nのようにあらわす。このように粒度の概念を伴ってぼかし処理がされた画像のことを粒度nの色平均画像と呼ぶ。もちろん、ぼかし処理前の画像がカラー画像でなくグレースケール画像の場合もあるが、そのような場合にも色平均画像と呼ぶ。ただしこの場合は、色平均画像もグレースケール画像である。   Therefore, in this embodiment, the concept of “granularity” in the blurring process is introduced. The granularity indicates how much of the pixel value average (color average) of pixels in the blurring process is to be obtained. In the present embodiment, the range in the image subjected to the blurring process (this range). Are called the “granularity range”). In other words, if a certain granularity corresponds to the size of m × m pixels, the granularity range is m × m pixels, and each of the images subjected to the blurring process with the granularity has a size of m × m pixels. And the pixel values of the pixels in the area are the same for each area of the size of m × m pixels, and the pixels of the pixels in the area in the original image The average value. Further, n is an integer of 0 or more, and the level of granularity is expressed as granularity n. An image that has been subjected to the blurring process with the concept of grain size is referred to as a color average image having a grain size n. Of course, the image before the blurring process may be a grayscale image instead of a color image. In such a case, it is also called a color average image. However, in this case, the color average image is also a grayscale image.

本実施形態では、ある粒度レベルについて一度計算した色平均画像を、より粗い粒度レベルでの色平均画像を求める際に再利用する。図1は、この過程を概念的に示すものである。nは粒度のレベルを示し、小さい正方形は画素を示し、太線による正方形はその粒度のレベルでの粒度範囲を示している。   In this embodiment, the color average image calculated once for a certain granularity level is reused when obtaining a color average image with a coarser granularity level. FIG. 1 conceptually shows this process. n indicates a level of granularity, a small square indicates a pixel, and a square with a thick line indicates a particle size range at the level of the granularity.

まずn=0の場合は、色平均画像では、背景画像Goの画素単位の色情報をそのまま保持するものとする。すなわち、n=0の色平均画像B0は、背景画像Goと同一である。 First, in the case of n = 0, in the color average image, the color information of the pixel unit of the background image Go is held as it is. That is, the color average image B 0 with n = 0 is the same as the background image Go.

n=1の色平均画像B1は、色平均画像B0での4画素(2×2画素の領域)の色平均を求めてその値をn=1での粒度範囲内の各画素の値とする。 For the color average image B 1 with n = 1, the color average of 4 pixels (2 × 2 pixel area) in the color average image B 0 is obtained and the value is the value of each pixel within the granularity range with n = 1. And

n=2以降に関しては、色平均画像Bn-1で求めた各領域(n−1での粒度範囲)の4つを一つのグループとして、その色平均を求めて色平均画像Bnとする。この場合、各領域での色平均はすでに色平均画像nー1を求める処理で計算済みであることから、実際には、4つの領域ごとの値(RGB値あるいは輝度値)の平均を求めるだけでよい。以上の操作を一般的な式で示すと(2)式のようになる。 For n = 2 and later, four areas of the respective areas (granularity range at n−1) obtained in the color average image B n−1 are grouped into one group, and the color average is obtained as the color average image B n . . In this case, since the color average in each area has already been calculated in the process of obtaining the color average image n −1, in practice, only the average of the values (RGB values or luminance values) for each of the four areas is obtained. It's okay. The above operation is expressed by a general expression as shown in Expression (2).

Figure 2009237927
Figure 2009237927

ここでAverage{ }は、{ }内の要素の平均を算出する関数である。 Here, Average {} is a function for calculating the average of elements in {}.

以降、説明の便宜上、nの最大値が3であるとして、色平均画像B0,B1,B2,B3を用いるものとする。図2は、B0,B1,B2,B3を求める過程を示している。図2においては、一番小さい正方形の領域は、それぞれ、各粒度レベルでの粒度領域を示している。 Hereinafter, for convenience of explanation, it is assumed that the maximum value of n is 3, and color average images B 0 , B 1 , B 2 , B 3 are used. FIG. 2 shows a process for obtaining B 0 , B 1 , B 2 , and B 3 . In FIG. 2, the smallest square area indicates the granularity area at each granularity level.

このような計算により、色平均を求める過程において、同一領域の加算を重複して実施することを回避し計算の無駄を省くことができる。また、1ステップ前の計算結果を、そのまま再利用できるため、従来方法と比較して効率的に計算処理を進めることができる。   By such a calculation, it is possible to avoid redundantly performing the addition of the same region in the process of obtaining the color average and to save the calculation. In addition, since the calculation result of the previous step can be reused as it is, the calculation process can be performed more efficiently than in the conventional method.

本実施形態では、上述したような色平均画像B0〜B3からぼかし済み背景画像Gbを生成する。ぼかし済み背景画像Gbは、合成画像Oにおける画素ごとに、その画素の透過情報Oaに応じたぼかし処理を背景画像Goの対応する画素に対して施した画像であり、ここでは、特許文献1に記載されているように、合成画像での透明度が高い部分については、背景画像からのぼかしが小さく、合成画像での透明度が低い部分については、背景画像からのぼかしが大きくなるようなぼかし済み背景画像Gbとしている。具体的には、合成画像における画素ごとに、その画素の透過情報Oaに応じた重み付け係数を選択してその画素に対応する画素における色平均画像B0〜B3の画素値の重み付け和を求めることにより、その重み付け和を画素値とするぼかし済み背景画像Gbを生成している。すなわち、計算対象となる画素の座標を(x,y)とすると、座標(x,y)におけるぼかし済み背景画像Gb(x,y)の画素値を以下の式によって求めることとする。 In the present embodiment, the blurred background image Gb is generated from the color average images B 0 to B 3 as described above. The blurred background image Gb is an image obtained by performing, for each pixel in the composite image O, a blurring process corresponding to the transmission information Oa of the pixel on the corresponding pixel of the background image Go. As described, the blurred background where the blur in the background image is small for the part with high transparency in the composite image and the blur in the background image is large for the part with low transparency in the composite image The image is Gb. Specifically, for each pixel in the composite image, a weighting coefficient corresponding to the transmission information Oa of the pixel is selected to obtain a weighted sum of the pixel values of the color average images B 0 to B 3 in the pixel corresponding to the pixel. Thus, the blurred background image Gb having the weighted sum as a pixel value is generated. That is, assuming that the coordinates of the pixel to be calculated are (x, y), the pixel value of the blurred background image Gb (x, y) at the coordinates (x, y) is obtained by the following equation.

Gb(x,y)= W0(Oa(x,y))・B0(x,y)
+W1(Oa(x,y))・B1(x,y)
+W2(Oa(x,y))・B2(x,y)
+W3(Oa(x,y))・B3(x,y)
Sum{W0(Oa(x,y)),W1(Oa(x,y)),W2(Oa(x,y)),W3(Oa(x,y))}=1
ここでSum{ }は{ }内の値の総和を求める関数であり、Oa(x,y)は合成画像Oの座標(x,y)における透過情報Oaの値であり、i=0,1,2,3として、Bi(x,y)は色平均画像Biでの座標(x,y)における画素値である。また、Wiは、用意した複数の色平均画像B0〜B3のそれぞれについて、どれだけ計算結果に影響を及ぼさせるかを与える重み係数であり、各Wiの総和は1になるように、予め定義されているものとする。
Gb (x, y) = W 0 (Oa (x, y)) · B 0 (x, y)
+ W 1 (Oa (x, y)) · B 1 (x, y)
+ W 2 (Oa (x, y)) · B 2 (x, y)
+ W 3 (Oa (x, y)) · B 3 (x, y)
Sum {W 0 (Oa (x, y)), W 1 (Oa (x, y)), W 2 (Oa (x, y)), W 3 (Oa (x, y))} = 1
Here, Sum {} is a function for calculating the sum of the values in {}, Oa (x, y) is the value of the transmission information Oa at the coordinates (x, y) of the composite image O, and i = 0, 1 as 2,3, Bi (x, y) is the pixel value at the coordinates (x, y) of the color average image B i. W i is a weighting coefficient that gives an influence on the calculation result for each of the prepared color average images B 0 to B 3 , and the total sum of each W i is 1. Suppose that it is defined in advance.

図3は、Gb(x,y)の計算処理の概念図を示す。以上の説明では、色平均画像B0〜B3はいずれも背景画像Goと同じ画素数の画像であるが、粒度が大きい(粒度が粗い)色平均画像では1つの粒度範囲に含まれる画素数が大きくなり、粒度範囲内の各画素に同じ画素値をコピーする処理の負担が重くなる。そこで、メモリなどに格納する際には粒度範囲を単位としてデータを格納するようにし、すなわち、粒度レベルが大きくなるにつれて色平均画像のサイズが小さくなるようにし、ぼかし済み背景画像Gbの画素値の算出に際して、参照座標の変換計算を行うことにより、計算負荷を減らすようにすることが考えられる。 FIG. 3 shows a conceptual diagram of Gb (x, y) calculation processing. In the above description, the color average images B 0 to B 3 are all images having the same number of pixels as the background image Go. However, in a color average image having a large granularity (coarse granularity), the number of pixels included in one granularity range. Increases, and the burden of the process of copying the same pixel value to each pixel within the granularity range becomes heavy. Therefore, when storing in a memory or the like, the data is stored in units of the granularity range, that is, the size of the color average image is reduced as the granularity level increases, and the pixel value of the blurred background image Gb is set. At the time of calculation, it is conceivable to reduce the calculation load by performing conversion calculation of reference coordinates.

次に、上述した重み係数Wiについて説明する。図4は、座標(x,y)における不透過度に応じて各Wiにどれだけの重みを持たせるかを一例として示したものであり、マップ上に定義したものとして表現している。これは一例であり、背景画像を撮影するカメラの設置場所や、それに伴って確定する撮影画像に応じて、各現場ごとに、マッピングを手動で変更できるようにすることが好ましい。いずれにせよ、合成画像に含まれる物体の不透過度が高い場合(すなわち透過度が高い場合)、その物体の裏にある背景画像が見えやすい状況であるため、元の背景画像Goに近い画像B0がより強く影響するように、W0の重みを上げている。逆に、物体の不透過度が低い場合(すなわち透過度が低い場合)、その物体の裏にある背景画像が見え難い状況であるため、元の背景画像Goに近い画像B0がより弱く影響するように、W0の重みを下げている。 Next, a description will be given weighting factors W i as described above. Figure 4 is an illustration how to have a weight of how much each W i depending on the opacity at the coordinates (x, y) as an example, is represented as having been defined on the map. This is merely an example, and it is preferable that the mapping can be manually changed for each site according to the installation location of the camera that captures the background image and the captured image determined accordingly. In any case, when the opacity of the object included in the composite image is high (that is, when the transparency is high), the background image behind the object is easy to see, and thus an image close to the original background image Go. The weight of W 0 is increased so that B 0 affects more strongly. On the contrary, when the opacity of the object is low (that is, when the transparency is low), it is difficult to see the background image behind the object, so the image B 0 close to the original background image Go has a weaker effect. Thus, the weight of W 0 is lowered.

以上の処理により、ぼかし処理をほどこした背景画像すなわちぼかし済み背景画像Gbにおける画素値Gb(x,y)を求めることができる。あとは、合成画像の色彩情報Oc(x,y)とぼかし済み背景画像Gb(x,y)とを、透過情報Oa(x,y)の値を用いて、通常のαブレンド処理によって重ね合わせ合成することにより、合成結果画像Mが得られる。   With the above processing, the pixel value Gb (x, y) in the background image subjected to the blurring process, that is, the blurred background image Gb can be obtained. After that, the color information Oc (x, y) of the composite image and the blurred background image Gb (x, y) are superimposed by a normal α blend process using the value of the transmission information Oa (x, y). By combining, a combined result image M is obtained.

ここまでの座標(x,y)に対する処理を、合成画像がカバーする領域の全ての画素に対して実施することにより、特許文献1に示された効果と同様の効果を得ることができる。ぼかし具合の厳密性という観点では本実施形態の手法は特許文献1に記載のものに劣るが、特許文献1に記載のものに比べ、計算処理の負荷を劇的に低減することが可能である。   By performing the processing on the coordinates (x, y) so far for all the pixels in the region covered by the composite image, the same effect as that shown in Patent Document 1 can be obtained. Although the technique of this embodiment is inferior to that described in Patent Document 1 in terms of the degree of strictness of blurring, it is possible to dramatically reduce the load of calculation processing compared to that described in Patent Document 1. .

図5は、上述した処理を実行する画像合成装置の構成の一例を示すブロック図である。この画像合成装置は、カメラ11で撮影した画像(背景画像Go)に対して、合成画像記憶部12に記憶され透過情報を有する合成画像Oを合成し、合成結果画像Mとして表示装置17に出力するものである。この画像合成装置は、背景画像Goに対する合成画像Oの配置場所を決定し、合成画像Oの色彩情報Oc及び透過情報Oaを出力する合成物配置器13と、色平均画像B0〜B3を一時的に格納するメモリ14と、背景画像Goから上述した手順にしたがって色平均画像B1〜B3を生成する色平均画像生成器18と、合成画像Oにおける画素ごとに、その画素の透過情報に応じた重み付け係数Wiを選択してその画素に対応する画素における色平均画像B0〜B3の画素値の重み付け和を求めることにより、この重み付け和を画素値とするぼかし済み背景画像Gbを生成する背景画像ぼかし処理器15と、αブレンンディングにより透過情報Oaに応じて合成画像Oをぼかし済み背景画像Gbに合成して合成結果画像Mを得て出力する画像合成処理器16と、を備えている。上述したように色平均画像B0は背景画像Goであるから、カメラ11からの背景画像Goは、色平均画像生成器18とメモリ14内の色平均画像B0の記憶領域とに並列して送られる。 FIG. 5 is a block diagram illustrating an example of a configuration of an image composition device that performs the above-described processing. This image synthesizing device synthesizes a synthesized image O having transparency information stored in the synthesized image storage unit 12 with an image (background image Go) photographed by the camera 11 and outputs the synthesized image O to the display device 17 as a synthesized result image M. To do. This image synthesizing device determines the arrangement location of the synthesized image O with respect to the background image Go, and outputs the color information Oc and the transmission information Oa of the synthesized image O, and the synthesized product arranging device 13 and the color average images B 0 to B 3 . Temporary storage memory 14, color average image generator 18 that generates color average images B 1 to B 3 from the background image Go according to the above-described procedure, and transmission information of each pixel in the composite image O select a weighting factor W i corresponding to by obtaining a weighted sum of the pixel values of the color average image B 0 .about.B 3 in the pixel corresponding to the pixel, blurred already background image Gb of the weighted sum as the pixel value A background image blur processing unit 15 for generating the image, and an image composition for synthesizing the synthesized image O with the blurred background image Gb according to the transmission information Oa by α blending to obtain and output a synthesized result image M And a processor 16. Since the color average image B 0 is the background image Go as described above, the background image Go from the camera 11 is parallel to the color average image generator 18 and the storage area of the color average image B 0 in the memory 14. Sent.

以上説明した実施形態では、一つの合成結果画像Mを得るためには、粒度の異なる4種類の色平均画像B0〜B3を必要としている。しかしながら、入力する背景画像Goが連続する複数のフレームからなる動画である場合、動画の1フレームごとに色平均画像B0〜B3の全てを毎回求める必要はない。 In the embodiment described above, in order to obtain one synthesis result image M, four types of color average images B 0 to B 3 having different particle sizes are required. However, when the input background image Go is a moving image composed of a plurality of continuous frames, it is not necessary to obtain all of the color average images B 0 to B 3 for each frame of the moving image.

色平均画像と粒度との関係を検討すると、細かい粒度の色平均画像、例えば色平均画像B0,B1は、詳細な画像情報であって画質に大きな影響を与えるため、1フレーム単位に計算した方がよい。これに対して粗い粒度の色平均画像、例えば色平均画像B3,B4は、輪郭のはっきりしないぼけた画像情報しか有していない。しかも、このような色平均画像B3,B4に大きな重みが与えられるのは、合成画像Oの不透過率が大きい場合であって、そのようなときは、合成画像Oの後景となるぼかし済み背景画像Gbが画質に与える影響はそれほど大きくない。したがって、背景画像となる動画の中で動く物体があったとしても、相対的にぼけた画像である色平均画像B3,B4においては、その影響が小さいものとみなすことができる。つまり、ぼけが大きい色平均画像B3,B4などに関しては、1フレーム単位に厳密に計算する必要はなく、数フレームごとに計算する間引きを行なうことで、さらに計算の負荷を低減することができる。具体的な例としては、「色平均画像B0,B1は1フレームごとに更新し、色平均画像B3は2フレームごとに更新し、色平均画像B4は4フレームごとに更新する」ということが考えられる。 Examining the relationship between the color average image and the granularity, the color average image having a fine granularity, for example, the color average images B 0 and B 1, are detailed image information and have a large influence on the image quality, and thus are calculated in units of one frame. You should do it. On the other hand, a color average image with a coarse particle size, for example, the color average images B 3 and B 4 , has only blurred image information with unclear outlines. Moreover, a large weight is given to the color average images B 3 and B 4 when the opacity of the composite image O is large. In such a case, the background image of the composite image O is obtained. The influence of the blurred background image Gb on the image quality is not so great. Therefore, even if there is a moving object in the moving image serving as the background image, it can be considered that the influence is small in the color average images B 3 and B 4 which are relatively blurred images. In other words, for the color average images B 3 and B 4 with large blurring, it is not necessary to calculate strictly for each frame, and the calculation load can be further reduced by performing decimation for every several frames. it can. As a specific example, “the color average images B 0 and B 1 are updated every frame, the color average image B 3 is updated every two frames, and the color average image B 4 is updated every four frames”. It can be considered.

本実施形態の画像合成装置についてソフトウェアによって全ての処理を実装する場合には、このように、処理を間引いて負荷を軽減することが有効になる。   When all the processing is implemented by software for the image composition apparatus of the present embodiment, it is effective to reduce the load by thinning the processing in this way.

また、ぼかし処理の計算結果をパイプライン的に処理できる場合は、色平均画像Bn-1から色平均画像Bnを生成する処理を、以下のように時間差で実行することも可能である。 When the calculation result of the blurring process can be processed in a pipeline manner, the process of generating the color average image Bn from the color average image Bn-1 can be executed with a time difference as follows.

0は、カメラから与えられる最新の背景画像Go
1は、1フレーム前のB0を参照して計算する。(B0に対して1フレーム遅れ)
2は、1フレーム前のB1を参照して計算する。(B0に対して2フレーム遅れ)
3は、1フレーム前のB2を参照して計算する。(B0に対して3フレーム遅れ)
このようなパイプライン的な処理が実施できれば、色平均画像B0〜B4までを直列でなく並列的に計算することができ、マルチプロセスが可能な環境、あるいはハードウェアによる実装においては、計算時間の短縮に寄与することができる。
B 0 is the latest background image Go given from the camera.
B 1 is calculated with reference to B 0 one frame before. (1 frame delay from B 0 )
B 2 is calculated with reference to B 1 one frame before. (2 frames behind B 0 )
B 3 is calculated with reference to B 2 one frame before. (3 frames behind B 0 )
If such pipeline processing can be performed, the color average images B 0 to B 4 can be calculated not in series but in parallel. In an environment where multi-process is possible, or in hardware implementation, calculation is performed. This can contribute to shortening the time.

図6は、このようにパイプラインによる処理を実行する画像合成装置の構成の一例を示している。図示される装置は、図5に示す装置と同様のものであるが、色平均画像生成器の代わりにパイプライン処理を実行する3個の変換器21〜23が設けられている点で図5に示すものと相違している。変換器21は、メモリ14に格納されている色平均画像B0を読み出して色平均処理を行って色平均画像B1を生成し、生成した色平均画像B1をメモリ14に格納する。同様に変換器22は、メモリ14に格納されている色平均画像B1を読み出し色平均画像B2を生成してメモリ14に格納し、変換器23は、メモリ14に格納されている色平均画像B0を読み出し色平均画像B1を生成してメモリ14に格納する。 FIG. 6 shows an example of the configuration of an image composition device that executes pipeline processing in this way. The illustrated apparatus is similar to the apparatus shown in FIG. 5 except that three converters 21 to 23 for executing pipeline processing are provided instead of the color average image generator. It is different from what is shown in. Converter 21 generates the color average image B 1 performs color averaging process by reading the color average image B 0 stored in the memory 14, and stores the generated color average image B 1 to the memory 14. Similarly, the converter 22 reads the color average image B 1 stored in the memory 14, generates the color average image B 2 and stores it in the memory 14, and the converter 23 stores the color average image stored in the memory 14. The image B 0 is read and a color average image B 1 is generated and stored in the memory 14.

以上の説明では、4種類の色平均画像B0〜B3を生成するとしたが、それ以上に粒度の粗い色平均画像Bn(n≧4)までを生成してもかまわない。 In the above description, four types of color average images B 0 to B 3 are generated. However, a color average image B n (n ≧ 4) with a coarser grain size may be generated.

以上述べてきた手法により、達成すべき項目として挙げた下記事項が実現される:
(1)不透明マスクが確定していなくても、背景画像のぼかし処理計算が開始できる,
(2)不透明領域の大小に関わらず、計算に要する時間を均一化する,
(3)色平均を求める際に、同じ部分で重複するような計算を発生させない。
With the methods described above, the following items listed as items to be achieved are realized:
(1) Even if the opaque mask is not fixed, the background image blur calculation can be started.
(2) Make the time required for calculation uniform regardless of the size of the opaque area.
(3) When calculating the color average, the calculation which overlaps in the same part is not generated.

以上説明した画像合成装置は、それを実現するためのコンピュータプログラムを、パーソナルコンピュータ(PC)やサーバ用コンピュータなどのコンピュータに読み込ませ、そのプログラムを実行させることによっても実現できる。上述した手順で画像合成を行うためのプログラムは、CD−ROMなどの記録媒体によって、あるいはネットワークを介して、コンピュータに読み込まれる。   The image synthesizing apparatus described above can also be realized by reading a computer program for realizing it into a computer such as a personal computer (PC) or a server computer and executing the program. A program for performing image composition in the above-described procedure is read into a computer by a recording medium such as a CD-ROM or via a network.

次に、上述した本発明の画像合成方法及び装置の応用例について説明する。   Next, application examples of the above-described image composition method and apparatus of the present invention will be described.

[応用例1]
図7は、PC(パーソナルコンピュータ)と大画面モニタと背景画像を取得する動画カメラとを組み合わせ、リアルタイムで画像合成を実施するようにした例を示している。この例では、合成画像となるオブジェクト(物体)やキャラクタ(人物像)に関して、事前に、その画像情報やαマスク情報が、多数の視点からそのオブジェクトやキャラクタを眺めた場合について、予めPCに蓄積されているものとする。
[Application Example 1]
FIG. 7 shows an example in which a PC (personal computer), a large screen monitor, and a moving image camera that acquires a background image are combined to perform image synthesis in real time. In this example, with respect to an object (object) or character (person image) to be a composite image, the image information and α mask information are stored in advance in the PC when the object or character is viewed from many viewpoints. It is assumed that

(従来技術による実装)
比較のため、まずは従来技術を用いてソフトウェアで合成処理を実施する場合について述べる。
(Mounting by conventional technology)
For comparison, first, a case will be described in which synthesis processing is performed by software using the conventional technique.

第一段階:ユーザは、システムの前に置かれているマーカを身に着けたり、手に持つなどして、そのマーカがカメラによって撮影されるように大画面モニタの前に立つ。動画カメラが、ユーザとマーカ、及びそれらの背景を1フレーム分撮影し、その画像データをPCに送出する。   First stage: The user stands in front of a large-screen monitor so that the marker is photographed by the camera, such as wearing or holding the marker placed in front of the system. The video camera captures one frame of the user, the marker, and their background, and sends the image data to the PC.

第二段階:PCは、撮影された画像データを受け取り、自動画像認識処理によってその画像データの中からマーカの位置、大きさ、向きを算出する。上記によって求められたマーカの位置、大きさ、向きに応じて、PCは、合成するオブジェクトやキャラクタの種類を特定し、さらに合成に用いる蓄積データのうち最も視点として近いものを選択し、撮影画像中における合成の位置を決定する。   Second stage: The PC receives captured image data, and calculates the position, size, and orientation of the marker from the image data by automatic image recognition processing. In accordance with the position, size, and orientation of the marker determined as described above, the PC specifies the type of object or character to be combined, and selects the stored data that is closest to the viewpoint from among the stored data used for combining, and the captured image Determine the position of the composition within.

第三段階:合成するオブジェクトの位置、大きさが決まると、撮影画像に対してぼかし処理を実施するべきエリアが確定する。PCは、このエリアの各画素に対して、合成オブジェクトのαマスク情報を用いて、ぼかし処理を実施する。   Third stage: When the position and size of the object to be combined are determined, the area where the blurring process should be performed on the captured image is determined. The PC performs a blurring process on each pixel in this area using the α mask information of the composite object.

第四段階:ぼかし処理の完了した撮影画像を後方に置く背景画像として、合成物(オブジェクトまたはキャラクタ)をαブレンディングにより重畳する。   Fourth stage: A composite (object or character) is superposed by α blending as a background image on which the photographed image for which the blurring process has been completed is placed behind.

第五段階:アプリケーションの設定に応じて、鏡面反転処理が必要とされる場合には鏡面反転を実施して、もしくは鏡面反転が不要な場合にはそのままで、PCは、合成結果画像を大型モニタに表示する。以後、第一段階に戻って処理を繰り返す。   Fifth stage: Depending on the application settings, if mirror reversal processing is required, mirror reversal is performed, or if mirror reversal is not necessary, the PC can display the composite result image on a large monitor. To display. Thereafter, the process returns to the first stage and is repeated.

以上が、従来技術をソフトウェアで実装した場合の処理の流れである。   The above is the processing flow when the conventional technology is implemented by software.

この場合、マーカがカメラから見て遠方であったり、合成物が小さい場合には、ぼかし処理が必要とされる画素面積が少ないため、ぼかし処理自体に必要となる計算量は少なくなり、画面更新のフレームレートは早くなる。その反面、マーカが近くにある場合や、合成物が大きい場合、撮影画像のほぼ全体にわたってぼかし処理を行うことが必要な状況となる。上述の[発明が解決しようとする課題]の欄で述べたように、隣接する画素同士のぼかし処理においては、重複する計算が無駄に繰り返される可能性があり、処理に時間がかかり、結果として画像更新のフレームが遅くなる。また、第一段階から順番に処理していく必要があり、合成物の位置が決まらないとぼかし処理が開始できないという特徴がある。   In this case, if the marker is far from the camera or the composite is small, the pixel area that needs to be blurred is small, so the amount of calculation required for the blurring itself is small and the screen is updated. Frame rate will be faster. On the other hand, when the marker is close or the composite is large, it is necessary to perform blurring processing over almost the entire captured image. As described in the above section [Problems to be solved by the invention], in the blurring process between adjacent pixels, there is a possibility that overlapping calculations may be repeated in vain, which takes time and results in the process. Image update frame is slow. Moreover, it is necessary to process sequentially from the first stage, and the blurring process cannot be started unless the position of the composite is determined.

(本発明の方法による実装)
次に、本発明に基づく方法で実施した場合について述べる。
(Implementation by the method of the present invention)
Next, the case where it implements by the method based on this invention is described.

第一段階:上述の従来の方法によるものと同じである。   First stage: the same as in the conventional method described above.

第二段階:PCは、以下の二つの処理を並列で実行する:
[2a]従来技術の第二段階と同様に、マーカ認識処理を実施する;
[2b]本提案で示した、撮影画像を順々にぼかしていった画像(色平均画像)を複数生成する。
Second stage: The PC performs the following two processes in parallel:
[2a] Perform marker recognition processing as in the second stage of the prior art;
[2b] A plurality of images (color average images) obtained by sequentially blurring the captured images shown in the present proposal are generated.

第三段階:PCは、複数生成された色平均画像と、合成物が配置される場所のαマスクを参照しながら、重み係数にしたがって、ぼかし済み背景画像を生成する。   Third stage: The PC generates a blurred background image according to a weighting factor while referring to a plurality of generated color average images and an α mask where the composite is placed.

第四段階:ぼかし済み背景画像を後方に置く画像として、合成物(オブジェクトまたはキャラクタ)をαブレンディングにより重畳する。   Fourth stage: A composite (object or character) is superimposed by α blending as an image with the blurred background image placed behind.

第五段階:上述の従来の方法によるものと同じである。   Fifth stage: Same as the above-mentioned conventional method.

以上に示したように、本発明の方法を応用した場合には、無駄な重複計算を回避しつつ、ぼかし処理が画像の全体に及ぶような場合であってもそうでない場合であっても、計算量が一定となる。したがって、フレームレートがばらつくような問題を回避することが可能となる。また、マルチコアCPUが搭載され、また、パラレル演算処理を支援する拡張ボードが利用可能となった昨今のPCにおいては、第二段階において、画像物の位置特定を待たずに同時並行でぼかし処理(色平均画像の生成処理)を開始することができ、全体としての処理を効率的に行なうことが可能となる。   As described above, when the method of the present invention is applied, whether or not the blurring process covers the entire image while avoiding useless duplication calculation, The amount of calculation is constant. Therefore, it is possible to avoid the problem that the frame rate varies. In recent PCs equipped with a multi-core CPU and an expansion board that supports parallel arithmetic processing can be used, in the second stage, the blur processing (in parallel) without waiting for the position of the image object to be specified ( Color average image generation process) can be started, and the entire process can be efficiently performed.

[応用例2]
図7は、画像合成処理を行うサーバをネットワーク上に設け、画像合成処理サービスを提供するようにしたシステムを示している。インターネットなどのデータネットワーク30に対し、本発明の方法で画像合成を行う処理サーバ31が接続するとともに、携帯電話32、PC33が接続している。携帯電話32及びPC33は、電子メールで、あるいはプロトコルとしてHTTP(Hypertext Transfer Protocol)を使用して処理サーバ31にアクセス可能である。
[Application 2]
FIG. 7 shows a system in which a server for performing image composition processing is provided on a network to provide an image composition processing service. A processing server 31 that performs image composition by the method of the present invention is connected to a data network 30 such as the Internet, and a mobile phone 32 and a PC 33 are connected. The mobile phone 32 and the PC 33 can access the processing server 31 by e-mail or using HTTP (Hypertext Transfer Protocol) as a protocol.

まず、マーカをページ中に含んだ紙冊子を、店頭設置や郵送などの手段によりユーザに配布する。ユーザは、マーカが印刷されたページを冊子から切り離して、これを撮影に利用することとする。ユーザは、カメラ付携帯電話32により撮影した画像を電子メールやHTTPによって処理サーバ31に送出することができる。または、デジタルカメラで撮影した画像を、PC33を使い電子メールやHTTPによって処理サーバに送出することができる。この時、合成するオブジェクトを指定するための商品番号などを、合わせて送出することもできる。   First, a paper booklet including a marker in a page is distributed to users by means such as store installation or mailing. The user separates the page on which the marker is printed from the booklet and uses it for photographing. The user can send an image captured by the camera-equipped mobile phone 32 to the processing server 31 by e-mail or HTTP. Alternatively, an image taken with a digital camera can be sent to the processing server by e-mail or HTTP using the PC 33. At this time, a product number or the like for designating an object to be combined can be sent together.

処理サーバ31は、受信した画像からマーカを自動認識し、オブジェクトやキャラクタによる画像合成処理を実施してユーザに返送する。図示した例では、机の上にマーカとコーヒーカップとが配置されている画像を送信画像(撮影画像)として処理サーバ31に送ると、処理サーバ31での画像合成処理により、マーカ上にガラス製の花瓶が配置された画像が合成結果画像として生成し、端末側はその合成結果画像を受信画像として受け取る。   The processing server 31 automatically recognizes a marker from the received image, performs an image composition process using an object or character, and returns it to the user. In the illustrated example, when an image in which a marker and a coffee cup are arranged on a desk is sent to the processing server 31 as a transmission image (captured image), the image is made of glass on the marker by image synthesis processing in the processing server 31. An image in which a vase is arranged is generated as a combined result image, and the terminal side receives the combined result image as a received image.

以上により、ユーザは、自端末に画像認識や画像合成のためのソフトウェアを備えることなく、結果としての合成結果画像を入手することができる。   As described above, the user can obtain the resultant composite result image without providing the terminal with software for image recognition or image composition.

従来技術を用いた場合には、ぼかし処理において無駄な繰り返しの計算があったため、処理サーバに負荷がかかりやすかった。特にサーバクライアント型のシステム構成とした場合、多数のユーザが同時にアクセスして来るような状況が想定されるため、処理サーバ側の処理が軽いほど、システム全体としてのパフォーマンスが向上することになる。本発明に基づく方法を適用することにより、処理サーバ側の処理負荷が軽減されるため、処理サーバ側で重系システムを構築する場合でも、より少ない台数で、従来技術の場合と同等のパフォーマンスを得ることができる。   In the case of using the conventional technique, there is a wasteful calculation in the blurring process, and thus it is easy to put a load on the processing server. In particular, in the case of a server client type system configuration, a situation in which a large number of users are accessing at the same time is assumed. Therefore, as the processing on the processing server side is lighter, the performance of the entire system is improved. By applying the method according to the present invention, the processing load on the processing server side is reduced. Therefore, even when a heavy system is built on the processing server side, the performance is the same as in the case of the prior art with a smaller number of units. Obtainable.

粒度が異なる色平均画像を順次生成する過程を概念的に示す図である。It is a figure which shows notionally the process in which the color average image from which a particle size differs is produced | generated sequentially. 粒度が異なる色平均画像B0,B1,B2,B3を生成する過程を示す図である。The particle size is a diagram illustrating a process of generating a different color average image B 0, B 1, B 2 , B 3. 本発明の実施の一形態の画像合成方法におけるぼかし済み背景画像Gbを求める処理を説明する図である。It is a figure explaining the process which calculates | requires the blurred background image Gb in the image composition method of one Embodiment of this invention. 不透過度と重み係数Wiとの関係を示す図である。It is a diagram showing a relationship between opacity and the weighting factor W i. 本発明の実施の一形態の画像合成装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image composition apparatus of one Embodiment of this invention. 本発明の別の実施形態の画像合成装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image composition apparatus of another embodiment of this invention. 動画像に対するリアルタイムでの画像合成に適用した例を示す図である。It is a figure which shows the example applied to the image synthesis in real time with respect to a moving image. ネットワーク上のサーバによって画像合成処理サービスを提供するようにしたシステムを示すブロック図である。It is a block diagram showing a system in which an image composition processing service is provided by a server on a network. 透過情報を有する合成画像を背景画像に合成した例を示す図である。It is a figure which shows the example which synthesize | combined the synthesized image which has transparency information with the background image. 合成結果画像の一例を示す図である。It is a figure which shows an example of a synthetic result image. 合成結果画像の一例を示す図である。It is a figure which shows an example of a synthetic result image. 特許第4007160号明細書に示された画像合成方法における処理を概念的に示す図である。It is a figure which shows notionally the process in the image composition method shown by the patent 4007160 specification.

符号の説明Explanation of symbols

11 カメラ
12 合成画像記憶部
13 合成物配置器
14 メモリ
15 背景画像ぼかし処理器
16 画像合成処理器
17 表示装置
18 色平均画像生成器
21〜23 変換器
30 データネットワーク
31 処理サーバ
32 携帯電話
33 PC(パーソナルコンピュータ)
DESCRIPTION OF SYMBOLS 11 Camera 12 Composite image memory | storage part 13 Composite arrangement | positioning device 14 Memory 15 Background image blurring processor 16 Image composition processor 17 Display apparatus 18 Color average image generator 21-23 Converter 30 Data network 31 Processing server 32 Cellular phone 33 PC (Personal computer)

Claims (9)

透過情報を有する合成画像を背景画像に合成して合成結果画像を得る画像合成方法であって、
ぼかし処理を行うことによって前記背景画像から粒度が異なる複数の色平均画像を生成する色平均画像生成段階と、
前記合成画像における画素ごとに、当該画素の透過情報に応じた重み付け係数を選択して当該画素に対応する画素における前記複数の色平均画像の画素値の重み付け和を求めることにより、前記重み付け和を画素値とするぼかし済み背景画像を生成し、
αブレンンディングにより前記透過情報に応じて前記合成画像を前記ぼかし済み背景画像に合成して合成結果画像を得る、
画像合成方法。
An image composition method for obtaining a composite result image by compositing a composite image having transmission information with a background image,
A color average image generation step of generating a plurality of color average images having different particle sizes from the background image by performing a blurring process;
For each pixel in the composite image, a weighting coefficient corresponding to the transmission information of the pixel is selected, and a weighted sum of pixel values of the plurality of color average images in the pixel corresponding to the pixel is obtained. Generate a blurred background image with pixel values,
The blended image is synthesized with the blurred background image according to the transmission information by α blending to obtain a synthesized result image.
Image composition method.
前記背景画像を粒度0の色平均画像とし、nを1以上の整数とし、
前記色平均画像生成段階において、粒度(n−1)の色平均画像に対して、粒度(n−1)での所定の数の粒度範囲についての色平均を求めることによって、粒度nの色平均処理を生成し、これによって複数の粒度での色平均画像を再帰的に生成する、請求項1に記載の画像合成方法。
The background image is a color average image with a particle size of 0, n is an integer of 1 or more,
In the color average image generation step, the color average of the particle size n is obtained by obtaining the color average of a predetermined number of particle size ranges at the particle size (n-1) for the color average image of the particle size (n-1). The image synthesizing method according to claim 1, wherein processing is generated to thereby recursively generate a color average image with a plurality of granularities.
前記背景画像が連続する複数のフレームからなる動画像であり、iを所定のしきい値として、粒度iよりも粗い粒度の色平均画像については、一定のフレームごとに間引きながら生成する、請求項2に記載の画像合成方法。   The background image is a moving image composed of a plurality of continuous frames, and a color average image having a particle size coarser than the particle size i is generated by thinning out every predetermined frame with i as a predetermined threshold value. 3. The image composition method according to 2. 前記背景画像が連続する複数のフレームからなる動画像であり、
前記色平均画像生成段階において、前フレームでの粒度(n−1)の色平均画像に対して、粒度(n−1)での前記所定の数の粒度範囲についての色平均を求めることによって、現フレームでの粒度nの色平均画像を生成する、請求項2に記載の画像合成方法。
The background image is a moving image composed of a plurality of continuous frames;
In the color average image generation step, by obtaining a color average for the predetermined number of particle size ranges at the particle size (n−1) with respect to the color average image of the particle size (n−1) in the previous frame, The image composition method according to claim 2, wherein a color average image having a particle size n in a current frame is generated.
透過情報を有する合成画像を背景画像に合成して合成結果画像を得る画像合成方法であって、
ぼかし処理を行うことによって前記背景画像から粒度が異なる複数の色平均画像を生成する色平均画像生成手段と、
前記合成画像における画素ごとに、当該画素の透過情報に応じた重み付け係数を選択して当該画素に対応する画素における前記複数の色平均画像の画素値の重み付け和を求めることにより、前記重み付け和を画素値とするぼかし済み背景画像を生成する背景画像ぼかし処理手段と、
αブレンンディングにより前記透過情報に応じて前記合成画像を前記ぼかし済み背景画像に合成して合成結果画像を得る画像合成処理手段と、
を有する画像合成装置。
An image composition method for obtaining a composite result image by compositing a composite image having transmission information with a background image,
A color average image generating means for generating a plurality of color average images having different particle sizes from the background image by performing a blurring process;
For each pixel in the composite image, a weighting coefficient corresponding to the transmission information of the pixel is selected, and a weighted sum of pixel values of the plurality of color average images in the pixel corresponding to the pixel is obtained. Background image blur processing means for generating a blurred background image as a pixel value;
image synthesis processing means for synthesizing the synthesized image with the blurred background image according to the transmission information by α blending to obtain a synthesized result image;
An image synthesizing apparatus.
前記背景画像を粒度0の色平均画像とし、nを1以上の整数とし、
前記色平均画像生成手段は、粒度(n−1)の色平均画像に対して、粒度(n−1)での所定の数の粒度範囲についての色平均を求めることによって、粒度nの色平均処理を生成し、これによって複数の粒度での色平均画像を再帰的に生成する、請求項5に記載の画像合成装置。
The background image is a color average image with a particle size of 0, n is an integer of 1 or more,
The color average image generation means obtains a color average of a predetermined number of particle size ranges at the particle size (n-1) for the color average image of the particle size (n-1), thereby obtaining a color average of the particle size n. The image synthesizing apparatus according to claim 5, wherein the image synthesizing apparatus generates a process and thereby recursively generates a color average image with a plurality of granularities.
前記背景画像が連続する複数のフレームからなる動画像であり、iを所定のしきい値として、粒度iよりも粗い粒度の色平均画像については、一定のフレームごとに間引きながら生成する、請求項6に記載の画像合成装置。   The background image is a moving image composed of a plurality of continuous frames, and a color average image having a particle size coarser than the particle size i is generated by thinning out every predetermined frame with i as a predetermined threshold value. 6. The image composition device according to 6. 前記背景画像が連続する複数のフレームからなる動画像であり、
前記複数の色平均画像を保持するメモリをさらに備え、
前記色平均画像生成手段は、前記メモリに格納された前フレームでの粒度(n−1)の色平均画像に対して、粒度(n−1)での前記所定の数の粒度範囲についての色平均を求めることによって、現フレームでの粒度nの色平均画像を生成して前記メモリに格納する変換手段を備える、請求項6に記載の画像合成装置。
The background image is a moving image composed of a plurality of continuous frames;
A memory for holding the plurality of color average images;
The color average image generating means is configured to output the color for the predetermined number of granularity ranges at the granularity (n−1) with respect to the color average image of the granularity (n−1) in the previous frame stored in the memory. The image synthesizing apparatus according to claim 6, further comprising a conversion unit that generates a color average image having a granularity n in a current frame by storing an average and stores the average image in the memory.
コンピュータに請求項1乃至4のいずれか1項に記載の画像合成方法を実行させるプログラム。   The program which makes a computer perform the image composition method of any one of Claims 1 thru | or 4.
JP2008083619A 2008-03-27 2008-03-27 Image composition method and apparatus Expired - Fee Related JP4797039B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008083619A JP4797039B2 (en) 2008-03-27 2008-03-27 Image composition method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008083619A JP4797039B2 (en) 2008-03-27 2008-03-27 Image composition method and apparatus

Publications (2)

Publication Number Publication Date
JP2009237927A true JP2009237927A (en) 2009-10-15
JP4797039B2 JP4797039B2 (en) 2011-10-19

Family

ID=41251794

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008083619A Expired - Fee Related JP4797039B2 (en) 2008-03-27 2008-03-27 Image composition method and apparatus

Country Status (1)

Country Link
JP (1) JP4797039B2 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011123741A (en) * 2009-12-11 2011-06-23 Toppan Printing Co Ltd Sample providing device and promotion development system
EP2506560A2 (en) 2011-03-31 2012-10-03 Casio Computer Co., Ltd. Image Processing Apparatus, Image Processing Method, and Storage Medium
EP2506552A1 (en) 2011-03-31 2012-10-03 Casio Computer Co., Ltd. Image processing apparatus, image processing method, and storage medium
US9094625B2 (en) 2010-12-14 2015-07-28 Thomson Licensing Method and device for generating images comprising motion blur
CN112511768A (en) * 2020-11-27 2021-03-16 上海网达软件股份有限公司 Multi-picture synthesis method, device, equipment and storage medium
CN112653905A (en) * 2019-10-12 2021-04-13 腾讯数码(天津)有限公司 Image processing method, device, equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002204453A (en) * 2000-10-27 2002-07-19 Matsushita Electric Ind Co Ltd Image object content generator and padding device
JP2006186983A (en) * 2004-12-01 2006-07-13 Univ Of Tokushima Color image exposure compensation method
JP2007082145A (en) * 2005-09-16 2007-03-29 Seiko Epson Corp Image processing apparatus, image processing method, and program
JP2008187230A (en) * 2007-01-26 2008-08-14 Nikon Corp Camera, image processing program, and image processing method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002204453A (en) * 2000-10-27 2002-07-19 Matsushita Electric Ind Co Ltd Image object content generator and padding device
JP2006186983A (en) * 2004-12-01 2006-07-13 Univ Of Tokushima Color image exposure compensation method
JP2007082145A (en) * 2005-09-16 2007-03-29 Seiko Epson Corp Image processing apparatus, image processing method, and program
JP2008187230A (en) * 2007-01-26 2008-08-14 Nikon Corp Camera, image processing program, and image processing method

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011123741A (en) * 2009-12-11 2011-06-23 Toppan Printing Co Ltd Sample providing device and promotion development system
US9094625B2 (en) 2010-12-14 2015-07-28 Thomson Licensing Method and device for generating images comprising motion blur
EP2506560A2 (en) 2011-03-31 2012-10-03 Casio Computer Co., Ltd. Image Processing Apparatus, Image Processing Method, and Storage Medium
EP2506552A1 (en) 2011-03-31 2012-10-03 Casio Computer Co., Ltd. Image processing apparatus, image processing method, and storage medium
US9020255B2 (en) 2011-03-31 2015-04-28 Casio Computer Co., Ltd. Image processing apparatus, image processing method, and storage medium
CN112653905A (en) * 2019-10-12 2021-04-13 腾讯数码(天津)有限公司 Image processing method, device, equipment and storage medium
CN112511768A (en) * 2020-11-27 2021-03-16 上海网达软件股份有限公司 Multi-picture synthesis method, device, equipment and storage medium
CN112511768B (en) * 2020-11-27 2024-01-02 上海网达软件股份有限公司 Multi-picture synthesis method, device, equipment and storage medium

Also Published As

Publication number Publication date
JP4797039B2 (en) 2011-10-19

Similar Documents

Publication Publication Date Title
CN111161660B (en) Data processing system
US6809731B2 (en) System and method for rendering high-resolution critical items
CN108965847B (en) Method and device for processing panoramic video data
US8237730B1 (en) Tone mapping for motion pictures
EP2709057A2 (en) System, method and computer program product for image processing, in particular for introducing blurring effects to an image
JP4797039B2 (en) Image composition method and apparatus
CN100561517C (en) Method and system for viewing and enhancing images
KR102145220B1 (en) Method and apparatus for convert two-dimensional image to three-dimensional image utilizing deep learning
CN112468796B (en) Method, system and equipment for generating fixation point
WO2012015020A1 (en) Method and device for image enhancement
JP3947132B2 (en) Image composition display method, image composition display program, and recording medium recording this image composition display program
US20030090494A1 (en) Image processing apparatus and image processing program
JP4828479B2 (en) Composite image generation apparatus and composite image generation program
US20230030247A1 (en) Method of asynchronous reprojection of an image of a 3d scene
JP4323910B2 (en) Image composition apparatus and method
CN111583163B (en) AR-based face image processing method, device, equipment and storage medium
JP2022064148A (en) Image processing apparatus and image processing method
JP2016201771A (en) Image processing device, image processing method and program
JP2000201298A (en) Image processor, image processing method and providing medium
JP5713256B2 (en) Image processing apparatus, imaging apparatus, and image processing program
KR101864454B1 (en) Apparatus and method for composing images in an image processing device
JP2025500897A (en) Interactive Motion Blur on Mobile Devices
JP2004240910A (en) Image processor and image processing method
JP2004054635A (en) Picture processor and its method
JP4442586B2 (en) Image processing apparatus and image processing program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100115

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20110525

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20110630

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

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20110801

R150 Certificate of patent or registration of utility model

Ref document number: 4797039

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140805

Year of fee payment: 3

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees