JP6700804B2 - Information processing apparatus, information processing method, and program - Google Patents

Information processing apparatus, information processing method, and program Download PDF

Info

Publication number
JP6700804B2
JP6700804B2 JP2016008941A JP2016008941A JP6700804B2 JP 6700804 B2 JP6700804 B2 JP 6700804B2 JP 2016008941 A JP2016008941 A JP 2016008941A JP 2016008941 A JP2016008941 A JP 2016008941A JP 6700804 B2 JP6700804 B2 JP 6700804B2
Authority
JP
Japan
Prior art keywords
color
effective range
color information
information
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.)
Active
Application number
JP2016008941A
Other languages
Japanese (ja)
Other versions
JP2017084319A (en
Inventor
中川 真志
真志 中川
澤田 圭一
圭一 澤田
田中 章文
章文 田中
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to US15/332,985 priority Critical patent/US10445612B2/en
Publication of JP2017084319A publication Critical patent/JP2017084319A/en
Application granted granted Critical
Publication of JP6700804B2 publication Critical patent/JP6700804B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Analysis (AREA)

Description

本発明は、情報処理装置、情報処理方法、およびプログラムに関し、特に、撮像画像における被写体の色を抽出するために用いて好適なものである。   The present invention relates to an information processing device, an information processing method, and a program, and is particularly suitable for use in extracting a color of a subject in a captured image.

現実空間に仮想空間の情報をリアルタイムに重ね合せて利用者に提示する複合現実感に関する技術がある。複合現実感では、ビデオカメラなどの撮像装置によって撮像された現実の映像の全域、または一部に、撮像装置の位置・姿勢に応じた仮想空間の画像(Computer Graphics:CG)を重畳した合成画像を表示する。   There is a technology related to mixed reality in which information in a virtual space is superimposed on a real space in real time and presented to the user. In mixed reality, a composite image in which a virtual space image (Computer Graphics: CG) according to the position/orientation of the image pickup device is superimposed on the whole or a part of the actual image taken by the image pickup device such as a video camera. Is displayed.

現実空間の映像から利用者の手などの領域を抽出することで、現実空間の当該領域とCGとの間の干渉が起こっているか否かの判定や、現実空間の当該領域とCGとの前後関係の判定を行うことができる。以下の説明では、撮像画像における、利用者の手などの被写体の領域を必要に応じて被写体領域と称する。   By extracting a region such as the user's hand from the image in the real space, it is possible to determine whether or not interference occurs between the region in the real space and the CG, and determine whether the region in the real space is in front of or behind the CG. A relationship can be determined. In the following description, a region of a subject such as a user's hand in the captured image will be referred to as a subject region as necessary.

被写体領域を抽出する手法には、領域分割を行う手法や、動的に輪郭を抽出する手法や、学習の結果を用いる手法等がある。何れの手法でも、被写体領域の色(例えば肌色)を抽出することにより、初期の被写体領域を検出することが行われる。このように被写体領域の色を抽出する技術として特許文献1〜3に記載の技術がある。   Methods of extracting the subject area include a method of dividing the area, a method of dynamically extracting the contour, and a method of using the result of learning. In either method, the initial subject area is detected by extracting the color (for example, skin color) of the subject area. Techniques described in Patent Documents 1 to 3 are techniques for extracting the color of the subject region in this manner.

特許文献1には、以下の技術が開示されている。多種多様な人物の肌色データから肌色分布モデルを作成しておく。その後、入力した画像から人物の顔の存在を特定し、特定した顔の領域中の肌色の画素データから肌色分布モデルを作成する。これらの肌色分布モデルを重み付加算して修正肌色分布モデルを作成する。この修正肌色分布モデルを用いて、入力した画像データの各画素に対応する肌色尤度を求める。この肌色尤度と閾値とを比較することによって、入力した画像データの個々の画素データ群に対して肌色であるか否かを判定する。   Patent Literature 1 discloses the following technique. A skin color distribution model is created from skin color data of various people. After that, the presence of a person's face is specified from the input image, and a skin color distribution model is created from the pixel data of the skin color in the specified face area. A modified skin color distribution model is created by weighting and adding these skin color distribution models. Using this modified skin color distribution model, the skin color likelihood corresponding to each pixel of the input image data is obtained. By comparing this skin color likelihood with a threshold value, it is determined whether each pixel data group of the input image data has a skin color.

また、特許文献2には、以下の技術が開示されている。被写体を含まない背景画像と被写体を含む背景画像とのそれぞれから色情報を抽出する。これらの色情報を比較し、被写体を含む背景画像にある色情報のうち、被写体を含まない背景画像にない色情報を、被写体の色情報として登録する。また、被写体領域からユーザーによって指定されたノイズ領域の色情報を調整することで、被写体領域の色の検出精度の向上を図る。   In addition, Patent Document 2 discloses the following technique. Color information is extracted from each of the background image that does not include the subject and the background image that includes the subject. The color information is compared with each other, and among the color information in the background image containing the subject, the color information not in the background image not containing the subject is registered as the color information of the subject. Further, by adjusting the color information of the noise region designated by the user from the subject region, the accuracy of detecting the color of the subject region is improved.

また、特許文献3には、画素位置に応じた色テーブルを作成し、使用する色テーブルを画素ごとに指定し、指定した色テーブルを用いて各画素の色を抽出することが開示されている。   Further, Patent Document 3 discloses that a color table corresponding to a pixel position is created, a color table to be used is designated for each pixel, and a color of each pixel is extracted using the designated color table. ..

特開2007−257087号公報JP, 2007-257087, A 特開2005−228140号公報JP, 2005-228140, A 特許第3118915号公報Japanese Patent No. 3118915

しかしながら、特許文献1、2に記載の技術では、画素の位置によって色味が変わる場合、被写体領域の色を正しく抽出することができない虞がある。例えば、カメラの周辺減光のある撮像画像では、中心部と端部でと輝度や色味が変わる。このため、撮像画像の中心付近のみで色情報を登録すると、画面の端部分において色の未検出が増える。一方、画面全域で色情報を登録すると、色の過検出が増える。   However, in the techniques described in Patent Documents 1 and 2, when the tint changes depending on the position of the pixel, there is a possibility that the color of the subject region may not be correctly extracted. For example, in a captured image with dimming around the camera, the brightness and tint change between the center and the edges. Therefore, if the color information is registered only near the center of the captured image, the number of undetected colors increases at the edge portion of the screen. On the other hand, if color information is registered in the entire screen, color overdetection increases.

一方、特許文献3に記載の技術では、画像の画素毎に色テーブルを作成することで撮像画像の場所によらずに、登録した色を抽出できる。しかしながら、画素毎に複数の色テーブルを作成するので、膨大なメモリが必要になり、実現が容易ではない。
本発明は、このような問題点に鑑みてなされたものであり、撮像画像における被写体領域の色を容易に且つ確実に抽出できるようにすることを目的とする。
On the other hand, in the technique described in Patent Document 3, the registered color can be extracted regardless of the location of the captured image by creating a color table for each pixel of the image. However, since a plurality of color tables are created for each pixel, an enormous memory is required and realization is not easy.
The present invention has been made in view of such a problem, and an object thereof is to make it possible to easily and reliably extract the color of a subject region in a captured image.

本発明の情報処理装置の第1の例は、撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得手段と、前記撮像画像の各画素から抽出される色情報ごとに、前記撮像画像における、前記色情報を有する画素であって、前記指定された領域の内側にある画素の数と、前記色情報を有する画素であって、前記指定された領域の外側にある画素の数の少なくとも一方に基づいて、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲を設定する有効範囲設定手段と、前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定手段により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出手段とを備えることを特徴とする。
本発明の情報処理装置の第2の例は、撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得手段と、前記撮像画像のうち、前記指定された領域に含まれる画素から抽出される色情報ごとに、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲として設定する有効範囲設定手段と、前記有効範囲設定手段により設定された前記有効範囲よりも多い数の新たな有効範囲における色情報を生成する生成手段と、前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定手段により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出手段とを備え、前記生成手段は、前記有効範囲設定手段により設定された前記有効範囲のそれぞれから、当該有効範囲に対応する色情報を代表する1つまたは複数の色を抽出し、抽出した色に基づいて、前記新たな有効範囲における色情報を生成することを特徴とする。
A first example of the information processing apparatus of the present invention includes an acquisition unit that acquires an area designated in a captured image of a subject captured by the imaging unit, and color information extracted from each pixel of the captured image , Of the pixels having the color information in the captured image, the number of pixels inside the designated area, and the number of pixels having the color information outside the designated area. Based on at least one of the numbers, the color information sets an effective range that is effective as the predetermined color in the process of extracting the area of the predetermined color from the image captured by the imaging unit. When the effective range setting means and the color information of each pixel of the image captured by the image capturing means are included in the effective range set for each color information by the effective range setting means at the position of the pixel. And a color area extracting means for extracting the pixel as a part of the area of the predetermined color .
A second example of the information processing apparatus of the present invention is an acquisition unit that acquires a region designated in a captured image of a subject captured by the image capturing unit, and a pixel included in the designated region of the captured image. For each color information extracted from, the color information is set as an effective range that is effective as the predetermined color in the process of extracting the area of the predetermined color from the image captured by the imaging unit. Effective range setting means, generating means for generating color information in a new effective range of a number larger than the effective range set by the effective range setting means, and each pixel of an image captured by the image capturing means. When the color information is included in the effective range set for each color information by the effective range setting means at the position of the pixel, the pixel is extracted as a part of the area of the predetermined color. A color area extracting means, wherein the generating means extracts, from each of the effective ranges set by the effective range setting means, one or more colors representing color information corresponding to the effective range, Color information in the new effective range is generated based on the extracted color.

本発明によれば、撮像画像における被写体領域の色を容易に且つ確実に抽出することができる。   According to the present invention, it is possible to easily and surely extract the color of a subject region in a captured image.

画像処理システムの構成の第1の例を示す図である。It is a figure which shows the 1st example of a structure of an image processing system. 画像処理システムの外観の構成を示す図である。It is a figure which shows the external structure of an image processing system. 肌色登録処理の第1の例を示すフローチャートである。It is a flow chart which shows the 1st example of skin color registration processing. ステップS303の処理の詳細を示すフローチャートである。It is a flow chart which shows details of processing of Step S303. 肌色の画素数の分布と、非肌色の画素数の分布を示す図である。It is a figure which shows the distribution of the pixel number of skin color, and the distribution of the pixel number of non-skin color. 色テーブルを説明する図である。It is a figure explaining a color table. 画像処理システムの構成の第2の例を示す図である。It is a figure which shows the 2nd example of a structure of an image processing system. 撮像位置算出部の処理を示すフローチャートである。It is a flow chart which shows processing of an image pick-up position calculation part. 新たな撮像領域を示す情報の表示例を示す図である。It is a figure which shows the example of a display of the information which shows a new imaging region. 画像処理システムの構成の第3の例を示す図である。It is a figure which shows the 3rd example of a structure of an image processing system. 有効深度取得部の処理を示すフローチャートである。It is a flow chart which shows processing of an effective depth acquisition part. 画像処理システムの構成の第4の例を示す図である。It is a figure which shows the 4th example of a structure of an image processing system. 肌色登録処理の第2の例を示すフローチャートである。It is a flow chart which shows the 2nd example of skin color registration processing. 色情報補間部による色情報の生成処理の例を示すフローチャートである。6 is a flowchart illustrating an example of color information generation processing by a color information interpolating unit. 画面中心からの距離とシェーディング係数の関係を示す図である。It is a figure which shows the relationship from the distance from a screen center, and a shading coefficient. 色情報の有効範囲を模式的に示す図である。It is a figure which shows the effective range of color information typically. 色情報補間部による補間前の色情報を模式的に示す図である。It is a figure which shows typically the color information before interpolation by a color information interpolation part. 色情報補間部による補間処理を示すフローチャートである。It is a flowchart which shows the interpolation process by a color information interpolation part. 色情報補間部による合成処理を示すフローチャートである。7 is a flowchart showing a synthesizing process performed by a color information interpolating unit.

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

(第1の実施形態)
まず、第1の実施形態を説明する。
<構成>
図1は、画像処理システムの構成の一例を示すブロック図である。図2は、本実施形態における画像処理システムの構成の一例を示す模式図である。
図1および図2に示すように、画像処理システムは、撮像部100、入力部200、表示部300、および情報処理装置1000を有する。本実施形態では、撮像部100、入力部200、および表示部300が、情報処理装置1000に通信可能に接続される。また、情報処理装置1000は、撮像部100から撮像画像を取得する。撮像部100は、例えば、ビデオシースルー型HMD(Head Mounted Display)やネットワークカメラにより実現される。入力部200は、マウスやキーボードにより実現される。表示部300は、HMDやPCモニタ等のディスプレイにより実現される。
(First embodiment)
First, the first embodiment will be described.
<Structure>
FIG. 1 is a block diagram showing an example of the configuration of an image processing system. FIG. 2 is a schematic diagram showing an example of the configuration of the image processing system in this embodiment.
As shown in FIGS. 1 and 2, the image processing system includes an imaging unit 100, an input unit 200, a display unit 300, and an information processing device 1000. In the present embodiment, the image capturing unit 100, the input unit 200, and the display unit 300 are communicably connected to the information processing apparatus 1000. The information processing apparatus 1000 also acquires a captured image from the image capturing unit 100. The imaging unit 100 is realized by, for example, a video see-through HMD (Head Mounted Display) or a network camera. The input unit 200 is realized by a mouse or a keyboard. The display unit 300 is realized by a display such as an HMD or a PC monitor.

情報処理装置1000は、図1に示されるように、画像取得部1010、データ記憶部1020、肌色領域設定部1030、画素情報抽出部1040、有効範囲算出部1050、肌色登録部1060、画像処理部1070、および画像出力部1080を有する。
画像取得部1010は、撮像部100で撮像された撮像画像を取得し、取得した画像をデータ記憶部1020に記憶する。撮像画像には、手などの被写体が含まれる。
As shown in FIG. 1, the information processing apparatus 1000 includes an image acquisition unit 1010, a data storage unit 1020, a skin color area setting unit 1030, a pixel information extraction unit 1040, an effective range calculation unit 1050, a skin color registration unit 1060, and an image processing unit. 1070 and an image output unit 1080.
The image acquisition unit 1010 acquires the captured image captured by the imaging unit 100 and stores the acquired image in the data storage unit 1020. The captured image includes a subject such as a hand.

データ記憶部1020は、仮想物体のデータと、画像取得部1010から入力される撮像画像と、肌色登録部1060から入力される色テーブルのデータとを含む情報を記憶する。
肌色領域設定部1030は、入力部200から入力された領域を、肌色の存在する領域として設定する。
The data storage unit 1020 stores information including virtual object data, a captured image input from the image acquisition unit 1010, and color table data input from the skin color registration unit 1060.
The skin color area setting unit 1030 sets the area input from the input unit 200 as the area where the skin color exists.

画素情報抽出部1040は、画像取得部1010で取得された撮像画像から、画素の色情報と画素位置とを抽出する。ここで、色情報とは、CbCrやa*b*など、輝度を含まない色の情報である。輝度に依存しない色の表現方法であれば色情報は限定されない。また、画素位置は、画素の位置を示す情報であり、例えば、画面の中心からの距離で表される。また、画面の領域を複数の小領域に分割した際の各小領域の識別番号で画素位置を表してもよい。画素の領域を識別できれば、どのように画素位置を表してもよい。本実施形態では、画面の中心からの距離が画素位置である場合を例に挙げて説明する。 The pixel information extraction unit 1040 extracts pixel color information and pixel position from the captured image acquired by the image acquisition unit 1010. Here, the color information is information on a color that does not include brightness, such as CbCr or a * b * . Color information is not limited as long as it is a method of expressing a color that does not depend on brightness. The pixel position is information indicating the position of the pixel, and is represented by, for example, the distance from the center of the screen. Further, the pixel position may be represented by the identification number of each small area when the area of the screen is divided into a plurality of small areas. Any pixel position may be represented as long as the pixel region can be identified. In the present embodiment, the case where the distance from the center of the screen is the pixel position will be described as an example.

有効範囲算出部1050は、色情報毎の画素数の分布(画素数と画素位置との関係)を基に、当該色情報が肌色として有効な画像領域(有効範囲)を算出する。例えば、有効範囲算出部1050は、画面の中心からの距離毎に、色情報の出現頻度を導出し、出現頻度が高い距離範囲を、当該色情報が有効な画像領域(有効範囲)とすることを色情報毎に行う。このようにして色情報毎の有効範囲が得られる。以下の説明では、色情報毎の有効範囲を登録するテーブルを必要に応じて色テーブルと称する。   The effective range calculation unit 1050 calculates an image area (effective range) in which the color information is effective as a flesh color based on the distribution of the number of pixels for each color information (relationship between the number of pixels and the pixel position). For example, the effective range calculation unit 1050 derives the appearance frequency of the color information for each distance from the center of the screen, and sets the distance range with high appearance frequency as the image area (effective range) in which the color information is effective. Is performed for each color information. In this way, the effective range for each color information is obtained. In the following description, a table for registering the effective range for each color information is referred to as a color table as needed.

肌色登録部1060は、有効範囲算出部1050で算出されたデータ(各色情報の有効範囲)をデータ記憶部1020(色テーブル)に保存する。
画像処理部1070は、肌色登録部1060により登録された色テーブルを用いて、撮像画像から肌色の領域を抽出する。画像処理部1070は、その抽出の結果を示す情報を、撮像画像に合成して合成画像を生成する。
画像出力部1080は、画像処理部1070で生成された合成画像を表示部300に表示する。
The skin color registration unit 1060 saves the data calculated by the effective range calculation unit 1050 (the effective range of each color information) in the data storage unit 1020 (color table).
The image processing unit 1070 uses the color table registered by the skin color registration unit 1060 to extract a skin color region from the captured image. The image processing unit 1070 combines the information indicating the extraction result with the captured image to generate a combined image.
The image output unit 1080 displays the combined image generated by the image processing unit 1070 on the display unit 300.

<処理の手順>
図3は、情報処理装置1000における肌色登録処理の流れの一例を示すフローチャートである。
ステップS301では、画像取得部1010は、撮像部100で撮像された撮像画像を取得する。画像取得部1010は、例えば、撮像部100で得られた撮像画像を取得するビデオキャプチャーカードを用いることにより実現される。
<Processing procedure>
FIG. 3 is a flowchart showing an example of the flow of skin color registration processing in the information processing apparatus 1000.
In step S301, the image acquisition unit 1010 acquires the captured image captured by the imaging unit 100. The image acquisition unit 1010 is realized, for example, by using a video capture card that acquires the captured image obtained by the imaging unit 100.

次に、ステップS302では、肌色領域設定部1030は、画像取得部1010で取得された撮像画像における肌色領域を指定する。入力部200(例えばGUI(Graphical User Interface))の操作によってユーザーにより設定された領域を肌色領域として採用することができる。また、予め定義した領域を肌色領域として採用してもよい。例えば、撮像部100の画面(電子ビューファインダー)内に枠を表示することと、表示部300に撮像画像と枠を表示することとの少なくとも何れか一方を行い、当該枠内に肌色が映るような構図でユーザーが被写体を撮像してもよい。この場合、当該枠内の領域が肌色領域になる。   Next, in step S302, the skin color area setting unit 1030 specifies the skin color area in the captured image acquired by the image acquisition unit 1010. An area set by the user by operating the input unit 200 (for example, GUI (Graphical User Interface)) can be adopted as the skin color area. Further, a predefined area may be adopted as the skin color area. For example, at least one of displaying a frame on the screen (electronic viewfinder) of the image capturing unit 100 and displaying the captured image and the frame on the display unit 300 is performed so that the skin color appears in the frame. The user may image the subject with various compositions. In this case, the area inside the frame becomes the skin color area.

次に、ステップS303では、画素情報抽出部1040は、色情報抽出処理を行う。本実施形態では、画素情報抽出部1040は、画像取得部1010で取得された撮像画像から、全画素について、色情報と画素位置とを抽出する。そして、有効範囲算出部1050は、有効範囲設定処理を行う。本実施形態では、有効範囲算出部1050は、色情報毎の画素数の分布を基に、色情報毎に、色情報が肌色として有効な画像領域(有効範囲)を算出する。また、肌色登録部1060は、色テーブルを作成し、データ記憶部1020に保存する。前述したように、色テーブルには、有効範囲算出部1050で求めた色情報と有効範囲が相互に関連付けて登録される。ステップS303の詳細については後述する。   Next, in step S303, the pixel information extraction unit 1040 performs color information extraction processing. In the present embodiment, the pixel information extraction unit 1040 extracts color information and pixel positions for all pixels from the captured image acquired by the image acquisition unit 1010. Then, the effective range calculation unit 1050 performs an effective range setting process. In the present embodiment, the effective range calculation unit 1050 calculates, for each color information, an image area (effective range) in which the color information is effective as a skin color, based on the distribution of the number of pixels for each color information. Further, the skin color registration unit 1060 creates a color table and stores it in the data storage unit 1020. As described above, the color information obtained by the effective range calculating unit 1050 and the effective range are registered in the color table in association with each other. Details of step S303 will be described later.

次に、ステップS304では、画像処理部1070は、色領域抽出処理を行う。本実施形態では、画像処理部1070は、データ記憶部1020に記憶されている色テーブルを用いて撮像画像から肌色領域を抽出する。例えば、画像処理部1070は、撮像画像の各画素について、色情報と画素位置とを抽出し、抽出した色情報と同じ色情報に対応する有効範囲を色テーブルから読み出し、抽出した画素位置が有効範囲内にある場合に、当該画素の位置の色を肌色と判定する。画像処理部1070は、以上のようにして抽出した結果を示す情報を、撮像画像に対して合成して合成画像を生成する。画像出力部1080は、この合成画像を表示部300に表示させる。尚、肌色領域の抽出結果は、撮像画像内の抽出領域を強調することにより示すことができる。例えば、強調する画素に赤色をアルファブレンディングして重ね合せてもよいし、強調する画素を黒色で塗りつぶしてもよい。肌色領域の抽出結果の表示が可能な手段であれば、肌色領域の抽出結果の表示方法は限定されない。   Next, in step S304, the image processing unit 1070 performs color area extraction processing. In the present embodiment, the image processing unit 1070 uses the color table stored in the data storage unit 1020 to extract the skin color region from the captured image. For example, the image processing unit 1070 extracts color information and a pixel position for each pixel of the captured image, reads an effective range corresponding to the same color information as the extracted color information from the color table, and the extracted pixel position is effective. If it is within the range, the color at the position of the pixel is determined to be a skin color. The image processing unit 1070 combines the information indicating the result extracted as described above with the captured image to generate a combined image. The image output unit 1080 displays this composite image on the display unit 300. The extraction result of the skin color area can be shown by emphasizing the extraction area in the captured image. For example, red may be alpha-blended and superimposed on the pixel to be emphasized, or the pixel to be emphasized may be filled with black. The display method of the extraction result of the skin color area is not limited as long as it is a means capable of displaying the extraction result of the skin color area.

次に、ステップS305では、ユーザーは、合成画像を確認すると、入力部200を操作することによって、肌色登録を終了するか否かを指示する。情報処理装置1000は、この指示に基づいて、肌色登録を終了するか否かを判定する。この判定の結果、肌色登録を終了する場合には、図3のフローチャートによる処理を終了する。   Next, in step S305, when the user confirms the composite image, the user operates the input unit 200 to instruct whether or not to finish the skin color registration. The information processing apparatus 1000 determines whether to finish the skin color registration based on this instruction. As a result of this determination, when the skin color registration is to be ended, the processing according to the flowchart of FIG. 3 is ended.

一方、肌色登録を終了しない場合には、ステップS302に戻り、肌色領域設定部1030は、肌色領域として、これまでに指定した肌色領域とは異なる領域を指定する。そして、肌色登録を終了すると判定されるまで、ステップS302〜S305の処理を繰り返し行う。
また、ステップS305において、肌色登録を終了しないと判定された場合には、ステップS302ではなくステップS301に戻るようにしてもよい。この場合、撮像部100は、被写体(手など)の位置を、過去の撮像画像における位置と異ならせた状態で撮像画像を得るようにする。
On the other hand, when the skin color registration is not completed, the process returns to step S302, and the skin color area setting unit 1030 designates an area different from the skin color area designated so far as the skin color area. Then, the processes of steps S302 to S305 are repeated until it is determined that the skin color registration is completed.
If it is determined in step S305 that the skin color registration is not completed, the process may return to step S301 instead of step S302. In this case, the image capturing unit 100 obtains the captured image in a state in which the position of the subject (hand, etc.) is different from the position in the past captured image.

次に、図4のフローチャートを参照しながら、図3のステップS303の処理の詳細の一例を説明する。
ステップS401では、画素情報抽出部1040は、画素選択処理を行う。本実施形態では、画素情報抽出部1040は、画像取得部1010で取得された撮像画像のうち未選択の1画素を選択し、当該画素の色情報と画素位置を取得する。前述したように本実施形態では、画面の中心からの距離が画素位置である場合を例に挙げて説明する。
Next, an example of the details of the process of step S303 of FIG. 3 will be described with reference to the flowchart of FIG.
In step S401, the pixel information extraction unit 1040 performs pixel selection processing. In the present embodiment, the pixel information extraction unit 1040 selects one unselected pixel in the captured image acquired by the image acquisition unit 1010, and acquires the color information and pixel position of the pixel. As described above, in the present embodiment, the case where the distance from the center of the screen is the pixel position will be described as an example.

次に、ステップS402では、有効範囲算出部1050は、領域判定処理を行う。本実施形態では、有効範囲算出部1050は、ステップS401で選択された画素の画素位置が、ステップS302において肌色領域設定部1030で指定された領域(指定領域)の内側(肌色)か外側(非肌色)かを判定する。   Next, in step S402, the effective range calculation unit 1050 performs a region determination process. In the present embodiment, the effective range calculation unit 1050 determines that the pixel position of the pixel selected in step S401 is inside (skin color) or outside (non-skin) of the region (designated region) designated by the skin color region setting unit 1030 in step S302. Skin color).

この判定の結果、ステップS401で選択された画素の画素位置が、指定領域内(肌色)であればステップS403に進む。ステップS403に進むと、有効範囲算出部1050は、肌色の領域についての関係導出処理を行う。本実施形態では、有効範囲算出部1050は、ステップS401で取得した画素位置(画面の中心からの距離)における肌色(ステップS401で取得した色情報)の画素数に「1」を加算する。そして、後述するステップS405に進む。   As a result of this determination, if the pixel position of the pixel selected in step S401 is within the designated area (skin color), the process proceeds to step S403. In step S403, the effective range calculation unit 1050 performs a relationship derivation process for the skin color area. In the present embodiment, the effective range calculation unit 1050 adds “1” to the number of pixels of the skin color (color information acquired in step S401) at the pixel position (distance from the center of the screen) acquired in step S401. Then, the process proceeds to step S405 described later.

一方、ステップS401で選択された画素位置が、指定領域外(非肌色)であればステップS404に進む。ステップS404に進むと、有効範囲算出部1050は、非肌色の領域についての関係導出処理を行う。本実施形態では、有効範囲算出部1050は、ステップS401で取得した画素位置(画面の中心からの距離)における非肌色(ステップS401で取得した色情報)の画素数に「1」を加算する。そして、ステップS405に進む。   On the other hand, if the pixel position selected in step S401 is outside the designated area (non-skin color), the process proceeds to step S404. In step S404, the effective range calculation unit 1050 performs a relationship derivation process for a non-skin color area. In the present embodiment, the effective range calculation unit 1050 adds “1” to the number of pixels of the non-skin color (color information acquired in step S401) at the pixel position (distance from the center of the screen) acquired in step S401. Then, the process proceeds to step S405.

ステップS405では、画素情報抽出部1040は、画像取得部1010で取得された撮像画像の全ての画素について、ステップS401〜S404の処理が終了したか否かを判定する。この判定の結果、画像取得部1010で取得された撮像画像の全ての画素について処理が終了していない場合には、ステップS401に戻る。ステップS401に戻ると、画素情報抽出部1040は、画像取得部1010で取得された撮像画像の画素のうち、未選択の画素を選択する。そして、画像取得部1010で取得された撮像画像の全ての画素について処理が終了するまで、ステップS401〜S405の処理を繰り返し行う。   In step S405, the pixel information extraction unit 1040 determines whether or not the processes of steps S401 to S404 have been completed for all the pixels of the captured image acquired by the image acquisition unit 1010. If the result of this determination is that processing has not been completed for all pixels of the captured image acquired by the image acquisition unit 1010, processing returns to step S401. Returning to step S401, the pixel information extraction unit 1040 selects an unselected pixel from the pixels of the captured image acquired by the image acquisition unit 1010. Then, the processes of steps S401 to S405 are repeated until the process is completed for all the pixels of the captured image acquired by the image acquisition unit 1010.

以上のようにして画像取得部1010で取得された撮像画像の全ての画素について処理が終了すると、ステップS406に進む。ステップS406では、有効範囲算出部1050は、有効範囲算出処理を行う。本実施形態では、有効範囲算出部1050は、画素情報抽出部1040で求めた画素位置(画面の中心からの距離)のそれぞれにおける、肌色・非肌色の画素数を基に、肌色として有効な画像領域(有効範囲)を計算することを、色情報毎に行う。具体的に、有効範囲算出部1050は、各画素位置における肌色・非肌色の画素数を比較し、画面の中心からの距離に応じた肌色の画素数が、当該距離における非肌色の画素数よりも多い範囲を有効範囲とすればよい。   When the processing is completed for all pixels of the captured image acquired by the image acquisition unit 1010 as described above, the process proceeds to step S406. In step S406, the effective range calculation unit 1050 performs an effective range calculation process. In the present embodiment, the effective range calculation unit 1050 determines an image effective as a skin color based on the number of pixels of skin color/non-skin color at each pixel position (distance from the center of the screen) obtained by the pixel information extraction unit 1040. The area (effective range) is calculated for each color information. Specifically, the effective range calculation unit 1050 compares the number of pixels of skin color/non-skin color at each pixel position, and the number of pixels of skin color corresponding to the distance from the center of the screen is larger than the number of pixels of non-skin color at the distance. The range with a large number may be set as the effective range.

図5は、肌色(領域内)の画素数の分布と、非肌色(領域外)の画素数の分布の一例を示す図である。
例えば、図5に示すように、画素数の分布(画素数と撮像画像内の画素位置との関係)が、肌色の分布501と非肌色の分布502で表される場合、有効範囲算出部1050は、肌色として有効な画像領域(有効範囲503)を算出することになる。尚、このような分布501、502は、色情報毎に得られるので、有効範囲503も色情報毎に得られる。
FIG. 5 is a diagram showing an example of the distribution of the number of pixels of skin color (inside the area) and the distribution of the number of pixels of non-skin color (outside the area).
For example, as shown in FIG. 5, when the distribution of the number of pixels (the relationship between the number of pixels and the pixel position in the captured image) is represented by a skin color distribution 501 and a non-skin color distribution 502, the effective range calculation unit 1050 Will calculate an image area (effective range 503) that is effective as a skin color. Since such distributions 501 and 502 are obtained for each color information, the effective range 503 is also obtained for each color information.

ただし、必ずしも以上のようにして有効領域を算出する必要はない。例えば、肌色の画素数が一定数以上ある画素位置(画面の中心からの距離)の範囲を、有効範囲としてもよい。この場合、肌色の分布501のみを求めればよい。また、肌色の画素数が非肌色の画素数よりも多い範囲のうち、肌色の画素数が一定数以上ある範囲を、有効範囲としてもよい。また、非肌色の画素数が一定数以下である画素位置(画面の中心からの距離)の範囲を、有効範囲としてもよい。この場合、非肌色の分布502のみを求めればよい。また、肌色の画素数が非肌色の画素数よりも多い範囲のうち、非肌色の画素数が一定数以下である範囲を、有効範囲としてもよい。
有効範囲算出部1050は、以上のような有効範囲の算出を色情報毎に行う。
However, it is not always necessary to calculate the effective area as described above. For example, a range of pixel positions (distance from the center of the screen) where the number of pixels of skin color is a certain number or more may be set as the effective range. In this case, only the skin color distribution 501 needs to be obtained. In addition, a range in which the number of pixels of skin color is a certain number or more in the range in which the number of pixels of skin color is larger than the number of pixels of non-skin color may be the effective range. Further, a range of pixel positions (distance from the center of the screen) where the number of non-skin-color pixels is a certain number or less may be set as the effective range. In this case, only the non-skin color distribution 502 need be obtained. In addition, a range in which the number of non-skin-color pixels is equal to or less than a certain number in a range in which the number of pixels of flesh-color is larger than the number of pixels of non-skin-color may be the effective range.
The effective range calculation unit 1050 calculates the effective range as described above for each color information.

次に、ステップS407では、肌色登録部1060は、登録処理を行う。本実施形態では、肌色登録部1060は、有効範囲算出部1050で算出された、色情報毎の有効範囲をデータ記憶部1020に保存する。図6は、このとき作成される色テーブルの一例を説明する図である。色テーブルの色情報には、当該色情報について、撮像画像内のどの領域が有効範囲であるかを示す距離情報が関連付けられる。例えば、色テーブルの色情報のそれぞれには、当該色情報の有効範囲を識別する識別情報が関連付けられる。識別情報は距離の数値データでもよいし、有効領域の識別番号でもよい。図6に示す例では、色情報の有効範囲の識別情報が、距離の数値データである場合を示す。図6において、色情報601の有効範囲は、画面の中心から50ピクセルの範囲である。また、色情報602の有効範囲は、画面の中心から50ピクセル離れたところから、画面の中心から100ピクセル離れたところまでの範囲である。このような有効範囲の色テーブルへの登録が、撮像画像における全ての色情報(図6のます目)のそれぞれについて行われる。   Next, in step S407, the skin color registration unit 1060 performs registration processing. In the present embodiment, the flesh color registration unit 1060 saves the effective range calculated by the effective range calculation unit 1050 for each color information in the data storage unit 1020. FIG. 6 is a diagram illustrating an example of the color table created at this time. The color information of the color table is associated with distance information indicating which area in the captured image is the effective range for the color information. For example, each piece of color information in the color table is associated with identification information that identifies the effective range of that color information. The identification information may be numerical data of distance or an identification number of the effective area. In the example shown in FIG. 6, the identification information of the effective range of the color information is the numerical value data of the distance. In FIG. 6, the effective range of the color information 601 is a range of 50 pixels from the center of the screen. The effective range of the color information 602 is a range from 50 pixels away from the center of the screen to 100 pixels away from the center of the screen. Registration of such an effective range in the color table is performed for each of all color information (cells in FIG. 6) in the captured image.

撮像画像にCGを重畳するために、撮像画像から被写体領域(手などの領域)を検出する場合、情報処理装置1000は、撮像画像の各画素について、色情報と画素位置を取得し、当該色情報に対応する有効範囲を色テーブルから読み出す。読み出した有効範囲内に当該画素の画素位置が含まれている場合、情報処理装置1000は、当該画素の位置の色は肌色であると判定する。一方、抽出した有効範囲内に当該画素の画素位置が含まれていない場合、情報処理装置1000は、当該画素の位置の色は肌色でないと判定する。情報処理装置1000は、このようにして肌色であると判定した画素の領域を、撮像画像における被写体領域(手などの領域)として抽出する。   When a subject region (a region such as a hand) is detected from a captured image in order to superimpose CG on the captured image, the information processing apparatus 1000 acquires color information and a pixel position for each pixel of the captured image, and the color The effective range corresponding to the information is read from the color table. When the pixel position of the pixel is included in the read valid range, the information processing apparatus 1000 determines that the color of the pixel position is a skin color. On the other hand, when the pixel position of the pixel is not included in the extracted effective range, the information processing apparatus 1000 determines that the color of the pixel position is not a skin color. The information processing apparatus 1000 extracts the area of the pixel determined to have the skin color in this way as the subject area (area of the hand or the like) in the captured image.

以上のように本実施形態では、撮像画像の各画素の色情報と画素位置を導出すると共に、各画素が肌色領域にあるか否か(肌色であるか否か)を判定する。肌色の画素数の分布501と被肌色の画素数の分布502を色情報毎に求め、これらの分布501、502に基づいて、各色情報の有効範囲503を算出する。したがって、周辺減光があっても、多数の色テーブルを持つことなく、現実映像から手などの被写体領域を精度良く抽出することができる。よって、複合現実感において、現実の被写体領域(手など)を違和感なく仮想空間に合成することができる。   As described above, in the present embodiment, the color information and the pixel position of each pixel of the captured image are derived, and whether each pixel is in the skin color region (whether or not it is a skin color) is determined. The distribution 501 of the number of pixels of skin color and the distribution 502 of the number of pixels of skin color are obtained for each color information, and the effective range 503 of each color information is calculated based on these distributions 501 and 502. Therefore, even if there is peripheral dimming, it is possible to accurately extract a subject region such as a hand from a real image without having a large number of color tables. Therefore, in mixed reality, it is possible to synthesize an actual subject region (such as a hand) in the virtual space without a sense of discomfort.

(第2の実施形態)
次に、第2の実施形態を説明する。第1の実施形態では、肌色登録を終了するか否かをユーザーが判断する場合を例に挙げて説明した。これに対し、本実施形態では、各色情報の有効範囲の大きさに注目して、肌色を十分に登録できたか否かを自動的に判断する場合を例に挙げて説明する。このように本実施形態と第1の実施形態は、肌色登録を終了するか否かを判定する方法が主として異なる。したがって、本実施形態の説明において、第1の実施形態と同一の部分については、図1〜図6に付した符号と同一の符号を付す等して詳細な説明を省略する。
(Second embodiment)
Next, a second embodiment will be described. In the first embodiment, the case has been described as an example where the user determines whether or not to finish the skin color registration. On the other hand, in the present embodiment, an example will be described in which attention is paid to the size of the effective range of each color information and it is automatically determined whether or not the flesh color has been sufficiently registered. As described above, the present embodiment and the first embodiment are mainly different in the method of determining whether or not to finish the skin color registration. Therefore, in the description of the present embodiment, the same parts as those in the first embodiment will be denoted by the same reference numerals as those in FIGS. 1 to 6, and the detailed description thereof will be omitted.

<構成>
図7は、本実施形態に係る画像処理システムの構成の一例を示すブロック図である。
図7に示すように、本実施形態の画像処理システムは、図1に示した第1の実施形態の画像処理システムに対し、情報処理装置2000において撮像位置算出部2010が追加されたものとなる。
<Structure>
FIG. 7 is a block diagram showing an example of the arrangement of the image processing system according to this embodiment.
As shown in FIG. 7, the image processing system of the present embodiment is the image processing system of the first embodiment shown in FIG. 1 in which an image pickup position calculation unit 2010 is added to the information processing apparatus 2000. .

撮像位置算出部2010は、色情報毎の有効範囲をデータ記憶部1020(色テーブル)から取得し、次の撮像における被写体の画面内での位置を示す情報をデータ記憶部1020に保存する。   The imaging position calculation unit 2010 acquires the effective range for each color information from the data storage unit 1020 (color table), and stores information indicating the position of the subject on the screen in the next imaging in the data storage unit 1020.

<処理の手順>
図8は、撮像位置算出部2010の処理の流れの一例を示すフローチャートである。図8のフローチャートは、図3のステップS304の代わりに実行される。
ステップS801では、撮像位置算出部2010は、肌色登録部1060により登録された色テーブルのデータ(色情報と有効範囲)をデータ記憶部1020から取得する。
次に、ステップS802では、撮像位置算出部2010は、ステップS801で取得した色テーブルのデータから、色情報の有効範囲の平均と分散を計算する。
<Processing procedure>
FIG. 8 is a flowchart showing an example of the flow of processing of the imaging position calculation unit 2010. The flowchart of FIG. 8 is executed instead of step S304 of FIG.
In step S801, the imaging position calculation unit 2010 acquires the data (color information and effective range) of the color table registered by the skin color registration unit 1060 from the data storage unit 1020.
Next, in step S802, the imaging position calculation unit 2010 calculates the average and variance of the effective range of color information from the data of the color table acquired in step S801.

次に、ステップS803では、撮像位置算出部2010は、ステップS802で計算した分散が閾値以下であるか否かを判定する。この判定の結果、分散が閾値以下であれば、肌色の登録が十分に行われたものとみなして肌色登録を終了すると判定する。   Next, in step S803, the imaging position calculation unit 2010 determines whether the variance calculated in step S802 is less than or equal to a threshold value. If the result of this determination is that the variance is less than or equal to the threshold value, it is determined that the registration of the skin color has been sufficiently performed, and it is determined that the skin color registration is completed.

一方、分散が閾値以下でない場合には、ステップS804に進む。ステップS804に進むと、撮像位置算出部2010は、位置導出処理と出力処理を行う。本実施形態では、撮像位置算出部2010は、色情報の有効範囲の平均と分散から、当該分散が小さくなる撮像領域を算出し、当該撮像領域を示す情報を表示部300に表示させる。図9は、新たな撮像領域を示す情報の表示例を示す図である。例えば、画面(撮像画像)の中心付近のみで肌色の色登録をすると、各色情報の有効範囲にばらつきが生じる。そこで、図9に示すように、有効範囲が平均から外れた位置(図9の破線で示す位置)で撮像するよう、撮像領域をユーザーに提示する。   On the other hand, if the variance is not less than or equal to the threshold, the process proceeds to step S804. In step S804, the imaging position calculation unit 2010 performs position derivation processing and output processing. In the present embodiment, the image pickup position calculation unit 2010 calculates an image pickup region in which the variance is reduced from the average and variance of the effective range of color information, and causes the display unit 300 to display information indicating the image pickup region. FIG. 9 is a diagram showing a display example of information indicating a new imaging region. For example, when the skin color is registered only near the center of the screen (captured image), the effective range of each color information varies. Therefore, as shown in FIG. 9, the imaging area is presented to the user so that imaging is performed at a position where the effective range is out of the average (the position shown by the broken line in FIG. 9).

そして、図3のステップS301に戻り、ユーザーは、ステップS804で表示された撮像領域に被写体領域(手などの領域)が位置するような状態で撮像部100に対して撮像指示を行う。これにより、撮像部100は、ステップS804で表示された撮像領域で被写体(手など)が撮像される構図で、当該被写体領域(手など)を撮像し、撮像画像を得る。
以上のようにすれば、肌色登録を終了するか否かをユーザーが判断する必要がなくなると共に、より適切な肌色登録を行うことができる。
Then, returning to step S301 in FIG. 3, the user instructs the imaging unit 100 to perform imaging in a state where the subject area (area such as the hand) is located in the imaging area displayed in step S804. As a result, the image capturing unit 100 captures an image of the subject area (such as the hand) with a composition in which the subject (such as the hand) is captured in the image capturing area displayed in step S804, and obtains a captured image.
According to the above, the user does not need to determine whether or not to finish the skin color registration, and more appropriate skin color registration can be performed.

(第3の実施形態)
次に、第3の実施形態を説明する。第1、第2の実施形態では、色情報と有効領域により肌色の登録を行う場合を例に挙げて説明した。本実施形態では、色情報と有効領域に加えて、現実空間上で有効なカメラからの深度を用いて、肌色の登録を行う。このように本実施形態と第1、第2の実施形態は、色テーブルのデータとして、色情報と有効領域に加え、現実空間上で有効なカメラからの深度が含まれることによる構成および処理が主として異なる。したがって、本実施形態の説明において、第1、第2の実施形態と同一の部分については、図1〜図9に付した符号と同一の符号を付す等して詳細な説明を省略する。
(Third Embodiment)
Next, a third embodiment will be described. In the first and second embodiments, the case where the flesh color is registered based on the color information and the effective area has been described as an example. In this embodiment, in addition to the color information and the effective area, the effective depth from the camera in the physical space is used to register the skin color. As described above, the present embodiment and the first and second embodiments are configured and processed by including, as the data of the color table, the depth from the camera effective in the real space in addition to the color information and the effective area. Mainly different. Therefore, in the description of the present embodiment, the same parts as those in the first and second embodiments will be denoted by the same reference numerals as those in FIGS. 1 to 9, and the detailed description thereof will be omitted.

<構成>
図10は、本実施形態に係る画像処理システムの構成の一例を示すブロック図である。
図10に示すように、本実施形態の画像処理システムは、図1に示した第1の実施形態の画像処理システムに対し、情報処理装置3000において有効深度取得部3010が追加されたものとなる。
<Structure>
FIG. 10 is a block diagram showing an example of the arrangement of the image processing system according to this embodiment.
As shown in FIG. 10, the image processing system of the present exemplary embodiment is the image processing system of the first exemplary embodiment shown in FIG. 1 in which an effective depth acquisition unit 3010 is added to the information processing apparatus 3000. ..

有効深度取得部3010は、データ記憶部1020に保持されている色テーブルのデータ(色情報毎の有効範囲)から、撮像画像の肌色領域を求め、求めた肌色領域についてのカメラ(撮像部100)からの深度を算出する。深度は、カメラの撮像面に垂直な方向におけるカメラと被写体との距離である。有効深度取得部3010は、複数の撮像画像から、肌色領域についてのカメラからの深度を算出し、最大の深度から最小の深度までの範囲を有効深度範囲としてデータ記憶部1020(色テーブル)に保存する。   The effective depth acquisition unit 3010 obtains the skin color region of the captured image from the data (effective range for each color information) of the color table held in the data storage unit 1020, and the camera (imaging unit 100) for the obtained skin color region. Calculate the depth from. The depth is the distance between the camera and the subject in the direction perpendicular to the imaging surface of the camera. The effective depth acquisition unit 3010 calculates the depth from the camera for the skin color region from the plurality of captured images, and saves the range from the maximum depth to the minimum depth as the effective depth range in the data storage unit 1020 (color table). To do.

<処理の手順>
図11は、有効深度取得部3010の処理の流れの一例を示すフローチャートである。図11のフローチャートは、例えば、図3のステップS303とステップS304との間で実行される。
ステップS1101では、有効深度取得部3010は、領域抽出処理を行う。本実施形態では、有効深度取得部3010は、色テーブルを用いて、画像取得部1010で取得された撮像画像の肌色領域を抽出する。
<Processing procedure>
FIG. 11 is a flowchart showing an example of the processing flow of the effective depth acquisition unit 3010. The flowchart of FIG. 11 is executed, for example, between step S303 and step S304 of FIG.
In step S1101, the effective depth acquisition unit 3010 performs area extraction processing. In the present embodiment, the effective depth acquisition unit 3010 uses the color table to extract the skin color region of the captured image acquired by the image acquisition unit 1010.

次に、ステップS1102では、有効深度取得部3010は、深度導出処理を行う。本実施形態では、有効深度取得部3010は、ステップS1101で抽出された肌色領域に対するカメラ(撮像部100)からの深度を導出する。肌色領域に対するカメラからの深度は、例えば、ステレオ法を用いて導出してもよいし、深度センサの値を用いて導出してもよい。ステレオ法を用いる場合、撮像部100によりステレオ画像を得る。カメラ(撮像部100)と肌色領域との現実空間における距離を検出する方法を用いていれば、肌色領域に対するカメラからの深度を導出する方法は限定されない。有効深度取得部3010は、このような深度を複数の撮像画像のそれぞれについて行う。   Next, in step S1102, the effective depth acquisition unit 3010 performs a depth derivation process. In the present embodiment, the effective depth acquisition unit 3010 derives the depth from the camera (imaging unit 100) for the skin color region extracted in step S1101. The depth from the camera for the skin color region may be derived using, for example, the stereo method, or may be derived using the value of the depth sensor. When the stereo method is used, a stereo image is obtained by the image pickup unit 100. The method of deriving the depth from the camera for the skin color area is not limited as long as the method of detecting the distance between the camera (imaging unit 100) and the skin color area in the real space is used. The effective depth acquisition unit 3010 performs such depth for each of the plurality of captured images.

最後に、ステップS1103では、有効深度取得部3010は、複数の撮像画像から導出した肌色領域に対するカメラからの深度の最大値と最小値との間の範囲を、有効深度範囲として算出し、データ記憶部1020に保存する。   Finally, in step S1103, the effective depth acquisition unit 3010 calculates a range between the maximum value and the minimum value of the depth from the camera for the skin color area derived from the plurality of captured images as the effective depth range, and stores the data. It is stored in the section 1020.

撮像画像にCGを重畳するために、撮像画像から被写体領域(手などの領域)を検出する場合、情報処理装置1000は、撮像画像の各画素について、色情報と画素位置と深度を取得する。そして、情報処理装置1000は、取得した色情報に対応する有効範囲(当該色情報が肌色として有効な画像領域)と有効深度範囲とを色テーブルから読み出す。読み出した有効範囲内に当該画素の画素位置が含まれており、且つ、読み出した有効深度範囲内に当該画素の位置における深度が含まれている場合、情報処理装置1000は、当該画素の位置の色は肌色であると判定する。一方、そうでない場合、情報処理装置1000は、当該画素の位置の色は肌色でないと判定する。情報処理装置1000は、このようにして肌色であると判定した画素の領域を、撮像画像における被写体領域(手などの領域)として抽出する。   When detecting a subject region (a region such as a hand) from the captured image in order to superimpose the CG on the captured image, the information processing apparatus 1000 acquires color information, a pixel position, and a depth for each pixel of the captured image. Then, the information processing apparatus 1000 reads from the color table an effective range (an image area where the color information is effective as a skin color) and an effective depth range corresponding to the acquired color information. When the pixel position of the pixel is included in the read effective range and the depth at the position of the pixel is included in the read effective depth range, the information processing apparatus 1000 determines the position of the pixel. The color is determined to be a skin color. On the other hand, if not, the information processing apparatus 1000 determines that the color at the position of the pixel is not a skin color. The information processing apparatus 1000 extracts the area of the pixel determined to have the flesh color in this way as a subject area (area such as a hand) in the captured image.

以上のように本実施形態では、各色情報に対応する有効範囲(肌色として有効な画像領域)に加え、有効深度の範囲を登録し、これらの双方に基づいて被写体領域の抽出を行う。したがって、肌色登録時に登録した被写体領域(手などの領域)にある肌色だけをより確実に抽出することができ、被写体領域の誤検出率をより小さくすることができる。   As described above, in the present embodiment, in addition to the effective range (image area effective as a skin color) corresponding to each color information, the effective depth range is registered, and the subject area is extracted based on both of these. Therefore, it is possible to more reliably extract only the skin color in the subject area (the area such as the hand) registered when the skin color is registered, and it is possible to further reduce the false detection rate of the subject area.

(第4の実施形態)
次に、第4の実施形態を説明する。第1〜3の実施形態では、設定された肌色領域を基に色情報毎の有効範囲を算出する場合を例に挙げて説明した。これに対し、本実施形態では、あらかじめ有効範囲と関連付けられた色情報を取得し、その色情報に対して補間処理を行うことで、新たな有効範囲と関連付けられた新たな色情報を生成する場合を例に挙げて説明する。このように本実施形態と第1〜3の実施形態は、あらかじめ有効範囲と関連付けられた色情報を取得する点と、その色情報に対して補間処理を行う点が主として異なる。したがって、本実施形態の説明において、第1〜3の実施形態と同一の部分については、図1〜図11に付した符号と同一の符号を付す等して詳細な説明を省略する。
(Fourth Embodiment)
Next, a fourth embodiment will be described. In the first to third embodiments, the case where the effective range for each color information is calculated based on the set skin color area has been described as an example. On the other hand, in this embodiment, color information associated with a valid range is acquired in advance, and interpolation processing is performed on the color information to generate new color information associated with a new valid range. The case will be described as an example. As described above, the present embodiment and the first to third embodiments are mainly different in that color information associated with the effective range in advance is acquired and that interpolation processing is performed on the color information. Therefore, in the description of the present embodiment, the same parts as those in the first to third embodiments will be denoted by the same reference numerals as those in FIGS. 1 to 11, and the detailed description thereof will be omitted.

<構成>
図12は、本実施形態に係る画像処理システムの構成の一例を示すブロック図である。図12において、色情報補間部4010は、あらかじめ有効範囲と関連付けられた色情報に対して補間処理を行うことで新たな有効範囲と関連付けられた新たな色情報を生成する。また、有効範囲算出部1210は、第1〜3の実施形態の有効範囲算出部1050とは役割が異なる。第1〜3の実施形態における有効範囲算出部1050は、画素情報抽出部1040が抽出した色情報と画素位置とから、各色情報の有効範囲を算出する。一方、本実施形態における有効範囲算出部1210は、画素情報抽出部1040が抽出する色情報の有効範囲をあらかじめ設定、もしくは算出しておく役割を担う。
<Structure>
FIG. 12 is a block diagram showing an example of the arrangement of the image processing system according to this embodiment. In FIG. 12, the color information interpolating unit 4010 generates new color information associated with a new effective range by performing an interpolation process on the color information associated with the effective range in advance. The effective range calculation unit 1210 has a different role from the effective range calculation unit 1050 of the first to third embodiments. The effective range calculation unit 1050 in the first to third embodiments calculates the effective range of each color information from the color information extracted by the pixel information extraction unit 1040 and the pixel position. On the other hand, the effective range calculation unit 1210 in the present embodiment has a role of presetting or calculating the effective range of the color information extracted by the pixel information extraction unit 1040.

<処理の手順>
図13は、情報処理装置4000における肌色登録処理の流れの一例を示すフローチャートである。図13のフローチャートは、例えば、図3のステップS301〜S304の代わりに実行される。
ステップS1301では、色情報補間部4010は、有効範囲と関連付けされた色情報を取得する。取得する色情報の生成方法の例については後述する。
次に、ステップS1302では、色情報補間部4010は、ステップS1301で取得した色情報に対して補間処理を行うことで新たな有効範囲と関連付けられた新たな色情報を生成する。補間処理については後述する。
<Processing procedure>
FIG. 13 is a flowchart showing an example of the flow of skin color registration processing in the information processing device 4000. The flowchart of FIG. 13 is executed instead of, for example, steps S301 to S304 of FIG.
In step S1301, the color information interpolation unit 4010 acquires the color information associated with the effective range. An example of a method of generating the acquired color information will be described later.
Next, in step S1302, the color information interpolation unit 4010 performs interpolation processing on the color information acquired in step S1301 to generate new color information associated with the new effective range. The interpolation process will be described later.

図14は、ステップS1301において取得する色情報に関する生成処理の流れの一例を示すフローチャートである。
ステップS1401では、有効範囲算出部1210は、後述するステップS1405において取得する色情報の有効範囲を設定(取得もしくは算出)する。例えば、色情報の有効範囲として、画像中の画素位置を、入力部200から取得する。また、データ記憶部1020にあらかじめ有効範囲を示す画素位置を設定しておき、それを取得してもよい。また、撮像部100が撮像する画像の画素数と、「中央部」や「端部」などの概略的な有効範囲を示す設定情報を、入力部200やデータ記憶部1020から取得し、それらの情報から色情報の有効範囲として画素位置を算出してもよい。
FIG. 14 is a flowchart showing an example of the flow of a generation process regarding the color information acquired in step S1301.
In step S1401, the effective range calculation unit 1210 sets (acquires or calculates) the effective range of the color information acquired in step S1405 described later. For example, the pixel position in the image is acquired from the input unit 200 as the effective range of the color information. Further, the pixel position indicating the effective range may be set in advance in the data storage unit 1020 and then acquired. In addition, setting information indicating the number of pixels of the image captured by the image capturing unit 100 and the approximate effective range such as “center” and “edge” is acquired from the input unit 200 and the data storage unit 1020, and the setting information is acquired. The pixel position may be calculated from the information as the effective range of the color information.

次に、ステップS1402では、有効範囲算出部1210は、ステップS1401で算出した有効範囲に基づいて撮像部100の露出を算出し、不図示の撮像制御部を介して撮像部100の露出を設定する。露出の設定方法については後述する。
次に、ステップS1403では、画像取得部1010は、第1の実施形態と同様に、撮像部100から撮像画像を取得し、データ記憶部1020に記憶する。
Next, in step S1402, the effective range calculation unit 1210 calculates the exposure of the image capturing unit 100 based on the effective range calculated in step S1401, and sets the exposure of the image capturing unit 100 via an image capturing control unit (not shown). .. The method of setting the exposure will be described later.
Next, in step S1403, the image acquisition unit 1010 acquires a captured image from the imaging unit 100 and stores the captured image in the data storage unit 1020, as in the first embodiment.

次に、ステップS1404では、肌色領域設定部1030は、第1の実施形態と同様に、肌色領域を設定する。
次に、ステップS1405では、画素情報抽出部1040は、第1の実施形態と同様に、ステップS1404で設定した肌色領域に含まれる画素の色情報を抽出する。
次に、ステップS1406では、ユーザーが撮影を終了するか否かを判定し、入力部200を介して、情報処理装置4000に与える。または、あらかじめ撮影回数を設定しておき、その回数撮影を行ったか否かに応じて、情報処理装置4000が撮影を終了するか否かの判定を行ってもよい。この判定の結果、撮影を終了する場合には、図14のフローチャートによる処理を終了する。
一方、撮影を終了しない場合には、ステップS1401に戻り、撮影を終了すると判定されるまで、ステップS1401〜S1406の処理を繰り返し行う。
Next, in step S1404, the skin color area setting unit 1030 sets a skin color area, as in the first embodiment.
Next, in step S1405, the pixel information extraction unit 1040 extracts color information of pixels included in the skin color region set in step S1404, as in the first embodiment.
Next, in step S1406, it is determined whether or not the user finishes shooting, and the information is given to the information processing apparatus 4000 via the input unit 200. Alternatively, the number of times of shooting may be set in advance, and the information processing apparatus 4000 may determine whether or not to end shooting, depending on whether or not the number of times of shooting has been performed. If the result of this determination is that shooting should end, then the processing according to the flowchart of FIG. 14 ends.
On the other hand, when the photographing is not ended, the process returns to step S1401 and the processes of steps S1401 to S1406 are repeated until it is determined that the photographing is ended.

以上の処理によって、有効範囲と関連付けられた複数の色情報を生成することができる。なお、本実施形態は、図14のフローチャートに従って色情報を生成する場合に限定されず、任意の方法で色情報を生成して構わない。例えば、画面中心で適正露出となるように撮影した画像と画面端で適正露出となるように撮影した画像から色情報を抽出し、それらを、画面中心を有効範囲とする色情報と画面端を有効範囲とする色情報として用いても構わない。また、情報処理装置4000の外部で生成された色情報を、入力部200を介して取得しても構わない。   Through the above processing, it is possible to generate a plurality of color information associated with the effective range. Note that the present embodiment is not limited to the case of generating color information according to the flowchart of FIG. 14, and color information may be generated by any method. For example, color information is extracted from an image taken so that the proper exposure is made at the center of the screen and an image taken so that the proper exposure is made at the edge of the screen, and the color information and the edge of the screen whose effective range is the center of the screen are extracted. It may be used as the color information for the effective range. Further, the color information generated outside the information processing device 4000 may be acquired via the input unit 200.

図15は、画面中心からの距離とシェーディング係数の関係を示す図である。シェーディングとは画面内の輝度ムラのことであり、以下では、画面中心における輝度を1.0とした場合の各画素位置における輝度をシェーディング係数とする場合を例に挙げて説明する。以下、図15を参照して、有効範囲算出部1050による露出の算出方法について説明する。まず、ステップS1210で設定した有効範囲の中心における画面中心からの距離を算出し、その距離におけるシェーディング係数sを算出する。そして、適正露出をs倍した値を撮像部100の露出として算出する。以上が有効範囲算出部1210による露出の算出方法の説明である。   FIG. 15 is a diagram showing the relationship between the distance from the center of the screen and the shading coefficient. Shading refers to brightness unevenness in the screen, and in the following description, the case where the brightness at each pixel position when the brightness at the screen center is 1.0 is used as the shading coefficient will be described as an example. Hereinafter, with reference to FIG. 15, an exposure calculation method by the effective range calculation unit 1050 will be described. First, the distance from the screen center at the center of the effective range set in step S1210 is calculated, and the shading coefficient s at that distance is calculated. Then, a value obtained by multiplying the proper exposure by s is calculated as the exposure of the image capturing unit 100. The above is the description of the exposure calculation method by the effective range calculation unit 1210.

図16は、色情報の有効範囲の一例を模式的に示す図である。図16(a)は、ステップS1401において設定される色情報の有効範囲1601〜1603とその境界部1604、1605を示している。また、図16(b)は、色情報補間部4010によって設定される新たな色情報の有効範囲1606〜1614を示している。また、図17は、ステップS1401において設定される色情報の一例を模式的に示す図である。図17(a)は、ステップS1401で設定された色情報1701の全体を示す図である。図17(b)は、色情報1701のうち有効範囲1601に対応する色情報1702を示す図である。図17(c)は、有効範囲1602、1603に対応する色情報1703を示す図である。   FIG. 16 is a diagram schematically showing an example of the effective range of color information. FIG. 16A shows the valid ranges 1601 to 1603 of color information set in step S1401 and the boundary portions 1604 and 1605 thereof. Further, FIG. 16B shows effective ranges 1606 to 1614 of new color information set by the color information interpolation unit 4010. In addition, FIG. 17 is a diagram schematically illustrating an example of the color information set in step S1401. FIG. 17A is a diagram showing the entire color information 1701 set in step S1401. FIG. 17B is a diagram showing color information 1702 corresponding to the effective range 1601 of the color information 1701. FIG. 17C is a diagram showing color information 1703 corresponding to the effective ranges 1602 and 1603.

これらの色情報を用いて被写体の肌色領域の検出を行うと、有効範囲1601に対応する色情報1702と有効範囲1602、1603に対応する色情報1703が大きく異なる場合、境界部1604、1605の左右の領域で、検出結果が大きく異なる。この問題を解決するために、本実施形態では、色情報1702、1703に対して補間処理を行うことで、図16(b)の有効範囲1606〜1614のように、より細かく分割された有効範囲に対応する色情報を生成する。   When the skin color region of the subject is detected using these color information, when the color information 1702 corresponding to the effective range 1601 and the color information 1703 corresponding to the effective ranges 1602 and 1603 are greatly different, the left and right sides of the boundary portions 1604 and 1605 are detected. The detection results are significantly different in the area. In order to solve this problem, in the present embodiment, interpolation processing is performed on the color information 1702 and 1703, so that the effective range divided into smaller effective ranges 1606 to 1614 in FIG. Generates color information corresponding to.

図18は、色情報補間部4010における補間処理の流れの一例を示すフローチャートである。
ステップS1801では、色情報補間部4010は、色情報1702、1703の重心1704、1705を算出する。例えば、色情報がCbCr色空間で示される情報の場合、CbCr色空間における座標を色情報の重心として算出する。
次に、ステップS1802では、色情報補間部4010は、色情報1702、1703の各色を、ステップS1801で算出した重心1704、1705からの距離が近い順番に整列する。
FIG. 18 is a flowchart showing an example of the flow of interpolation processing in the color information interpolation unit 4010.
In step S1801, the color information interpolation unit 4010 calculates the centroids 1704 and 1705 of the color information 1702 and 1703. For example, when the color information is information shown in the CbCr color space, the coordinates in the CbCr color space are calculated as the center of gravity of the color information.
Next, in step S1802, the color information interpolating unit 4010 arranges the colors of the color information 1702 and 1703 in order of decreasing distance from the centroids 1704 and 1705 calculated in step S1801.

次に、ステップS1803では、色情報補間部4010は、有効範囲1606〜1614から1つの有効範囲を参照する。なお、ここでは、ステップS1803で参照した有効範囲を必要に応じて参照有効範囲と称する。
次に、ステップS1804では、色情報補間部4010は、ステップS1803で参照した有効範囲のシェーディング係数を取得する。シェーディング係数は、ステップS1402で説明した画面中心からの距離とシェーディング係数の関係を示す情報から取得することができる(図15を参照)。なお、本実施形態は、シェーディング係数として、実際の画像のシェーディングに忠実な値を取得する場合に限定されない。例えば、画面中心に対応する有効範囲のシェーディング係数を1とし、画面端に対応する有効範囲のシェーディング係数を0(ゼロ)とすることなどができる。
Next, in step S1803, the color information interpolation unit 4010 refers to one effective range from the effective ranges 1606 to 1614. Here, the effective range referred to in step S1803 will be referred to as a reference effective range as necessary.
Next, in step S1804, the color information interpolation unit 4010 acquires the shading coefficient in the effective range referred to in step S1803. The shading coefficient can be acquired from the information indicating the relationship between the distance from the screen center and the shading coefficient described in step S1402 (see FIG. 15). The present embodiment is not limited to the case where a value faithful to the shading of the actual image is acquired as the shading coefficient. For example, the shading coefficient in the effective range corresponding to the center of the screen can be set to 1, and the shading coefficient in the effective range corresponding to the screen edge can be set to 0 (zero).

次に、ステップS1805では、色情報補間部4010は、ステップS1804で取得したシェーディング係数に基づいて、色情報1702と1703の補間比率を算出する。例えば、参照有効範囲のシェーディング係数がs、有効範囲1601のシェーディング係数がs1、有効範囲1602、1603のシェーディング係数がs2の場合、色情報1702、1703の補間比率r1、r2は以下の式(1)、式(2)で算出できる。
r1=(s―s2)÷(s1−s2) ・・・(1)
r2=1−r1 ・・・(2)
Next, in step S1805, the color information interpolation unit 4010 calculates the interpolation ratio of the color information 1702 and 1703 based on the shading coefficient acquired in step S1804. For example, when the shading coefficient of the reference effective range is s, the shading coefficient of the effective range 1601 is s1, and the shading coefficient of the effective ranges 1602 and 1603 is s2, the interpolation ratios r1 and r2 of the color information 1702 and 1703 are as follows: ) And equation (2).
r1=(s-s2)÷(s1-s2) (1)
r2=1-r1 (2)

次に、ステップS1806では、色情報補間部4010は、ステップS1805で算出した補間比率r1、r2に基づいて有効範囲1601、1602の色情報を合成し、ステップS1803で参照した参照有効範囲に対応する色情報を生成する。
次に、ステップS1807において、色情報補間部4010は、全ての有効範囲1606〜1614を参照したか否かを判定する。この判定の結果、全ての有効範囲1606〜1614を参照していない場合には、ステップS1803に戻り、有効範囲1606〜1614のうち、まだ参照していない有効範囲を参照する。そして、全ての有効範囲1606〜1614を参照するまで、ステップS1803〜S1807の処理を繰り返し行う。そして、全ての有効範囲1606〜1614を対象としてステップS1803〜S1806の処理を行うと、図18のフローチャートによる処理を終了する。
Next, in step S1806, the color information interpolation unit 4010 combines the color information of the effective ranges 1601 and 1602 based on the interpolation ratios r1 and r2 calculated in step S1805, and corresponds to the reference effective range referred to in step S1803. Generate color information.
Next, in step S1807, the color information interpolation unit 4010 determines whether or not all effective ranges 1606 to 1614 have been referenced. As a result of this determination, if all the valid ranges 1606 to 1614 are not referred to, the process returns to step S1803 to refer to the valid ranges that have not yet been referred to among the valid ranges 1606 to 1614. Then, the processes of steps S1803 to S1807 are repeated until all the valid ranges 1606 to 1614 are referenced. When the processes of steps S1803 to S1806 are performed on all the valid ranges 1606 to 1614, the process according to the flowchart of FIG. 18 ends.

図19は、ステップS1806における合成処理の流れの一例を示すフローチャートである。
ステップS1901では、色情報補間部4010は、合成前の色情報1702、1703のうち1つの色情報を参照する。
次に、ステップS1902では、色情報補間部4010は、ステップS1901で参照した色情報から、ステップS1805で算出した補間比率r1、r2に応じて、色を抽出する。以下、ステップS1901で色情報1702を参照した場合を例に説明する。色情報1702の補間比率はr1である。したがって、色情報補間部4010は、ステップS1802で整列した順番に(重心から近い順に)色情報1702に含まれる全色数のr1倍の数だけ、色を抽出する。ステップS1902で色情報1703を参照した場合の処理も同様である。ただし、補間比率としてはr1ではなく、r2を用いる。
FIG. 19 is a flowchart showing an example of the flow of the combining process in step S1806.
In step S1901, the color information interpolating unit 4010 refers to one of the color information 1702 and 1703 before combining.
Next, in step S1902, the color information interpolation unit 4010 extracts a color from the color information referred to in step S1901 in accordance with the interpolation ratios r1 and r2 calculated in step S1805. Hereinafter, a case where the color information 1702 is referred to in step S1901 will be described as an example. The interpolation ratio of the color information 1702 is r1. Therefore, the color information interpolating unit 4010 extracts the number of colors r1 times the total number of colors included in the color information 1702 in the order arranged in step S1802 (from the center of gravity). The same applies to the processing when the color information 1703 is referred to in step S1902. However, r2 is used as the interpolation ratio instead of r1.

前記の処理によって、補間比率r1、r2に応じて重要な(重心から近い)色から順番に色を抽出することができる。なお、本実施形態における色の抽出処理は前記のものに限定されない。例えば、ある色情報から色を抽出する時に、その色情報自身の重心ではなく、他方の色情報の重心からの距離の順番に抽出してもよい。そのように色の抽出処理を行うと、合成前の色情報同士が色空間上で離れている場合でも、その間を繋ぐように補間を行うことができる。   By the above processing, it is possible to extract colors in order from important colors (close to the center of gravity) according to the interpolation ratios r1 and r2. The color extraction processing in this embodiment is not limited to the above. For example, when a color is extracted from certain color information, it may be extracted in order of distance from the center of gravity of the other color information instead of the center of gravity of the color information itself. When the color extraction processing is performed in this way, even if the color information before combining is separated from each other in the color space, it is possible to perform interpolation so as to connect them.

次に、ステップS1903では、色情報補間部4010は、合成前の色情報1702、1703の全てを参照したか否かを判定する。この判定の結果、合成前の色情報1702、1703の全てを参照した場合は、ステップS1904へ進む。
一方、合成前の色情報1702、1703の全てを参照し終えていない場合には、ステップS1901に戻り、合成前の色情報1702、1703のうち、まだ参照していない色情報を参照する。そして、合成前の色情報1702、1703の全てを参照し終えるまで、ステップS1901〜S1903の処理を繰り返し行う。
次に、ステップS1904では、色情報補間部4010は、ステップS1902で色情報1702、1703から抽出した色の論理和をとることで、合成後の色情報を算出する。この処理によって、シェーディング係数に基づいた補間比率によって補間された色情報を生成することができる。
Next, in step S1903, the color information interpolating unit 4010 determines whether or not all of the pre-combination color information 1702 and 1703 has been referenced. As a result of this determination, if all of the pre-combination color information 1702 and 1703 are referenced, the process advances to step S1904.
On the other hand, if all of the pre-combination color information 1702 and 1703 has not been referred to, the process returns to step S1901 and the uncombined color information 1702 and 1703 is referred to. Then, the processes of steps S1901 to S1903 are repeated until all the pre-combination color information 1702 and 1703 have been referenced.
Next, in step S1904, the color information interpolating unit 4010 calculates the color information after composition by taking the logical sum of the colors extracted from the color information 1702 and 1703 in step S1902. By this processing, it is possible to generate the color information interpolated by the interpolation ratio based on the shading coefficient.

なお、ステップS1902において、既に他の色情報から抽出されている色を重複して抽出すると、合成後の色情報の色数が合成前の色情報1702、1703の色数と比較して少なくなる。このため、このような重複が起こらないように色を抽出するのが望ましい。ただし、このような色の重複を除く場合に限定されるわけではなく、重複して色を抽出しても構わない。   Note that in step S1902, if the colors already extracted from other color information are extracted redundantly, the number of colors of the color information after combining becomes smaller than the number of colors of the color information 1702 and 1703 before combining. .. Therefore, it is desirable to extract the colors so that such overlapping does not occur. However, the present invention is not limited to the case of eliminating such color overlap, and the colors may be extracted in an overlapping manner.

また、本実施形態においても、肌色登録部1060により登録処理が行われる。ただし、本実施形態では、有効範囲算出部1050で算出された、色情報毎の有効範囲ではなく、色情報補間部4010で算出された、色情報毎の有効範囲をデータ記憶部1020に保存する。   Also in this embodiment, the registration processing is performed by the skin color registration unit 1060. However, in the present embodiment, the effective range for each color information calculated by the color information interpolating unit 4010, not the effective range for each color information calculated by the effective range calculating unit 1050, is stored in the data storage unit 1020. ..

なお、本実施形態では、2つの色情報を補間する場合について説明したが、補間する色情報の数はこれに限定されない。2つ以上の色情報を補間することで、より多くの色情報を生成する全ての場合に適用できる。また、補間ではなく、補外によって新たな色情報を生成する場合にも本発明を適用することができる。   In the present embodiment, the case where two pieces of color information are interpolated has been described, but the number of pieces of color information to be interpolated is not limited to this. By interpolating two or more color information, it can be applied to all cases in which more color information is generated. The present invention can also be applied to the case of generating new color information by extrapolation instead of interpolation.

以上のように、本実施形態では、あらかじめ取得した色情報を補間することで、より細かく分割された領域に対応する色情報を算出することができる。これによって、肌色領域を検出した場合に有効範囲の境界の左右領域で、検出結果が大きく異なってしまう減少を低減することができる。
なお、本実施形態においても、第2、第3の実施形態の構成を採用することができる。
As described above, in the present embodiment, the color information corresponding to the more finely divided area can be calculated by interpolating the color information acquired in advance. As a result, it is possible to reduce a decrease in the detection results that greatly differ between the left and right areas of the boundary of the effective range when the skin color area is detected.
Note that the configurations of the second and third embodiments can also be adopted in this embodiment.

以上の各実施形態では、被写体の色として肌色を検出する場合を例に挙げて説明した。しかしながら、検出する色は、被写体に応じて適宜決定されるので、肌色に限定されない。   In each of the above embodiments, the case where the skin color is detected as the color of the subject has been described as an example. However, the color to be detected is appropriately determined according to the subject, and is not limited to the skin color.

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

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

100:撮像部、200:入力部、300:表示部、1000:情報処理装置   100: imaging unit, 200: input unit, 300: display unit, 1000: information processing device

Claims (16)

撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得手段と、
前記撮像画像の各画素から抽出される色情報ごとに、前記撮像画像における、前記色情報を有する画素であって、前記指定された領域の内側にある画素の数と、前記色情報を有する画素であって、前記指定された領域の外側にある画素の数の少なくとも一方に基づいて、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲を設定する有効範囲設定手段と、
前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定手段により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出手段とを備えることを特徴とする情報処理装置。
An acquisition unit that acquires an area designated in the captured image of the subject captured by the imaging unit;
For each color information extracted from each pixel of the captured image, the number of pixels in the captured image having the color information , the number of pixels inside the specified region, and the pixel having the color information. That is, based on at least one of the number of pixels outside the designated region, the color information is a process of extracting a region of a predetermined color from an image captured by the image capturing unit, An effective range setting means for setting an effective range that is effective as the predetermined color ;
When the color information of each pixel of the image captured by the image capturing unit is included in the effective range set for each of the color information by the effective range setting unit at the position of the pixel, the pixel is set in advance as described above. An information processing apparatus, comprising: a color area extraction unit that extracts a part of a predetermined color area.
前記有効範囲設定手段は、前記撮像画像の各画素から抽出される色情報ごとに、前記撮像画像における、前記色情報を有する画素であって、前記指定された領域の内側にある画素の数である第1の数と、前記色情報を有する画素であって、前記指定された領域の外側にある画素の数である第2の数とを、前記撮像手段により撮像される撮像画像のうち中心からの距離に基づいて定義される複数の領域のそれぞれごとに算出するものであって、The effective range setting unit is, for each color information extracted from each pixel of the captured image, the number of pixels having the color information in the captured image, the number of pixels being inside the designated region. A certain first number and a second number, which is the number of pixels having the color information and located outside the designated region, are set to the center of the imaged images captured by the image capturing unit. Is calculated for each of a plurality of regions defined based on the distance from
前記色情報ごとに、前記複数の領域のうち、前記第1の数が、前記第2の数よりも多い領域を、前記色情報の前記有効範囲として設定することを特徴とする請求項1に記載の情報処理装置。The area in which the first number is larger than the second number among the plurality of areas is set as the valid range of the color information for each of the color information. The information processing device described.
前記有効範囲設定手段は、更に、
前記指定された領域の内側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係と、前記指定された領域の外側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係との少なくとも何れか一方を、前記色情報のそれぞれについて導出する関係導出手段を備え、
前記関係導出手段により導出された前記関係に基づいて、前記有効範囲を、前記色情報のそれぞれについて導出することを特徴とする請求項2に記載の情報処理装置。
The effective range setting means further includes
Information indicating the position in the captured image regarding the pixels inside the specified region and the number of pixels, and information indicating the position in the captured image regarding the pixels outside the specified region and at least one of the relationship between the number of pixels, comprising the relationship deriving means to derive for each of the color information,
Based on the relationship derived by the relationship deriving means, the pre-Symbol valid range, information processing apparatus according to claim 2, wherein the deriving for each of the color information.
前記関係導出手段は、前記指定された領域の内側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係と、前記指定された領域の外側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係とを、前記色情報のそれぞれについて導出し、
前記有効範囲設定手段は、前記指定された領域の内側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係と、前記指定された領域の外側にある画素についての、前記撮像画像における位置を示す情報と画素数との関係とを比較した結果に基づいて、前記有効範囲を、前記色情報のそれぞれについて導出することを特徴とする請求項3に記載の情報処理装置。
The relationship deriving means, for the pixel that is inside the designated area, the relationship between the information and the number of pixels indicating the position in the captured image, for pixels that are outside of the designated area, the imaging The relationship between the information indicating the position in the image and the number of pixels is derived for each of the color information,
The effective range setting means, for the pixels inside the designated area, the relationship between the information indicating the position in the captured image and the number of pixels, and for the pixels outside the designated area, based on the result of comparing the relationship between the information and the number of pixels indicating the position in the captured image, the information processing according to claim 3, the pre-Symbol valid range, and wherein the deriving for each of the color information apparatus.
撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得手段と、
前記撮像画像のうち、前記指定された領域に含まれる画素から抽出される色情報ごとに、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲として設定する有効範囲設定手段と、
前記有効範囲設定手段により設定された前記効範囲よりも多い数の新たな有効範における色情報を生成する生成手段と、
前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定手段により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出手段とを備え
前記生成手段は、前記有効範囲設定手段により設定された前記有効範囲のそれぞれから、当該有効範囲に対応する色情報を代表する1つまたは複数の色を抽出し、抽出した色に基づいて、前記新たな有効範囲における色情報を生成することを特徴とする情報処理装置。
An acquisition unit that acquires an area designated in the captured image of the subject captured by the imaging unit;
In the process of extracting a region of a predetermined color from the image captured by the image capturing unit, for each color information extracted from the pixels included in the designated region in the captured image. An effective range setting means for setting an effective range that is effective as the predetermined color,
A generating means for generating color information in the set the chromatic Kohan large number of new chromatic Kohan circumference than enclosed by said effective range setting means,
When the color information of each pixel of the image captured by the image capturing unit is included in the effective range set for each of the color information by the effective range setting unit at the position of the pixel, the pixel is set in advance as described above. A color area extracting means for extracting as a part of a predetermined color area ,
The generation means extracts one or more colors representing color information corresponding to the effective range from each of the effective ranges set by the effective range setting means, and based on the extracted colors, It characterized that you generate color information in the new coverage information processing apparatus.
前記生成手段は、前記有効範囲設定手段により設定された前記有効範囲のそれぞれから、当該有効範囲に対応する色情報を代表する1つまたは複数の色として、前記有効範囲設定手段により設定された前記有効範囲の位置に応じて定まる数の色を抽出することを特徴とする請求項5に記載の情報処理装置。 The generating means sets, from each of the effective ranges set by the effective range setting means, one or a plurality of colors representing color information corresponding to the effective range, which is set by the effective range setting means. The information processing apparatus according to claim 5, wherein a predetermined number of colors are extracted according to the position of the effective range . 前記生成手段は、前記有効範囲設定手段により設定された前記有効範囲のそれぞれから、当該有効範囲に対応する色情報を代表する1つまたは複数の色として、当該色情報に含まれる色の総数に、前記有効範囲設定手段により設定された前記有効範囲の位置に対応する輝度ムラを表す指標に基づいて定まる比率を掛けた数の色を抽出することを特徴とする請求項に記載の情報処理装置。 The generation unit determines, from each of the effective ranges set by the effective range setting unit, a total number of colors included in the color information as one or a plurality of colors representing color information corresponding to the effective range. 6. The information processing according to claim 5 , wherein the number of colors is extracted by multiplying by a ratio determined based on an index representing the brightness unevenness corresponding to the position of the effective range set by the effective range setting means. apparatus. 更に、前記色情報のそれぞれにおける前記有効範囲に基づいて、次の撮像における前記被写体の画面内の位置を導出する位置導出手段と、
前記位置導出手段により導出された前記位置を示す情報を出力する出力手段とを備え、
前記有効範囲設定手段は、記出力手段により前記位置を示す情報が出力されると、その後に前記撮像手段により撮像された被写体の撮像画像から抽出される色情報ごとに前記有効範囲設定することを特徴とする請求項乃至7のいずれか1項に記載の情報処理装置。
Furthermore, on the basis of the chromatic Kohan circumference of each of the color information, a position deriving means for deriving a position in the screen of the object in the next captured,
Output means for outputting information indicating the position derived by the position deriving means,
The effective range setting means, when the information indicating the position by the pre-SL output means is output, setting the effective range for each color information extracted from the captured image of a subject captured by subsequently said image pickup means The information processing apparatus according to any one of claims 1 to 7, characterized in that.
前記位置導出手段は、前記色情報のそれぞれにおける前記有効範囲の平均とばらつきに基づいて、次の撮像における前記被写体の画面内の位置を導出することを特徴とする請求項8に記載の情報処理装置。 Wherein the position deriving unit on the basis of the mean and variance of the chromatic Kohan circumference of each of the color information, according to claim 8, characterized in that to derive the position in the screen of the object in the next captured Information processing device. 更に、前記色領域抽出手段により抽出された前記予め定められた色の領域を示す情報を、前記撮像画像に合成して表示装置に表示させる表示手段を備えることを特徴とする請求項1乃至9のいずれか1項に記載の情報処理装置。 10. The display device further comprises display means for combining the captured image with the information indicating the area of the predetermined color extracted by the color area extraction means and displaying the combined image on a display device. The information processing apparatus according to any one of 1. 更に、前記色領域抽出手段により抽出された前記予め定められた色の領域に対する、前記撮像手段からの深度を、複数の前記撮像画像のそれぞれについて導出し、導出した深度に基づいて、前記予め定められた色の抽出に有効な、前記撮像手段からの深度の範囲を導出する深度導出手段を備えることを特徴とする請求項1乃至10のいずれか1項に記載の情報処理装置。 Furthermore, for the color of the region where a predetermined extracted by the color region extracting means, the depth from the imaging means to derive for each of the plurality of the captured image, based on the derived depth, the predetermined was color extraction to a valid, the information processing apparatus according to any one of claims 1 to 10, characterized in that it comprises a depth deriving means for deriving a range of depth from the imaging means. 前記予め定められた色は、肌色であることを特徴とする請求項1乃至11のいずれか1項に記載の情報処理装置。 The information processing device according to claim 1, wherein the predetermined color is a skin color. 更に、前記指定された領域に基づいて、前記撮像画像とCGとを合成する合成手段を備えることを特徴とする請求項1乃至12のいずれか1項に記載の情報処理装置。 Furthermore, on the basis of the specified realm, the information processing apparatus according to any one of claims 1 to 12, characterized in that it comprises combining means for combining the pre-Symbol IMAGING images and CG. 撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得工程と、
前記撮像画像の各画素から抽出される色情報ごとに、前記撮像画像における、前記色情報を有する画素であって、前記指定された領域の内側にある画素の数と、前記色情報を有する画素であって、前記指定された領域の外側にある画素の数の少なくとも一方に基づいて、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲を設定する有効範囲設定工程と、
前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定工程により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出工程とを備えることを特徴とする情報処理方法。
An acquisition step of acquiring an area designated in the captured image of the subject imaged by the imaging means ;
For each color information extracted from each pixel of the captured image, the number of pixels in the captured image having the color information , the number of pixels inside the specified region, and the pixel having the color information. That is, based on at least one of the number of pixels outside the designated region, the color information is a process of extracting a region of a predetermined color from an image captured by the image capturing unit, An effective range setting step of setting an effective range that is effective as the predetermined color ;
When the color information of each pixel of the image picked up by the image pickup unit is included in the effective range set for each of the color information by the effective range setting step at the position of the pixel, the pixel is set in advance as described above. An information processing method, comprising: a color area extracting step of extracting as a part of a predetermined color area.
撮像手段により撮像された被写体の撮像画像において指定された領域を取得する取得工程と、
前記撮像画像のうち、前記指定された領域に含まれる画素から抽出される色情報ごとに、当該色情報が、前記撮像手段に撮像される画像から予め定められた色の領域を抽出する処理において、前記予め定められた色として有効である有効範囲として設定する有効範囲設定工程と、
前記有効範囲設定工程により設定された前記効範囲よりも多い数の新たな有効範における色情報を生成する生成工程と、
前記撮像手段に撮像される画像の各画素の色情報が、当該画素の位置において、前記有効範囲設定工程により前記色情報ごとに設定された前記有効範囲に含まれる場合に、当該画素を前記予め定められた色の領域の一部として抽出する色領域抽出工程とを備え
前記生成工程は、前記有効範囲設定工程により設定された前記有効範囲のそれぞれから、当該有効範囲に対応する色情報を代表する1つまたは複数の色を抽出し、抽出した色に基づいて、前記新たな有効範囲における色情報を生成することを特徴とする情報処理方法。
An acquisition step of acquiring an area designated in the captured image of the subject imaged by the imaging means;
In the process of extracting a region of a predetermined color from the image captured by the image capturing unit, for each color information extracted from the pixels included in the designated region in the captured image. An effective range setting step of setting an effective range that is effective as the predetermined color,
A generation step of generating color information of the new chromatic Kohan circumference greater number than the chromatic Kohan circumference set by the effective range setting step,
When the color information of each pixel of the image captured by the image capturing unit is included in the effective range set for each of the color information by the effective range setting step at the position of the pixel, the pixel is set to the pixel in advance. And a color area extracting step of extracting as a part of a predetermined color area ,
The generating step extracts one or more colors representing color information corresponding to the effective range from each of the effective ranges set by the effective range setting step, and based on the extracted color, information processing method characterized that you generate color information in the new coverage.
請求項1乃至13のいずれか1項に記載の情報処理装置の各手段としてコンピュータを機能させることを特徴とするプログラム。   A program that causes a computer to function as each unit of the information processing apparatus according to any one of claims 1 to 13.
JP2016008941A 2015-10-26 2016-01-20 Information processing apparatus, information processing method, and program Active JP6700804B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US15/332,985 US10445612B2 (en) 2015-10-26 2016-10-24 Information processing apparatus, information processing method, and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2015209843 2015-10-26
JP2015209843 2015-10-26

Publications (2)

Publication Number Publication Date
JP2017084319A JP2017084319A (en) 2017-05-18
JP6700804B2 true JP6700804B2 (en) 2020-05-27

Family

ID=58712056

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016008941A Active JP6700804B2 (en) 2015-10-26 2016-01-20 Information processing apparatus, information processing method, and program

Country Status (1)

Country Link
JP (1) JP6700804B2 (en)

Also Published As

Publication number Publication date
JP2017084319A (en) 2017-05-18

Similar Documents

Publication Publication Date Title
US10701332B2 (en) Image processing apparatus, image processing method, image processing system, and storage medium
WO2018103244A1 (en) Live streaming video processing method, device, and electronic apparatus
US10600169B2 (en) Image processing system and image processing method
US9679415B2 (en) Image synthesis method and image synthesis apparatus
JP5818857B2 (en) Information processing apparatus and control method thereof
EP2879097A1 (en) Three-dimensional user-interface device, and three-dimensional operation method
JP6882868B2 (en) Image processing equipment, image processing method, system
JP2022118201A (en) Image processing system, image processing method, and program
CN109816766A (en) Image processing apparatus, image processing method and storage medium
KR102382247B1 (en) Image processing apparatus, image processing method, and computer program
US20230024396A1 (en) A method for capturing and displaying a video stream
CN108076359B (en) Business object display method and device and electronic equipment
JP6362401B2 (en) Image processing apparatus and image processing apparatus control method
KR101308184B1 (en) Augmented reality apparatus and method of windows form
WO2015072091A1 (en) Image processing device, image processing method, and program storage medium
JP6700804B2 (en) Information processing apparatus, information processing method, and program
JP4745724B2 (en) Image processing method and image processing apparatus
US10445612B2 (en) Information processing apparatus, information processing method, and storage medium
JP6103942B2 (en) Image data processing apparatus and image data processing program
KR20140119325A (en) Apparatus for redeeming noise of depth image and method thereof
KR20150116032A (en) Method of providing augmented reality
US10880533B2 (en) Image generation apparatus, image generation method, and storage medium, for generating a virtual viewpoint image
JP7422454B2 (en) Information processing device, information processing method and program
JP2024041435A (en) Image processing device, image processing method, and program
JP2022131197A (en) Image processing apparatus, image processing method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20190111

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20191120

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20191126

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20200127

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200501

R151 Written notification of patent or utility model registration

Ref document number: 6700804

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151