JP2017188071A - Pattern change simulation device, pattern change simulation method and program - Google Patents
Pattern change simulation device, pattern change simulation method and program Download PDFInfo
- Publication number
- JP2017188071A JP2017188071A JP2016240103A JP2016240103A JP2017188071A JP 2017188071 A JP2017188071 A JP 2017188071A JP 2016240103 A JP2016240103 A JP 2016240103A JP 2016240103 A JP2016240103 A JP 2016240103A JP 2017188071 A JP2017188071 A JP 2017188071A
- Authority
- JP
- Japan
- Prior art keywords
- image
- shadow
- target area
- component
- pattern
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Abstract
Description
本発明は、柄替えシミュレーション装置、柄替えシミュレーション方法、及びプログラムに係り、詳細には、衣類等の色や柄を置き換えた画像を生成する技術に関する。 The present invention relates to a pattern change simulation apparatus, a pattern change simulation method, and a program, and more particularly to a technique for generating an image in which a color or a pattern of clothing or the like is replaced.
消費者が衣類を購入する場合、購入前に試着して検討することが多い。しかし、色や柄等のバリエーションが多数存在すると、消費者にとっては試着の手間や時間がかかってしまう。またバリエーションの一部が店舗に品切れしている場合や、WEB上のショッピングサイトを利用する場合等は、注文する前に試着できないことがある。このような問題を回避するために、近年はCG(コンピュータ・グラフィックス)を使用した3Dベースのものを中心に、様々な色柄シミュレーションを行うシステムが開発されている。特許文献1には、撮影された画像から被写体の姿勢情報を算出し、被写体と洋服の特徴部のずれ量から透過度を決定して自然な合成画像を得る手法について記載されている。しかしながら特許文献1の手法は、三次元の体型形状を示す被写体モデルを予め生成しておく等、大掛かりな仕込みを必要とするものであるため手軽に利用できない。
When consumers purchase clothing, they often try it on before buying. However, if there are many variations of colors, patterns, etc., it will take time and effort for consumers to try on. In addition, when some of the variations are out of stock in the store or when using a shopping site on the WEB, it may not be possible to try on before ordering. In order to avoid such a problem, in recent years, a system for performing various color pattern simulations has been developed focusing on a 3D base using CG (computer graphics). Japanese Patent Application Laid-Open No. 2004-151561 describes a method of obtaining a natural composite image by calculating posture information of a subject from a photographed image and determining a transparency from a deviation amount between the subject and a feature part of clothes. However, the method of
実物に近い見え方を実現でき、また衣類のように商品サイクルが短いコンテンツに対する企業側のコンテンツ更新コストを考慮すると、CGベースのものより2D(2次元)の実写画像をベースとしたシミュレーションシステムが要望される。しかし、一般に撮影された2次元の画像(写真等)は、服の領域情報、ライティング、陰影、形状等、画像の合成に必要な各種の情報が含まれない。予め切り抜いた服の素材を元画像に単純にレイヤ合成すると、品質の低い合成画像となってしまうという問題があった。実写画像ベースで高品質な合成画像を生成可能な色柄シミュレーションシステムとしては、例えば、特許文献2がある。特許文献2には2次元の背景画像に対してパースや曲面を有する対象物(カーテン)の画像を簡単な操作で自然な柄の状態に合成する手法について記載されている。
A simulation system based on a 2D (two-dimensional) real image rather than a CG-based one can realize the appearance close to the real thing and consider the content update cost on the enterprise side for content such as clothing that has a short product cycle. Requested. However, generally taken two-dimensional images (such as photographs) do not include various information necessary for image synthesis, such as clothing region information, lighting, shadows, and shapes. There is a problem in that a layered image of clothing material cut out in advance is simply layer-combined with the original image, resulting in a low-quality composite image. For example,
しかしながら、特許文献2の画像合成装置は衣類についても適用可能な技術であるが、前提として、元の画像に対し様々なパラメータ(服の領域のマスク情報や形状情報等)を予めユーザが設定しておく必要がある。よって画像処理やCG等の専門的な知識や作業が必要となり、一般消費者または店舗の店員がその場で撮影した画像に対して直ちにシミュレーションを行うことは困難であった。
However, the image synthesizing apparatus of
本発明は、このような課題に鑑みてなされたもので、各種事前加工や素材制作の作業負担がなく、容易な操作で2次元画像内の対象領域(衣類等)の色や柄を替えることが可能な柄替えシミュレーション装置、柄替えシミュレーション方法、及びプログラムを提供することを目的とする。 The present invention has been made in view of such problems, and does not have the burden of various pre-processing and material production, and can easily change the color and pattern of a target area (clothing, etc.) in a two-dimensional image. An object is to provide a pattern change simulation apparatus, a pattern change simulation method, and a program.
前述した課題を解決するための第1の発明は、色及び柄を構成する素材データを複数記憶する記憶手段と、任意の画像を入力する入力手段と、入力された画像から対象領域を抽出する領域抽出手段と、前記入力された画像から前記対象領域について陰影成分を抽出する陰影分離手段と、前記陰影成分に基づいて前記対象領域の歪み量を算出する歪み量算出手段と、前記素材データを選択する素材選択手段と、選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに前記陰影分離手段により抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成する合成手段と、を備えることを特徴とする柄替えシミュレーション装置である。 A first invention for solving the above-described problem is a storage unit that stores a plurality of material data constituting colors and patterns, an input unit that inputs an arbitrary image, and extracts a target area from the input image. Region extraction means, shadow separation means for extracting a shadow component for the target area from the input image, distortion amount calculation means for calculating a distortion amount of the target area based on the shadow component, and the material data A material selection unit for selecting, a material composite image is generated by mapping the selected material data to the target region based on the amount of distortion, and adding a shadow component extracted by the shadow separation unit to the target region. And a composition changing means for generating a composite image by replacing the generated material composite image with the target area of the input image. A Interview configuration apparatus.
第1の発明によれば、色柄シミュレーション装置は任意の画像が入力されると、入力された画像から対象領域を抽出し、対象領域について陰影成分を抽出し、陰影成分に基づいて対象領域の歪み量を算出する。また、色及び柄を構成する素材データが選択されると、色柄シミュレーション装置は選択された素材データを歪み量に基づいて対象領域にマッピングするとともに抽出した陰影成分を対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を入力された画像の対象領域に置き換えて合成画像を生成する。これにより、画像に対する各種の事前加工や素材制作等の作業を必要としない2次元画像ベースの柄替えシミュレーション装置を提供できる。画像処理やCG等の専門的な知識がない者であっても、簡単な操作で、撮影された2次元画像に対して所望の素材の柄を高精細でリアルに適用した合成画像を生成できる。 According to the first invention, when an arbitrary image is input, the color pattern simulation apparatus extracts a target region from the input image, extracts a shadow component for the target region, and extracts the target region based on the shadow component. The amount of distortion is calculated. In addition, when material data constituting a color and a pattern is selected, the color pattern simulation apparatus maps the selected material data to the target area based on the distortion amount and adds the extracted shadow component to the target area. A material composite image is generated, and the generated material composite image is replaced with a target area of the input image to generate a composite image. As a result, it is possible to provide a two-dimensional image-based pattern change simulation device that does not require various pre-processing or material production for the image. Even a person who does not have specialized knowledge such as image processing or CG can generate a composite image in which a desired material pattern is applied in high definition and realistically to a captured two-dimensional image with a simple operation. .
第1の発明において、前記領域抽出手段は、前記対象領域として前記入力された画像内で着用されている服の領域を抽出することを特徴とすることが望ましい。本発明は各種の事前加工や素材制作等の作業を必要としないため、衣類(服)のように種類が多く商品サイクルが短いコンテンツについて本発明を適用すれば、企業側のコンテンツ更新コストを削減でき、好適である。 In the first invention, it is desirable that the region extracting means extracts a region of clothes worn in the input image as the target region. Since the present invention does not require various kinds of pre-processing or material production work, if the present invention is applied to contents such as clothes that have many types and short product cycles, the content update cost on the company side is reduced. It is possible and suitable.
第1の発明において、陰影分離手段は、入力された画像を柄無し反射率成分、柄成分、及び陰影成分に分離することにより前記入力された画像から陰影成分を抽出することが望ましい。また陰影分離手段は、入力された画像を色空間及び画像空間においてクラスタリングし、前記入力された画像から柄情報を抽出し、クラスタリングされたクラスタについて陰影成分を求めるための方程式を前記柄情報に基づいて生成し、前記方程式を解くことにより対象領域の画像から陰影成分を抽出することが望ましい。更に、前記方程式は、柄無し反射率成分に関する制約式、前記柄情報に対する制限を含む陰影成分に関する制約式、及び陰影成分の正規化に関する制約式を含むことが望ましい。ここで、陰影成分に関する制約式は、隣接する画素の陰影成分がなだらかに変化し近傍画素は近いシェーディング値を持つものとし、かつ、柄として抽出された画素については当該制約から除外する。このように柄についての制約を加えることにより、服のように陰影や柄が複雑に混在した画像についても陰影成分(シェーディング)をより正確に分離抽出することが可能となる。その結果、より自然な合成画像を生成できるようになる。 In the first invention, it is desirable that the shadow separating means extracts the shadow component from the input image by separating the input image into a patternless reflectance component, a pattern component, and a shadow component. Further, the shadow separating means clusters the input image in a color space and an image space, extracts pattern information from the input image, and based on the pattern information, an equation for obtaining a shadow component for the clustered cluster It is desirable to extract the shadow component from the image of the target region by generating the image and solving the equation. Furthermore, it is preferable that the equation includes a constraint equation regarding a patternless reflectance component, a constraint equation regarding a shadow component including a restriction on the pattern information, and a constraint equation regarding normalization of the shadow component. Here, the constraint equation related to the shadow component assumes that the shadow component of an adjacent pixel changes gently, neighboring pixels have close shading values, and pixels extracted as a pattern are excluded from the constraint. By adding the restrictions on the pattern in this way, it is possible to more accurately separate and extract the shadow component (shading) even for an image in which shadows and patterns are mixedly mixed like clothes. As a result, a more natural composite image can be generated.
また、前記歪み量算出手段は、前記陰影成分から推定される画像輝度の勾配情報に基づき前記対象領域の法線を復元し、法線に基づき前記歪み量を算出することが望ましい。これらにより、柄替えシミュレーション装置が自動で画像から陰影を分離したり歪み量を算出したりできるため、画像に対する事前の各種パラメータ設定等の作業が不要となる。 Further, it is preferable that the distortion amount calculating means restores a normal line of the target region based on gradient information of image luminance estimated from the shadow component, and calculates the distortion amount based on the normal line. As a result, the pattern change simulation apparatus can automatically separate the shadow from the image and calculate the amount of distortion, so that work such as setting various parameters in advance for the image becomes unnecessary.
第2の発明は、色及び柄を構成する素材データを複数記憶する記憶部を有するコンピュータの制御部が、任意の画像を入力するステップと、入力された画像から対象領域を抽出するステップと、前記入力された画像から前記対象領域について陰影成分を抽出するステップと、前記陰影成分に基づいて前記対象領域の歪み量を算出するステップと、前記素材データを選択するステップと、選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成するステップと、を含むことを特徴とする柄替えシミュレーション方法である。 The second aspect of the invention is a control unit of a computer having a storage unit that stores a plurality of material data constituting colors and patterns, a step of inputting an arbitrary image, a step of extracting a target region from the input image, Extracting a shadow component for the target region from the input image, calculating a distortion amount of the target region based on the shadow component, selecting the material data, and selected material data A material composite image is generated by mapping the extracted shadow component to the target region and mapping the generated material composite image to the target region of the input image. And a step of generating a composite image by replacing the pattern.
第2の発明によれば、色及び柄を構成する素材データを複数記憶する記憶部を有するコンピュータに任意の画像を入力すると、コンピュータの制御部は、入力された画像から対象領域を抽出し、対象領域について陰影成分を抽出し、陰影成分に基づいて対象領域の歪み量を算出する。また、制御部は素材データが選択されると、選択された素材データを歪み量に基づいて対象領域にマッピングするとともに抽出した陰影成分を対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を入力された画像の対象領域に置き換えて合成画像を生成する。これにより、画像に対する各種の事前加工や素材制作等の作業を必要としない2次元画像ベースの柄替えシミュレーション装置を提供できる。画像処理やCG等の専門的な知識がない者であっても、撮影された2次元画像に対して所望の素材の柄を高精細でリアルに適用した合成画像を生成できる。 According to the second invention, when an arbitrary image is input to a computer having a storage unit that stores a plurality of material data constituting colors and patterns, the control unit of the computer extracts a target area from the input image, A shadow component is extracted for the target area, and a distortion amount of the target area is calculated based on the shadow component. In addition, when the material data is selected, the control unit generates the material composite image by mapping the selected material data to the target area based on the amount of distortion and adding the extracted shadow component to the target area. The composite material image is generated by replacing the material composite image with the target area of the input image. As a result, it is possible to provide a two-dimensional image-based pattern change simulation device that does not require various pre-processing or material production for the image. Even a person who does not have specialized knowledge such as image processing or CG can generate a composite image in which a pattern of a desired material is applied to a photographed two-dimensional image with high definition and reality.
第3の発明は、コンピュータを、色及び柄を構成する素材データを複数記憶する記憶手段と、任意の画像を入力する入力手段と、入力された画像から対象領域を抽出する領域抽出手段と、前記入力された画像から前記対象領域について陰影成分を抽出する陰影分離手段と、前記陰影成分に基づいて前記対象領域の歪み量を算出する歪み量算出手段と、前記素材データの選択を受け付ける素材選択手段と、選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに前記陰影分離手段により抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成する合成手段、として機能させるためのプログラムである。 The third invention is a storage means for storing a plurality of material data constituting colors and patterns, an input means for inputting an arbitrary image, an area extraction means for extracting a target area from the input image, Shadow separation means for extracting a shadow component for the target area from the input image, distortion amount calculating means for calculating a distortion amount of the target area based on the shadow component, and material selection for receiving selection of the material data And a material composition image generated by mapping the selected material data to the target area based on the amount of distortion and adding a shadow component extracted by the shadow separation means to the target area, A program for causing a composite image to function as a compositing unit that generates a composite image by replacing the composite image with the target area of the input image
第3の発明によれば、コンピュータを第1の発明の柄替えシミュレーション装置として機能させることが可能となる。 According to the third invention, it is possible to cause the computer to function as the pattern change simulation device of the first invention.
本発明により、各種事前加工や素材制作の作業負担がなく、容易な操作で2次元画像内の対象領域の色や柄を替えることが可能な柄替えシミュレーション装置、柄替えシミュレーション方法、及びプログラムを提供できる。 According to the present invention, there is provided a pattern change simulation apparatus, a pattern change simulation method, and a program capable of changing the color and pattern of a target area in a two-dimensional image with an easy operation without any burden of various pre-processing and material production. Can be provided.
以下、図面に基づいて本発明の実施形態を詳細に説明する。図1は、柄替えシミュレーション装置1のハードウェア構成を示すブロック図である。なお、図1のハードウェア構成は一例であり、用途、目的に応じて様々な構成を採ることが可能である。
Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings. FIG. 1 is a block diagram illustrating a hardware configuration of the pattern
図1に示すように、柄替えシミュレーション装置1は、制御部11、記憶部12、メディア入出力部13、通信制御部14、入力部15、表示部16、周辺機器I/F部17等が、バス18を介して接続される。
As shown in FIG. 1, the pattern
制御部11は、CPU(Central Processing Unit)、ROM(Read Only Memory)、RAM(Random Access Memory)等によって構成される。CPUは、記憶部12、ROM、記録媒体等に格納されるプログラムをRAM上のワークメモリ領域に呼び出して実行し、バス18を介して接続された各装置を駆動制御し、柄替えシミュレーション装置1が行う後述する処理を実現する。ROMは、不揮発性メモリであり、コンピュータのブートプログラムやBIOS等のプログラム、データ等を恒久的に保持している。RAMは、揮発性メモリであり、記憶部12、ROM、記録媒体等からロードしたプログラム、データ等を一時的に保持するとともに、制御部11が各種処理を行う為に使用するワークエリアを備える。
The
記憶部12は、HDD(Hard Disk Drive)等であり、制御部11が実行するプログラム、プログラム実行に必要なデータ、OS(Operating System)等が格納される。プログラムに関しては、OSに相当する制御プログラムや、後述する処理をコンピュータに実行させるためのアプリケーションプログラムが格納されている。これらの各プログラムコードは、制御部11により必要に応じて読み出されてRAMに移され、CPUに読み出されて各種の手段として実行される。
The
メディア入出力部13(ドライブ装置)は、データの入出力を行い、例えば、CDドライブ(−ROM、−R、−RW等)、DVDドライブ(−ROM、−R、−RW等)等のメディア入出力装置を有する。通信制御部14は、通信制御装置、通信ポート等を有し、コンピュータとネットワーク間の通信を媒介する通信インタフェースであり、ネットワークを介して、他のコンピュータ間との通信制御を行う。ネットワークは、有線、無線を問わない。
The media input / output unit 13 (drive device) inputs / outputs data, for example, media such as a CD drive (-ROM, -R, -RW, etc.), DVD drive (-ROM, -R, -RW, etc.) Has input / output devices. The
入力部15は、データの入力を行い、例えば、キーボード、マウス等のポインティングデバイス、テンキー等の入力装置を有する。入力部15を介して、コンピュータに対して、操作指示、動作指示、データ入力等を行うことができる。表示部16は、液晶パネル等のディスプレイ装置、ディスプレイ装置と連携してコンピュータのビデオ機能を実現するための論理回路等(ビデオアダプタ等)を有する。なお、入力部15及び表示部16は、タッチパネルディスプレイのように、一体となっていてもよい。
The
周辺機器I/F(Interface)部17は、コンピュータに周辺機器を接続させるためのポートであり、周辺機器I/F部17を介してコンピュータは周辺機器とのデータの送受信を行う。周辺機器I/F部17は、USB(Universal Serial Bus)やIEEE1394やRS−232C等によって構成されており、通常複数の周辺機器I/Fを有する。周辺機器との接続形態は有線、無線を問わない。バス18は、各装置間の制御信号、データ信号等の授受を媒介する経路である。
The peripheral device I / F (Interface)
柄替えシミュレーション装置1は、1台のコンピュータで構成されてもよいし、複数のコンピュータがネットワークを介して構成されてもよい。例えば、柄替えシミュレーション装置1が、サーバとクライアント端末で構成される場合、クライアント端末においてデータの入力を受け付けて、サーバが各種の処理を行い、クライアント端末が処理結果を表示するようにしてもよい。以下の説明では、簡素な構成例として、柄替えシミュレーション装置1が1台のコンピュータで構成された例を説明する。
The pattern
次に、図2を参照して本発明に係る柄替えシミュレーション装置1の機能構成について説明する。
Next, the functional configuration of the pattern
図2に示すように、柄替えシミュレーション装置1の制御部11は、画像入力部21、領域抽出部22、陰影分離部23、歪み量算出部(テクスチャ座標生成部)24、素材選択部26、テクスチャマッピング・陰影合成部27、画像出力部28を有する。また、柄替えシミュレーション装置1の記憶部12には、素材データ5が記憶される。
As shown in FIG. 2, the
まず図3を参照して柄替えシミュレーション装置1の記憶部12に記憶される素材データ5について説明する。図3に示すように、柄替えシミュレーション装置1の記憶部12には、素材データ5として複数の素材画像5a、5b、5c、…が記憶される。素材画像5a、5b、5c、…は、1単位分の色や柄(テクスチャ)を表すパッチ画像である。各素材画像5a、5b、5c、…には、それぞれ高さ及び幅のサイズを示すサイズ情報が紐づけて格納される。素材画像5a、5b、5c、…及びサイズ情報は、家具やインテリアのカタログデータから取得してもよいし、ユーザが入力部15等を介して登録してもよい。
First, the
例えば図3には、「素材1」に関する情報として、植物柄のパッチ画像(素材画像5a)が保持された例が示されている。同様に、「素材2」、「素材3」、…についても、それぞれ色や柄を示す素材画像5b、5c、…が格納される。
For example, FIG. 3 shows an example in which a plant pattern patch image (
次に、図2に示す柄替えシミュレーション装置1の各部について説明する。
画像入力部21は、柄替えシミュレーションの背景画像とする任意の画像の入力を受け付ける。以下の説明では画像入力部21に入力された画像を入力画像31と呼ぶ。入力画像31は、衣類(服)を着用した人物や動物の写真等、2次元の実写画像とする。
Next, each part of the pattern
The
領域抽出部22は、図4に示すマスク画像32のように、画像入力部21により入力された入力画像31から対象領域を抽出する。対象領域は、柄替えシミュレーションを行う対象とする領域であり、例えば、服の領域である。領域抽出部22は、対象領域と対象領域以外の領域を識別する2値のマスク画像32を作成する。なお、入力画像31の服の領域が上衣(ブラウスやシャツ)と下衣(ズボンやスカート)等のように複数ある場合は、複数の領域をそれぞれ識別して抽出してもよい。その場合は、各領域についてそれぞれマスク画像32を作成する。領域抽出部22は、抽出した対象領域を示すマスク画像32を陰影分離部23に出力する。
The
陰影分離部23は、入力画像31の対象領域(マスク画像32により指定された領域)について陰影成分を抽出する。具体的には、図5に示すように陰影分離部23は領域抽出部22から対象領域を表すマスク画像32を取得するとともに画像入力部21から入力画像31を取得する。そして入力画像31の対象領域について後述する陰影分離処理を行い、画像内の各物体から陰影成分を分離する。このとき陰影分離部23は、服の柄を考慮した陰影分離処理を行う。具体的には、入力画像31の対象領域を柄無し反射率成分、柄成分、及び陰影成分に分離することにより入力画像31の対象領域から陰影成分を抽出する。陰影成分は、各画素の陰影の大きさを表す数値で表した画像データ(陰影画像34)として抽出される。陰影分離部23によって分離された陰影成分を入力画像31の対象領域から除いた画像が図5に示すテクスチャ画像33である。テクスチャ画像33と陰影成分(陰影画像34)とは、理論上、乗算すると元の入力画像31と一致する。なお、テクスチャ画像33は柄無し反射率成分と柄成分(服の模様)とを含むものである。テクスチャ・陰影分離処理の具体的な処理の流れについては後述する(図9〜図18)。陰影分離部23は、分離抽出した陰影成分を表す陰影画像34を歪み量算出部(テクスチャ座標生成部)24へ出力する。
The
歪み量算出部(テクスチャ座標生成部)24は、図6に示すように、陰影分離部23により分離された陰影画像34と対象領域を表すマスク画像32とを取得し、対象領域の歪み量を算出する。算出した歪み量はテクスチャ座標35(格子状のグリッド)に反映される。歪み量は、身体の凹凸や姿勢、服のしわ等により生じる面の歪みを表すものである。テクスチャ座標35は縦横の線で画像を複数の区画に区分したグリッド(格子)であり、各区画の歪み量に応じて該当区画を変形させて表したものである。歪み量は陰影画像34に基づいて推定される。歪み量の算出手法については後述する。
As shown in FIG. 6, the distortion amount calculation unit (texture coordinate generation unit) 24 acquires the
素材選択部26は、記憶部12に記憶されている素材データ5の中から対象領域に適用する素材データ5を選択する。選択された素材データ5を選択素材画像36と呼ぶ。
The
テクスチャマッピング・陰影合成部27は、図7に示すように素材選択部26により選択された素材データ5(選択素材画像36)を歪み量(テクスチャ座標35)に基づいて変形して入力画像31の対象領域にマッピングする。また、陰影分離部23により抽出した陰影成分(陰影画像34)を対象領域に付与(乗算)する。これにより対象領域に選択素材画像36が合成された素材合成画像を生成する。また、生成した素材合成画像を入力画像31の対象領域に置き換えて合成画像4を生成する。
The texture mapping /
画像出力部28は、テクスチャマッピング・陰影合成部27により生成された合成画像4を出力する。出力は、表示部16への表示、記憶部12への記憶の他、通信制御部14を介したネットワーク等への送信等を含む。
The
次に、図8を参照して、柄替えシミュレーション装置1の制御部11が実行する柄替えシミュレーション処理の流れを説明する。
Next, with reference to FIG. 8, the flow of the pattern change simulation process which the
まず、制御部11はシミュレーションを行う画像の入力を受け付ける(ステップS101)。一例として、入力画像31は服を着た人物等を撮影した2次元の画像とするが、人物に限らず、動物やマネキン等でもよい。次に制御部11は、入力画像31に対して、エッジ抽出処理やセグメンテーション・ラベリング処理を実行し、色や柄の変更を適用する対象領域である服の領域と、対象領域(服)以外の領域を識別する2値(対象領域が「白」、非対象領域が「黒」)のマスク画像32を作成する(ステップS102)。なお、ステップS102におけるラベリング処理において、制御部11は、まず非対象領域(背景や手、足、頭等)が「黒」、対象領域(服の領域)が「白」、不確定領域が「灰色」の3色のラベル画像であるトライマップ画像を生成し、次に、制御部11は不確定領域を「黒」か「白」のいずれかに決定して2値のマスク画像32を生成するようにしてもよい。不確定領域については、例えば最小コスト切断問題(Graph Cut;グラフカット)として定式化し、「黒」か「白」かを決定する方法が挙げられる。このグラフカットの手法では、灰色の領域(不確定領域)内の画素を基点として、隣接する複数の前景領域及び背景領域の画素との類似度を用いた最少コスト切断問題として定式化し、最もコストが小さくなる切断軌跡を求め、切断軌跡に基づいて不確定領域を「黒」か「白」のいずれかに決定する。なお、ステップS102の領域抽出処理はこの手法に限定されず、入力画像31から対象領域を抽出できるものであればどのような技術を用いてもよい。
First, the
制御部11は、入力画像31からステップS102で抽出された対象領域(マスク画像32の「白」領域)について、陰影成分を分離する(ステップS103)。例えば、“Intrinsic images in the wild(SIGGRAPH2014)”等に具体的な演算手法が開示されている。この手法は、主にシーン画像を対象として、対象の画像を固有反射率(テクスチャ)と陰影成分に分離する方法であり、以下の先見知識(A)〜(F)を利用し、
The
I(入力)=R(反射率)×S(陰影) I (input) = R (reflectance) × S (shadow)
の不良設定問題を同じ反射率セグメントによるグラフィカルモデル問題とシェーディングの滑らかさによる最適化問題に置き換えることで解くものである。 This problem is solved by replacing the defect setting problem with a graphical model problem with the same reflectance segment and an optimization problem with the smoothness of shading.
上述の先見知識としては、例えば以下のものを利用する。
(A)近くにある同じ色度や輝度を持つ画素は、ほとんど似たような反射率を含む。
(B)反射率は区分的定数である。
(C)反射率は、スパースセットからサンプルされる。
(D)特定のシェーディングの値は、他のものよりも推測できる可能性が高い。
(E)近傍ピクセルは似たようなシェーディング値を持つ。
(F)シェーディングはグレースケール、または光源と同じ色である。
As the above-mentioned foresight knowledge, for example, the following is used.
(A) Pixels having the same chromaticity and brightness in the vicinity include almost similar reflectances.
(B) The reflectance is a piecewise constant.
(C) The reflectance is sampled from a sparse set.
(D) A specific shading value is more likely to be inferred than others.
(E) Neighboring pixels have similar shading values.
(F) Shading is grayscale or the same color as the light source.
上述の手法は、シーン画像を対象とするものであるため、服のように柄やシワのあるものに適用した場合に常に良好な結果が得られるものではない。そこで、本実施の形態では、柄のある服への適用を考慮した陰影分離処理を実施する。以下、柄を考慮した陰影分離処理について図9〜図18を参照して説明する。 Since the above-mentioned method is intended for a scene image, a good result cannot always be obtained when applied to a pattern or wrinkle such as clothes. Therefore, in the present embodiment, shadow separation processing is performed in consideration of application to patterned clothes. Hereinafter, the shadow separation process considering the pattern will be described with reference to FIGS.
図9は、柄を考慮した陰影分離処理の手順を示すフローチャートである。
制御部11(陰影分離部23)は、入力画像31の対象領域(マスク画像32により指定された領域)について陰影成分を抽出する。図5に示すように陰影分離部23は領域抽出部22から対象領域を表すマスク画像32を取得するとともに画像入力部21から入力画像31を取得し、マスク処理により入力画像31から陰影分離処理の対象とする領域(以下、対象領域という)を取得する(ステップS201)。
FIG. 9 is a flowchart showing the procedure of the shadow separation process considering the pattern.
The control unit 11 (shadow separation unit 23) extracts a shadow component for a target region (region specified by the mask image 32) of the
次に、制御部11は、対象領域について色空間クラスタリング処理を行い(ステップS202)、色空間クラスタリング処理で求めた色空間クラスタを初期値として画像空間クラスタリング処理を実施する(ステップS202、ステップS203)。クラスタリングの精度を向上させるためには、例えば、画像空間クラスタリング処理においてDense CRF(conditional random field;条件付き確率場)という手法を用いることが望ましい。
Next, the
図10は、ステップS202の色空間クラスタリング処理の概要を示す図である。色空間クラスタリング処理において、制御部11は入力画像31の対象領域を以下の式(1)に示すように3次元色空間61に変換する。
FIG. 10 is a diagram showing an outline of the color space clustering process in step S202. In the color space clustering process, the
そして制御部11は、3次元色空間61上で、k−meansを行い、K個の色空間クラスタ[CC1〜CCK]を算出する。
Then, the
次に、制御部11は、ステップS202の色空間クラスタリング処理で求めた色空間クラスタ[CC1〜CCK]を初期値として、画像空間クラスタリング処理を実施する。この画像空間クラスタリング処理では、例えばDenseCRFの推論を行ってDenseCRFクラスタ[Cd1〜CdK]を求めた後、ラベリング処理を行って画像空間クラスタ[C0_1〜C0_N0]を求める。
Next, the
DenseCRFの推論モデルは、以下の式(2)〜式(4)である(V Koltun 2011,2013)。 The inference model of DenseCRF is the following formulas (2) to (4) (V Koltun 2011, 2013).
制御部11は、上述の式(2)のUnary項とPairwise項とを設定し、DenseCRFの推論(平均場近似+近似フィルタリング)を行い、クラスタを求める。なお、上述の式(3)、式(4)において、fiは任意の特徴空間、k(m)はm個のガウシアンカーネル、w(m)はそれぞれの重み、μ(xi,xj)は、ラベル一貫性を表すCompatibility Functionモデル(パラメータ)である。
The
式(2)のPairwise項については、特徴の距離が離れているところでクラスタを区切ることを目的として設定する。
具体的には、DenseCRFによるクラスタを構成する変数をxiと置き、特徴を以下の式(5)に示すように、5次元ベクトルfiで設定する(位置+色空間クラスタリング特徴)。
The Pairwise term in Equation (2) is set for the purpose of dividing the cluster where the feature distance is far away.
Specifically, placing the variable in the cluster by DenseCRF and x i, characterized as shown in the following equation (5), set by the five-dimensional vector f i (position + color space clustering feature).
また、Compatibility Functionは、クラスタリング代表値のL1距離とする、対角成分が0である対象行列として設定する。すなわち、Cd1〜CdKを、Cd(x1)〜Cd(xi)〜Cd(xK)と置き、以下の式(6)のように設定する。 In addition, the compatibility function is set as an object matrix whose diagonal component is 0, which is the L1 distance of the clustering representative value. That is, C d1 to C dK are set as C d (x 1 ) to C d (x i ) to C d (x K ), and are set as in the following formula (6).
式(2)のUnary項については、(a)色空間クラスタの事前知識、(b)色空間クラスタのクラスタ色事前知識、(c)擬似シェーディング値の極端な値の抑制を考慮して推論式を設定する。 For the Unary term in equation (2), an inference equation is considered in consideration of (a) prior knowledge of color space clusters, (b) prior knowledge of cluster color of color space clusters, and (c) suppression of extreme values of pseudo-shading values. Set.
(a)色空間クラスタの事前知識について
色空間クラスタの事前知識については、以下の式(7)を設定する。
(A) Prior knowledge of color space clusters For prior knowledge of color space clusters, the following equation (7) is set.
式(7)は、色空間クラスタリングの結果[CC1〜CCK]を初期値としてDense CRFクラスタリングを行った場合、その結果が図12の63aに示すように色空間クラスタリングの結果62がある程度反映されたものであれば、「OK」とすることを表している。例えば、図12に示すように、色空間クラスタリングの結果[CC1〜CCK]の単純なマッピング62を初期値としてDense CRFクラスタリングを行う場合、その結果が図12の63aに示すように色空間クラスタリングの結果62がある程度反映されたものであれば「OK」とし、図12の63bのように色空間クラスタリング結果62が反映されないものであれば、「NG」とする。
In Expression (7), when dense CRF clustering is performed using the color space clustering result [CC 1 to CC K ] as an initial value, the result reflects the color
(b)色空間クラスタのクラスタ色事前知識の反映について
Unary項は、また、色空間クラスタのクラスタ色事前知識を反映させる。具体的には、各画素値が、色空間クラスタの各クラスタの代表値の画素値に近いものとなるようにする。これを以下の式(8)で表す。
(B) Reflecting cluster color prior knowledge of color space clusters
The Unary term also reflects cluster color prior knowledge of the color space cluster. Specifically, each pixel value is set to be close to the representative pixel value of each cluster in the color space cluster. This is expressed by the following formula (8).
式(8)は図13に示すように、色空間クラスタ[CC1〜CCK]の単純なマッピング62を初期値とする場合、DenseCRFクラスタリング結果が図13の63cのように、なるべく色空間クラスタの値に近いようにするものである。
As shown in FIG. 13, when the
(c)擬似シェーディング値の極端な値の抑制について
また、Unary項は、擬似シェーディング値の極端な値を抑制するよう設定する。色空間クラスタの各クラスタの代表値の画素値を擬似的な反射率と仮定する。これは、明るさの観点から、中央値を持っていることが多いからである。擬似的なシェーディング値を(入力値/擬似反射率)から求め、その値が極端な値をとらないようにする(定数を引いた和をコストとする)。これを式で表すと、以下の式(9)、(10)で表される。
(C) About suppression of extreme value of pseudo-shading value The Unary term is set to suppress the extreme value of pseudo-shading value. It is assumed that the representative pixel value of each cluster in the color space cluster is a pseudo reflectance. This is because it often has a median value from the viewpoint of brightness. A pseudo shading value is obtained from (input value / pseudo-reflectance) so that the value does not take an extreme value (the sum obtained by subtracting a constant is regarded as a cost). This is expressed by the following formulas (9) and (10).
上述の3つのUnary項(ΨU1(xi)、ΨU2(xi)、ΨU3(xi)、)にそれぞれ重みパラメータをかけて、式(11)に示すように全体のUnary項ΨU(x)を設定する。 Each of the above three Unary terms (Ψ U1 (x i ), Ψ U2 (x i ), Ψ U3 (x i ))) is multiplied by a weight parameter, and the entire Unary term Ψ as shown in Expression (11). Set U (x).
以上説明したような推論により制御部11は上述の推論式(2)を設定し、画像空間クラスタリング結果を得る。なお、本実施の形態では、精度の良いクラスタリング処理の最も好適な一例としてDenseCRFを用いているが、本発明はこれに限定されず、任意の手法のクラスタリング処理を実施するものとしてもよい。
Based on the inference as described above, the
図9の説明に戻る。
クラスタリング処理が終了すると、制御部11は、元の画像(ステップS201でマスク処理した入力画像31の対象領域)から柄情報を抽出する(ステップS204)。柄情報の抽出にはエッジフィルタを用いる。服の柄を抽出するには、例えばCannyのエッジフィルタが好適である。服の画像には柄やシワが複雑に混在するため、通常、柄のみを精度よく検出するのは困難であるが、Cannyのエッジフィルタはフィルタの強弱等のパラメータ設定が容易であるため、本発明の対象とする服の柄の抽出に対して扱いやすく好適である。
Returning to the description of FIG.
When the clustering process ends, the
次に、制御部11は、ステップS203でクラスタリングされた各クラスタの陰影成分を求めるための制約式を設定し線形方程式を構築する(ステップS205)。線形方程式は、以下の先見的知識に基づき、不良設定問題を解くための制約式から設定される。
Next, the
具体的には、以下の制約を用いる。
(A)リフレクタンス制約(柄無し反射率成分に関する制約)
・リフレクタンスは、区分的定数であり、近くにある、同じ色度を持つ画素は、同じリフレクタンスである。
・リフレクタンスはスパースセットからサンプルされる。
(B)シェーディング制約(柄情報に対する制限を含む陰影成分に関する制約)
・シェーディングは滑らかに変化し、近傍ピクセルは近いシェーディング値を持つ。
・柄(エッジ)については滑らかさの考慮から除外する。
(C)シェーディング正規化制約(陰影成分の正規化に関する制約)
・すべての場合のシェーディングの量を統一する。
Specifically, the following constraints are used.
(A) Reflectance restriction (restriction on patternless reflectance component)
Reflectance is a piecewise constant, and nearby pixels with the same chromaticity have the same reflectance.
• Reflectance is sampled from a sparse set.
(B) Shading restrictions (constraints on shadow components including restrictions on pattern information)
• Shading changes smoothly and neighboring pixels have close shading values.
-Handles (edges) are excluded from consideration of smoothness.
(C) Shading normalization constraint (constraint on shading component normalization)
• Unify the amount of shading in all cases.
入力画素値Iと陰影成分S(シェーディング)と反射率(リフレクタンス)Rとの関係は、一般に、図15(a)に示すような関係で表される。これを式で表すと、以下の式(12)となる。 The relationship among the input pixel value I, the shadow component S (shading), and the reflectance (reflectance) R is generally represented by a relationship as shown in FIG. This is expressed by the following expression (12).
I(入力画素値)=S(陰影)×R(反射率)・・・(12) I (input pixel value) = S (shadow) × R (reflectance) (12)
また図15(b)に示すように、シェーディング値Sは、画素値Iを示すグラフの傾き(Sfi)と定数(Sc)を掛け合わせたものである。 As shown in FIG. 15B, the shading value S is obtained by multiplying the slope (Sfi) of the graph indicating the pixel value I by a constant (Sc).
I(入力画素値)=(Sfi×Sc)×R・・・(13) I (input pixel value) = (Sfi × Sc) × R (13)
制御部11は、画像空間クラスタC1〜CNについて、各クラスタのシェーディング係数Sfiについての制約式を生成する。そして、シェーディング係数Sfiを求めた後、シェーディング値Sを求め、入力画素値Iをシェーディング値Sで割ることでリフレクタンスR(反射率)を求める。
The
以下、各制約式について説明する。
(A)リフレクタンス制約
色空間クラスタリング(k−means)時のクラスタリング結果が等しいクラスタは、リフレクタンスが同じはずである。これを式にすると、以下の式(14)で表される。
Hereinafter, each constraint equation will be described.
(A) Reflectance constraint Clusters having the same clustering result in color space clustering (k-means) should have the same reflectance. If this is made into a formula, it is expressed by the following formula (14).
例えば、図16(a)に示すように、色空間クラスタリング結果62と画像空間クラスタリング結果65とを比較すると、画像空間クラスタリング結果65におけるクラスタC4(図中「4」で示す)とクラスタC3(図中「3」で示す)とは、色クラスタが同じである。つまり、画像空間クラスタリング結果65におけるクラスタC3とクラスタC4とはリフレクタンスRが同じはずである。切断面70を横軸、入力画像の画素値Iを縦軸とすると、切断面70において隣接するクラスタC4、C2、C3の各画素値Iは図16(b)に示すように表される。つまり、クラスタC4とクラスタC3とは同じリフレクタンスRであり、クラスタC2は色クラスタが異なるためクラスタC4とクラスタC3とは異なるリフレクタンスRを持つものとする。
For example, as shown in FIG. 16A, when the color
(B)シェーディング制約
シェーディングSは滑らかに変化するので、隣接するクラスタの境界は、シェーディング係数Sfiの値が同じはずである。これを式にすると、以下の式(15)で表される。
(B) Shading constraint Since the shading S changes smoothly, the value of the shading coefficient Sfi should be the same at the boundary between adjacent clusters. If this is made into a formula, it is expressed by the following formula (15).
例えば、図16(b)に示すように、切断面70において隣接する3つのクラスタC4、C2、C3は、シェーディングが滑らかに変化する。よって各クラスタC4、C2、C3の境界のシェーディング値は等しくなるはずである。シェーディングの部分をつなげると、図16(c)に示すようになるものとする。 For example, as shown in FIG. 16B, the shading of three clusters C4, C2, and C3 adjacent to each other on the cut surface 70 changes smoothly. Therefore, the shading values at the boundaries of the clusters C4, C2, and C3 should be equal. When the shading portions are connected, it is as shown in FIG.
また、隣接するクラスタの中間のクラスタが柄(エッジ)の場合、シェーディングの連結のノイズになることが多い。そのため柄についてはシェーディングの滑らかさの考慮から除外する。その場合は、中間クラスタを介して接続する両端のクラスタについてシェーディングの滑らかさを考慮する。これを元に方程式を立てると、以下の式(16)で表される。 In addition, when an intermediate cluster between adjacent clusters is a pattern (edge), it is often a noise of shading connection. Therefore, the pattern is excluded from consideration of the smoothness of shading. In that case, the smoothness of shading is considered for the clusters at both ends connected via the intermediate cluster. When an equation is established based on this, it is expressed by the following equation (16).
例えば、図17(a)に示す画像空間クラスタリング結果65aのように柄80が含まれる場合、切断面70では、クラスタC4、「柄(エッジ)」、C3の各画素値Iは図17(b)のように表される。この場合、「柄」は除外し、その両隣のクラスタC4とC3について、シェーディングが滑らかに変化すると考える。シェーディングをつなげると図17(c)に示すようになるはずである。
For example, when the
(C)シェーディング正規化制約(陰影成分の正規化に関する制約)
全体のシェーディングの量を統一する。具体的には、図18に示すように、全てのシェーディング係数Sfiの対数を総和すると「0」となるように、シェーディング係数Sfiを求める。これを元に式を立てると、以下の式(17)で表される。
(C) Shading normalization constraint (constraint on shading component normalization)
Unify the overall amount of shading. Specifically, as shown in FIG. 18, the shading coefficient Sfi is obtained so that the sum of the logarithms of all the shading coefficients Sfi is “0”. Based on this, the following equation (17) is established.
このようにして、各制約に基づく方程式が制約式として設定される。制御部11は、設定した制約式(14)、(15)、(16)、(17)から、
A・x=B
の形の線形方程式を構築する。
In this way, an equation based on each constraint is set as a constraint equation. From the set constraint equations (14), (15), (16), and (17), the
A ・ x = B
Construct a linear equation of the form
次に制御部11は、ステップS205で構築した線形方程式を解く(ステップS206)。これを解くことにより、各クラスタCiのシェーディング係数Sfi(Ci)が求められる。線形方程式は、例えばQMR法を用いることにより高速に結果を得られるが、これに限定されず、どのような解法を用いてもよい。
Next, the
以上のようにして、各クラスタC1〜Cnのシェーディング係数Sfiが求められる。シェーディング係数Sfiに所定の定数Scを掛けることによりシェーディング値S(陰影成分)が求められる。また、上述の式(12)に基づき、入力画素値Iをシェーディング値Sで割ることでリフレクタンスR(柄無し反射率成分)が求められる。 As described above, the shading coefficient Sfi of each of the clusters C 1 to C n is obtained. A shading value S (shadow component) is obtained by multiplying the shading coefficient Sfi by a predetermined constant Sc. Further, the reflectance R (patternless reflectance component) is obtained by dividing the input pixel value I by the shading value S based on the above-described equation (12).
次に、制御部11はステップS103(ステップS201〜ステップS206)の処理により分離された陰影成分を示す画像である陰影画像34に基づいて、対象領域の歪み量を算出し、算出した歪み量を反映したグリッドであるテクスチャ座標35を生成する(ステップS104)。ステップS104において、制御部11は陰影画像34に基づいて、服の領域(マスク画像32の白値の領域)の法線を復元し、復元した法線に基づいて歪み量を推定する。この種の技術としては、例えば、“Textureshop : Texture Synthesis as a Photograph Editing Tool(SIGGRAPH2004)”の手法等が知られている。この手法では、以下の手順でテクスチャ座標35を生成する。
Next, the
(1)画像輝度の勾配情報を元に法線を復元する。
(2)法線を滑らかに並べ、テクスチャの変形射影マトリクスを求める。
(1) The normal is restored based on the gradient information of the image luminance.
(2) The normals are arranged smoothly to obtain a texture deformation projection matrix.
なお、歪み量の算出方法(テクスチャ座標35の生成方法)はこの方法に限定されるものではなく、本発明は、その他の公知の手法を用いてもよい。 Note that the method for calculating the distortion amount (method for generating the texture coordinates 35) is not limited to this method, and other known methods may be used in the present invention.
次に制御部11は、ユーザによる素材データ5の選択を受け付ける(ステップS105)。ステップS105において制御部11は記憶部12に記憶されている素材データ5の素材画像5a、5b、…を読み出し、表示部16に選択可能に一覧表示することが望ましい。入力部15を介してユーザにより素材データ5が選択される。
Next, the
制御部11は、ステップS105で選択された素材データ5(選択素材画像36)をステップS104で生成したテクスチャ座標35にマッピングし、更にステップS103で抽出した陰影画像34を合成(乗算)する(ステップS106)。テクスチャマッピングでは、テクスチャ座標35の歪みに応じて選択素材画像36が変形されて貼り付けられる。このようにして、服の領域に選択された素材画像36が適用される。制御部11は、選択素材画像36が合成された服の領域の画像(素材合成画像)の各画素を元の入力画像31の対応する画素に置き換える。これにより、入力画像31の服(対象領域)の柄が変更された合成画像4が生成される。
The
制御部11は、合成画像4を出力(記憶部12への記憶、表示部16への表示等)し(ステップS107)、一連の柄替えシミュレーションに関する処理を終了する。
The
なお、ステップS107における出力の結果、ユーザが合成画像4を確認し、別の色や柄を試したい場合等は、ステップS105へ戻り素材データ5の再選択を行えば、ステップS102〜ステップS104の結果を利用して選択素材の合成を繰り返し行える。また、服の領域が複数ある場合は、各領域についてそれぞれ陰影分離(ステップS103)、テクスチャ座標生成(ステップS104)、素材選択(ステップS105)を行って、各領域に異なる素材を適用することも可能である。
If the user confirms the
以上説明したように、本発明に係る柄替えシミュレーション装置1によれば、ユーザが所望の入力画像31を入力すると、柄替えシミュレーション装置1により自動で服の領域の抽出、陰影成分の抽出、テクスチャ座標35の生成(服領域の歪み量の算出)を行って、ユーザが選択した所望の素材の柄や色を適用した合成画像4を得ることが可能となる。これにより、事前加工や素材制作の作業負担がなく、容易な操作で任意の写真(2次元画像)内の服の柄を替えることが可能となる。また、単に素材画像を張り付けたものとは異なり、元の写真の陰影や服の歪み等が反映された合成画像4が作成されるため、品質の高い合成画像4を生成することが可能となる。
なお、上述の実施の形態では、柄替えシミュレーションを行う対象領域を服の領域としたが、本発明はこれに限定されず、柄替えシミュレーションの対象領域はどのような対象物としてもよい。例えば、家具やカーテン、壁紙等を対象領域として本発明を適用してもよいし、人物の髪や肌等を対象として本発明を適用してもよい。
As described above, according to the pattern
In the above-described embodiment, the target area for performing the pattern change simulation is the clothes area. However, the present invention is not limited to this, and the target area for the pattern change simulation may be any target object. For example, the present invention may be applied to furniture, curtains, wallpaper, and the like as target areas, or the present invention may be applied to human hair, skin, and the like.
以上、添付図面を参照して、本発明に係る柄替えシミュレーション装置、柄替えシミュレーション方法、及びプログラムの好適な実施形態について説明したが、本発明は係る例に限定されない。当業者であれば、本願で開示した技術的思想の範疇内において、各種の変更例または修正例に想到し得ることは明らかであり、それらについても当然に本発明の技術的範囲に属するものと了解される。 The preferred embodiments of the pattern change simulation device, the pattern change simulation method, and the program according to the present invention have been described above with reference to the accompanying drawings, but the present invention is not limited to such examples. It will be apparent to those skilled in the art that various changes or modifications can be conceived within the scope of the technical idea disclosed in the present application, and these are naturally within the technical scope of the present invention. Understood.
1……………………柄替えシミュレーション装置
11…………………制御部
12…………………記憶部
13…………………メディア入出力部
14…………………通信制御部
15…………………入力部
16…………………表示部
17…………………周辺機器I/F部
18…………………バス
21…………………画像入力部
22…………………領域抽出部
23…………………陰影分離部
24…………………歪み量算出部(テクスチャ座標生成部)
26…………………素材選択部
27…………………テクスチャマッピング・陰影合成部
28…………………画像出力部
31…………………入力画像
32…………………マスク画像
33…………………テクスチャ画像33
34…………………陰影画像
35…………………テクスチャ座標
36…………………選択素材画像
4……………………合成画像
5……………………素材データ
61…………………3次元色空間
62…………………色空間クラスタリング結果
63、63a〜63c…DenseCRFによるクラスタリング結果
64…………………擬似シェーディング値
65…………………画像空間クラスタリング結果
70…………………切断面
80…………………柄(エッジ)
1 …………………… Design
26 ……………………
34 …………………
Claims (9)
任意の画像を入力する入力手段と、
入力された画像から対象領域を抽出する領域抽出手段と、
前記入力された画像から前記対象領域について陰影成分を抽出する陰影分離手段と、
前記陰影成分に基づいて前記対象領域の歪み量を算出する歪み量算出手段と、
前記素材データの選択を受け付ける素材選択手段と、
選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに前記陰影分離手段により抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成する合成手段と、
を備えることを特徴とする柄替えシミュレーション装置。 Storage means for storing a plurality of material data constituting colors and patterns;
An input means for inputting an arbitrary image;
Area extracting means for extracting a target area from the input image;
Shadow separation means for extracting a shadow component for the target area from the input image;
A distortion amount calculating means for calculating a distortion amount of the target region based on the shadow component;
Material selection means for receiving selection of the material data;
The selected material data is mapped to the target area based on the amount of distortion, and a material composite image is generated by adding the shadow component extracted by the shadow separation unit to the target area, and the generated material composite image is Synthesizing means for generating a synthesized image by replacing the input image with the target area;
A pattern change simulation apparatus comprising:
任意の画像を入力するステップと、
入力された画像から対象領域を抽出するステップと、
前記入力された画像から前記対象領域について陰影成分を抽出するステップと、
前記陰影成分に基づいて前記対象領域の歪み量を算出するステップと、
前記素材データの選択を受け付けるステップと、
選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成するステップと、
を含むことを特徴とする柄替えシミュレーション方法。 A control unit of a computer having a storage unit that stores a plurality of material data constituting colors and patterns,
A step of inputting an arbitrary image;
Extracting a target area from the input image;
Extracting a shadow component for the target area from the input image;
Calculating a distortion amount of the target region based on the shadow component;
Receiving a selection of the material data;
The selected material data is mapped to the target area based on the amount of distortion, and a material composite image is generated by adding the extracted shadow component to the target area, and the generated material composite image is input to the input image. Replacing the target area with a composite image;
A pattern change simulation method characterized by comprising:
色及び柄を構成する素材データを複数記憶する記憶手段と、
任意の画像を入力する入力手段と、
入力された画像から対象領域を抽出する領域抽出手段と、
前記入力された画像から前記対象領域について陰影成分を抽出する陰影分離手段と、
前記陰影成分に基づいて前記対象領域の歪み量を算出する歪み量算出手段と、
前記素材データの選択を受け付ける素材選択手段と、
選択された素材データを前記歪み量に基づいて前記対象領域にマッピングするとともに前記陰影分離手段により抽出した陰影成分を前記対象領域に付与することにより素材合成画像を生成し、生成した素材合成画像を前記入力された画像の前記対象領域に置き換えて合成画像を生成する合成手段、
として機能させるためのプログラム。
Computer
Storage means for storing a plurality of material data constituting colors and patterns;
An input means for inputting an arbitrary image;
Area extracting means for extracting a target area from the input image;
Shadow separation means for extracting a shadow component for the target area from the input image;
A distortion amount calculating means for calculating a distortion amount of the target region based on the shadow component;
Material selection means for receiving selection of the material data;
The selected material data is mapped to the target area based on the amount of distortion, and a material composite image is generated by adding the shadow component extracted by the shadow separation unit to the target area, and the generated material composite image is A synthesizing unit that generates a synthesized image by replacing the input image with the target area;
Program to function as.
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2016068458 | 2016-03-30 | ||
JP2016068458 | 2016-03-30 |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2017188071A true JP2017188071A (en) | 2017-10-12 |
JP6891473B2 JP6891473B2 (en) | 2021-06-18 |
Family
ID=60045649
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2016240103A Active JP6891473B2 (en) | 2016-03-30 | 2016-12-12 | Pattern change simulation device, pattern change simulation method, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6891473B2 (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110084826A (en) * | 2018-11-30 | 2019-08-02 | 叠境数字科技(上海)有限公司 | Hair dividing method based on TOF camera |
KR102587288B1 (en) * | 2023-07-10 | 2023-10-10 | 연세대학교 산학협력단 | High-quality Pseudo-label Generation System and Method based on Self-supervised Learning for Training Semantic Segmentation on construction object datasets |
CN116883392A (en) * | 2023-09-05 | 2023-10-13 | 烟台金丝猴食品科技有限公司 | Feeding control method and system based on image processing |
-
2016
- 2016-12-12 JP JP2016240103A patent/JP6891473B2/en active Active
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110084826A (en) * | 2018-11-30 | 2019-08-02 | 叠境数字科技(上海)有限公司 | Hair dividing method based on TOF camera |
CN110084826B (en) * | 2018-11-30 | 2023-09-12 | 叠境数字科技(上海)有限公司 | Hair segmentation method based on TOF camera |
KR102587288B1 (en) * | 2023-07-10 | 2023-10-10 | 연세대학교 산학협력단 | High-quality Pseudo-label Generation System and Method based on Self-supervised Learning for Training Semantic Segmentation on construction object datasets |
CN116883392A (en) * | 2023-09-05 | 2023-10-13 | 烟台金丝猴食品科技有限公司 | Feeding control method and system based on image processing |
CN116883392B (en) * | 2023-09-05 | 2023-11-17 | 烟台金丝猴食品科技有限公司 | Feeding control method and system based on image processing |
Also Published As
Publication number | Publication date |
---|---|
JP6891473B2 (en) | 2021-06-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP7370527B2 (en) | Method and computer program for generating three-dimensional model data of clothing | |
US10796480B2 (en) | Methods of generating personalized 3D head models or 3D body models | |
JP6956252B2 (en) | Facial expression synthesis methods, devices, electronic devices and computer programs | |
US10628666B2 (en) | Cloud server body scan data system | |
US9984409B2 (en) | Systems and methods for generating virtual contexts | |
Yang et al. | Detailed garment recovery from a single-view image | |
JP5299173B2 (en) | Image processing apparatus, image processing method, and program | |
US11195318B2 (en) | Rapid avatar capture and simulation using commodity depth sensors | |
WO2018195485A1 (en) | Systems and methods for automatically creating and animating a photorealistic three-dimensional character from a two-dimensional image | |
KR20180069786A (en) | Method and system for generating an image file of a 3D garment model for a 3D body model | |
CN110663066A (en) | Image processing apparatus, image processing system, image processing method, and program | |
CN109872379A (en) | Data processing equipment and method | |
CN109964255B (en) | 3D printing using 3D video data | |
US8704823B1 (en) | Interactive multi-mesh modeling system | |
US11216998B2 (en) | Jointly editing related objects in a digital image | |
US10650524B2 (en) | Designing effective inter-pixel information flow for natural image matting | |
JP6891473B2 (en) | Pattern change simulation device, pattern change simulation method, and program | |
KR100828935B1 (en) | Method of Image-based Virtual Draping Simulation for Digital Fashion Design | |
JP2016071682A (en) | Object arrangement device, object arrangement method, and program | |
JP5526239B2 (en) | Method, device, and computer-readable medium for generating digital pictures | |
Liao et al. | Illumination animating and editing in a single picture using scene structure estimation | |
WO2018182938A1 (en) | Method and system for wireless ultra-low footprint body scanning | |
Nguyen et al. | High-definition texture reconstruction for 3D image-based modeling | |
CN115761143A (en) | 3D virtual reloading model generation method and device based on 2D image | |
Liu et al. | Animating characters in Chinese painting using two-dimensional skeleton-based deformation |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20191030 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20201127 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20201215 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20210125 |
|
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: 20210427 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20210510 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6891473 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |