JP5474169B2 - Image processing apparatus and image processing method - Google Patents
Image processing apparatus and image processing method Download PDFInfo
- Publication number
- JP5474169B2 JP5474169B2 JP2012260297A JP2012260297A JP5474169B2 JP 5474169 B2 JP5474169 B2 JP 5474169B2 JP 2012260297 A JP2012260297 A JP 2012260297A JP 2012260297 A JP2012260297 A JP 2012260297A JP 5474169 B2 JP5474169 B2 JP 5474169B2
- Authority
- JP
- Japan
- Prior art keywords
- region
- motion vector
- image
- area
- space 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.)
- Expired - Fee Related
Links
Images
Description
本発明は、現実空間画像と仮想空間画像との合成技術に関するものである。 The present invention relates to a technique for synthesizing a real space image and a virtual space image.
実写風景の上に、コンピュータグラフィックス(CG)を重畳して体験者に提示することで、この体験者にあたかもその場に仮想の物体が存在するかのような体験を行わせる複合現実感(Mixed Reality:MR)技術が従来から提案されている。 By presenting the computer graphics (CG) superimposed on the live-action scene and presenting it to the experiencer, this experience makes the experience as if a virtual object existed on the spot. Mixed Reality (MR) technology has been proposed.
MR技術を用いて体験者に臨場感豊かな体験をさせる為には、実写風景の上に単純にCGを重畳して表示するだけでなく、体験者が実際にCGで描画される仮想物体に触ったり操作する(しているように体感させる)といったインタラクションが重要になる。そして、このようなインタラクションを実現するめには、仮想物体よりも手前(前景)に仮想物体を操作する体験者の手など(被写体)を表示することが必要である。なぜなら、仮想物体よりも手前にあるべき被写体が仮想物体によって隠されてしまうと、仮想物体との距離感や現実感が破綻し、臨場感を損ねてしまうからである。 In order to give the experience-rich experience to the experience using MR technology, not only simply superimposing and displaying the CG on the live-action scenery, but also the virtual object that the experience is actually drawn by CG Interactions such as touching and operating (making you feel as you do) are important. In order to realize such an interaction, it is necessary to display the hand (subject) of the user who operates the virtual object in front of the virtual object (foreground). This is because if the subject that should be in front of the virtual object is hidden by the virtual object, the sense of distance from the virtual object and the sense of reality will break down, impairing the sense of reality.
このような課題を解決するために、本願出願人は特許文献1において、最前景とすべき被写体の画像を仮想物体によって隠さないようにする技術を提案した。係る技術では、背景と被写体とを実写画像として取得し、この実写画像から、予め手作業でシステムに登録した「仮想物体より手前に表示すべき被写体(被写体検出情報としての色情報を有する領域)」を被写体領域として抽出する。そして、被写体領域には仮想物体の描画を禁止する。係る技術により、最前景となるべき被写体が仮想物体で隠されることなく、仮想物体よりも手前にあるように表示され、臨場感の高い複合現実感体験を行うことが可能となる。 In order to solve such problems, the applicant of the present application has proposed a technique in Patent Document 1 that prevents an image of a subject to be the foreground from being hidden by a virtual object. In such a technique, the background and the subject are acquired as a live-action image, and the “subject to be displayed in front of the virtual object (area having color information as subject detection information) previously registered in the system manually from the live-action image. "Is extracted as a subject area. Then, drawing of a virtual object is prohibited in the subject area. With such a technique, the subject that should be the foreground is displayed so as to be in front of the virtual object without being hidden by the virtual object, and it is possible to perform a mixed reality experience with high presence.
図1は、現実空間画像、仮想空間画像、現実空間画像上に仮想空間画像を重畳させた合成画像の一例を示す図である。 FIG. 1 is a diagram illustrating an example of a composite image in which a virtual space image is superimposed on a real space image, a virtual space image, and a real space image.
図1において101は現実空間画像で、係る現実空間画像101内には、被写体としての手の領域150が含まれている。102は、現実空間画像101上に重畳させる仮想空間画像である。103は、現実空間画像101上に仮想空間画像102を重畳させた合成画像である。合成画像103を生成する際には、現実空間画像101上において手の領域150に対しては仮想空間画像102は重畳させていないので、結果として合成画像103上には、手の領域150がそのまま描画されている。
特許文献1に開示されている複合現実感体験システムは、体験者の見ている被写体が単色である場合には良好に動作する。しかしながら、被写体が異なる複数の色を有する場合、ある色を有する領域のみしかCGの描画を禁止できないため、被写体の一部分だけがCG内に浮いているように表示されてしまい、体験者の現実感を損なうことがあった。 The mixed reality experience system disclosed in Patent Document 1 operates well when the subject viewed by the experience person is monochromatic. However, when the subject has a plurality of different colors, only the area having a certain color can be prohibited from drawing CG, so that only a part of the subject is displayed as floating in the CG, and the experience of the user is felt. Could be damaged.
図2は、複数の色を有する被写体を含む現実空間画像、仮想空間画像、そして係る現実空間画像上に仮想空間画像を重畳させた合成画像の一例を示す図である。 FIG. 2 is a diagram illustrating an example of a real space image including a subject having a plurality of colors, a virtual space image, and a composite image in which the virtual space image is superimposed on the real space image.
図2において201は現実空間画像で、係る現実空間画像201内には、被写体としての手の領域150a、腕の領域150bが含まれている。それぞれの領域150a、150bは異なる色を有する領域である。202は、現実空間画像201上に重畳させる仮想空間画像である。203は、現実空間画像201上に仮想空間画像202を重畳させた合成画像である。ここでは、手の領域150aの色を有する領域のみを、仮想空間画像202の重畳対象外としているので、図2に示す如く、本来は仮想空間画像202を重畳させない腕の領域150bには仮想空間画像202が描画されてしまっている。
In FIG. 2,
このような技術的背景から、次のようなことな望まれている。即ち、体験者の手や指定した領域を実写画像より抽出した後、抽出した領域に付属する領域(体験者の腕等)を更に抽出する。そして、抽出したそれぞれの領域をマージした被写体領域(手と腕)については仮想空間画像を重畳させないように、現実空間画像上に仮想空間画像を重畳させる。 From such a technical background, the following is desired. That is, after the hands of the experience person and the designated area are extracted from the live-action image, areas (such as the hands of the experience person) attached to the extracted area are further extracted. Then, the virtual space image is superimposed on the real space image so that the virtual space image is not superimposed on the subject region (hand and arm) obtained by merging the extracted regions.
本発明は以上の問題に鑑みてなされたものであり、現実空間画像において、仮想空間画像を重畳させない領域を適切に設定するための技術を提供することを目的とする。 The present invention has been made in view of the above problems, and an object thereof is to provide a technique for appropriately setting a region in which a virtual space image is not superimposed in a real space image.
本発明の目的を達成するために、例えば、本発明の画像処理装置は以下の構成を備える。 In order to achieve the object of the present invention, for example, an image processing apparatus of the present invention comprises the following arrangement.
即ち、複数のフレームからなる現実空間画像を取得する手段と、
前記現実空間画像の注目フレームにおいて、所定の条件を満たす画素で構成される領域を第1の領域として設定する第1の設定手段と、
前記注目フレーム内において、前記第1の領域の動きベクトルと前記注目フレーム内の前記第1の領域以外の他の領域の動きベクトルとを取得する取得手段と、
前記取得した他の領域の動きベクトルの大きさが閾値以上であるか否かを判断する第1の判断手段と、
前記第1の判断手段により、前記他の領域の動きベクトルの大きさが閾値以上であると判断された場合に、該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似しているかを判断する第2の判断手段と、
前記第2の判断手段により、該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似していると判断された場合に、該他の領域を第2の領域として設定する第2の設定手段と、
前記設定された前記注目フレーム内の前記第1の領域と前記第2の領域以外の領域に、仮想空間画像を合成する合成手段とを備えることを特徴とする。
That is, a means for acquiring a real space image composed of a plurality of frames,
In the frame of interest of the real space image, a first setting means for setting a region composed of a predetermined pixel satisfying a first region,
Within the frame of interest, and acquisition means you get a motion vector of another region other than the first region of the target frame the motion vector of the first region,
First determination means for determining whether or not the magnitude of a motion vector of the acquired other region is greater than or equal to a threshold ;
When the first determination unit determines that the magnitude of the motion vector of the other area is equal to or greater than a threshold, the motion vector of the other area is similar to the motion vector of the first area. A second judging means for judging whether or not
A second region that sets the other region as a second region when the second determination unit determines that the motion vector of the other region is similar to the motion vector of the first region; Setting means,
To the first region and the region other than the second region of the target frame that have been pre-Symbol set, and wherein the obtaining Bei a synthesizing means for synthesizing the virtual space image.
本発明の構成によれば、現実空間画像において、仮想空間画像を重畳させない領域を適切に設定することができる。 According to the configuration of the present invention, it is possible to appropriately set a region in which a virtual space image is not superimposed in a real space image.
以下、添付図面を参照し、本発明の好適な実施形態について説明する。なお、以下説明する実施形態は、本発明を具体的に実施した場合の一例を示すもので、特許請求の範囲に記載の構成の具体的な実施例の1つである。 Preferred embodiments of the present invention will be described below with reference to the accompanying drawings. The embodiment described below shows an example when the present invention is specifically implemented, and is one of the specific examples of the configurations described in the claims.
[第1の実施形態]
本実施形態では、現実空間画像上に仮想空間画像を重畳させる場合に、現実空間画像内に「手」の領域と「腕」の領域とが含まれている場合には、それぞれの領域をマージして1つの被写体の領域(合成領域)を生成する。そして、係る被写体の領域を常に仮想空間の画像よりも手前に表示するよう、係る重畳の処理を制御する。詳しくは後述するが、被写体の領域は、「手」の領域と「腕」の領域とをマージしたものに限定するものではなく、どのような領域をマージして被写体の領域を形成しても良い。即ち、以下の説明は、被写体の領域が異なる複数の画素値で表示されるようなものであれば、どのような被写体の領域でも良い。
[First Embodiment]
In this embodiment, when a virtual space image is superimposed on a real space image, if the “hand” region and the “arm” region are included in the real space image, the respective regions are merged. Thus, a single subject area (composite area) is generated. Then, the superimposition process is controlled so that the subject area is always displayed in front of the image in the virtual space. As will be described in detail later, the subject area is not limited to the merged “hand” area and “arm” area, and any area may be merged to form the subject area. good. That is, in the following description, any subject area may be used as long as the subject area is displayed with a plurality of different pixel values.
図4は、現実空間の画像上に仮想空間の画像が重畳された合成画像を、ユーザがHMDを介して観察している様子を示す図である。 FIG. 4 is a diagram illustrating a state in which the user observes the composite image in which the virtual space image is superimposed on the real space image via the HMD.
図4に示すように、ユーザ401はHMD390を介して、撮像部301が撮像した現実空間の画像上に、センサ404による計測結果に基づいて生成した仮想空間の画像、を重畳させた合成画像(複合現実空間の画像)を観察している。係る観察中に自身の手405や自身の腕406が撮像部301の視野範囲409に入った場合、HMD390に表示される複合現実空間の画像中には手405、腕406が表示される。即ち、前景となる現実空間の画像上の手405、腕406の領域には仮想空間の画像(仮想物体408の一部)は重畳させないようにする。これを実現するために、前景とすべき現実の被写体は「ユーザ401の手405の領域、腕406の領域」、背景とすべき現実の対象物は「壁や鉢植え等の背景現実物体407」、等の領域の区別を行う。
As shown in FIG. 4, a
図3は、本実施形態に係るシステムの機能構成例を示すブロック図である。 FIG. 3 is a block diagram illustrating a functional configuration example of the system according to the present embodiment.
図3に示す如く、本実施形態に係るシステムは、HMD390、位置姿勢計測部306、画像処理装置300により構成されている。そして、HMD390、位置姿勢計測部306はそれぞれ、画像処理装置300に接続されている。
As shown in FIG. 3, the system according to the present embodiment includes an
先ず、HMD390について説明する。
First, the
HMD390は、頭部装着型表示装置の一例としてのものであり、撮像部301と表示部309とで構成されている。
The
撮像部301は、現実空間の動画像を撮像するビデオカメラであり、撮像した各フレームの画像(現実空間画像)は、画像信号として後段の画像処理装置300に入力される。撮像部301は、ユーザがHMD390を自身の頭部に装着した場合に、このユーザの目の近くに位置するように、HMD390に取り付けられる。更に、取り付ける(撮像部301の)姿勢は、HMD390を頭部に装着したユーザの正面方向(視線方向)に略一致するような姿勢である。これにより、撮像部301は、ユーザの頭部の位置姿勢に応じて見える現実空間の動画像を撮像することができる。従って、以下の説明では、撮像部301を「ユーザの視点」と呼称する場合もある。
The
表示部309は、例えば、液晶画面であり、HMD390を頭部に装着したユーザの眼前に位置するようにHMD390に取り付けられたものである。画像処理装置300からHMD390に対して送出される映像信号に基づいた画像は、係る表示部309に表示される。これにより、HMD390を頭部に装着したユーザの眼前には、画像処理装置300から送信された映像信号に基づいた画像が提示されることになる。
The
本実施形態では、撮像部301と表示部309とはHMD390に内蔵されており、且つ撮像部301と表示部309とは、表示部309の光学系と撮像部301の撮像系とが一致するようにHMD390に内蔵されている。
In the present embodiment, the
次に、位置姿勢計測部306について説明する。
Next, the position /
位置姿勢計測部306は、撮像部301の位置姿勢を計測するためのものであり、例えば、位置姿勢計測部306には、磁気センサや光学式センサ等のセンサシステムを適用することができる。例えば、位置姿勢計測部306に磁気センサを適用する場合、位置姿勢計測部306は次のような動作を行うことになる。
The position /
先ず、位置姿勢計測部306に磁気センサを適用する場合、位置姿勢計測部306は、次のような各部によって構成されることになる。
First, when a magnetic sensor is applied to the position /
・ 周囲に磁界を発生させるトランスミッタ
・ トランスミッタが発生する磁界中で、自身の位置姿勢に応じた磁界の変化を検知するレシーバ
・ トランスミッタの動作制御を行うと共に、レシーバによる計測結果に基づいて、レシーバのセンサ座標系における位置姿勢情報を生成するセンサコントローラ
トランスミッタは現実空間中の所定の位置に配置する。そしてレシーバは、撮像部301に取り付ける。トランスミッタが磁界を発生させると、レシーバは、自身の位置姿勢(撮像部301の位置姿勢)に応じた磁界の変化を検知し、検知した結果を示す信号をセンサコントローラに送出する。センサコントローラは、係る信号に基づいて、レシーバのセンサ座標系における位置姿勢を示す位置姿勢情報を生成する。ここで、センサ座標系とは、トランスミッタの位置を原点とし、係る原点で互いに直交する3軸をそれぞれx軸、y軸、z軸とする座標系のことである。そして、センサコントローラは、求めた位置姿勢情報を、後段の画像処理装置300に対して送出する。
A transmitter that generates a magnetic field in the surroundings.A receiver that detects changes in the magnetic field according to its position and orientation in the magnetic field generated by the transmitter. A sensor controller that generates position and orientation information in the sensor coordinate system The transmitter is placed at a predetermined position in the real space. The receiver is attached to the
しかし、位置姿勢計測部306にはどのようなセンサシステムを適用しても良く、位置姿勢計測部306に何れのセンサシステムを適用しても、その動作については周知であるので、これについての説明は省略する。また、センサシステムの代わりに、撮像部301が撮像した画像を用いて撮像部301の位置姿勢を求める方法を用いても良く、その場合には、位置姿勢計測部306は省略し、係る方法を実行する演算部を後段の画像処理装置300内に設ければよい。
However, any sensor system may be applied to the position /
次に、画像処理装置300について説明する。図3に示す如く、画像処理装置300は、撮影画像取込部302、キー領域抽出部303、動きベクトル検出部304、被写体領域抽出部305、画像合成部308、画像生成部307、記憶装置310、により構成されている。以下、画像処理装置300を構成する各部について説明する。
Next, the
撮影画像取込部302は、撮像部301から送出された各フレームの画像の画像信号を受けると、これを順次ディジタルデータに変換し、動きベクトル検出部304、キー領域抽出部303、画像合成部308に送出する。
When the captured
キー領域抽出部303は、撮影画像取込部302から受けたディジタルデータが示す現実空間画像から、キー領域(第1の領域)を抽出する。ここで、キー領域とは、予め定められた画素値を有する画素で構成される領域である。本実施形態では、ユーザの手の色を示す画素値を有する画素で構成される領域をキー領域とする。そして、キー領域抽出部303は、現実空間画像においてキー領域を特定する為のデータであるキー領域データを生成し、生成したキー領域データを、被写体領域抽出部305に送出する。
The key
動きベクトル検出部304は、撮影画像取込部302から受けた現実空間画像(現フレーム)と、この現実空間画像よりも1つ前のフレームの現実空間画像とを用いて、現フレームにおける現実空間画像を構成する画素毎に、フレーム間の動きベクトルを求める。そして画素毎に求めた動きベクトルのデータを、被写体領域抽出部305に送出する。
The motion
動きベクトル検出部304が行う動きベクトルの検出は、既存のブロックマッチング法によるオプティカルフローを算出することで実行することができる。本実施形態では、動きベクトルの検出(計算)をブロックマッチング法で行うものとするが、以下の説明は係る方法を用いることに限定するものではなく、フレーム間の動きベクトルを検出することができる方法であれば如何なる方法を用いても良い。例えば、動きベクトルの検出を勾配法によるオプティカルフローを用いることで行っても良い。
The motion vector detection performed by the motion
被写体領域抽出部305は、キー領域抽出部303から入力されたキー領域データと、動きベクトル検出部304から入力された動きベクトルのデータと、を用いて、現実空間画像中における被写体の領域(被写体領域)を抽出する。係る被写体領域とは上述の通り、ユーザの手の領域と腕の領域とをマージした領域である。そして、抽出した被写体領域を特定するためのデータである被写体領域データを画像合成部308に送出する。
The subject
画像生成部307は先ず、記憶装置310が保持している仮想空間のデータを用いて、仮想空間を構築する。仮想空間のデータには、仮想空間中に配置する仮想物体についてのデータ、仮想空間中に配置する光源のデータなどが含まれている。仮想物体のデータには、例えば、仮想物体がポリゴンで構成されている場合には、ポリゴンの法線ベクトルデータ、ポリゴンの色データ、ポリゴンを構成する各頂点の座標位置データ等が含まれている。また、仮想物体に対してテクスチャマッピングを施す場合には、テクスチャマップデータも、仮想物体のデータに含まれる。また、光源のデータには、例えば、光源の種類を示すデータ、光源の配置位置姿勢を示すデータ、等が含まれていることになる。
The
そして画像生成部307は、仮想空間の構築後、係る仮想空間中に、位置姿勢計測部306から受けた位置姿勢情報が示す位置姿勢で視点を設定する。そして画像生成部307は、係る視点から見える仮想空間の画像(仮想空間画像)を生成する。なお、所定の位置姿勢を有する視点から見える仮想空間の画像を生成する為の技術については周知であるので、これについての説明は省略する。そして、生成した仮想空間画像のデータを、画像合成部308に送出する。
Then, after constructing the virtual space, the
画像合成部308は、撮影画像取込部302から受けたディジタルデータが示す現実空間画像上に、画像生成部307から受けたデータが示す仮想空間画像を重畳させる処理を行う。係る重畳処理では、被写体領域抽出部305から受けた被写体領域データが示す被写体領域には仮想空間画像が重畳されないようにする。そして画像合成部308はこのような重畳処理によって生成された複合現実空間の画像を映像信号に変換してからHMD390が有する表示部309に送出する。これにより、HMD390を頭部に装着したユーザの眼前には、自身の視点の位置姿勢に応じた複合現実空間の画像が提示されることになる。更に係る複合現実空間の画像において被写体領域(自身の手と腕の領域)には仮想空間画像は重畳されていない。
The
なお、本実施形態では、複合現実空間の画像は、HMD390が有する表示部309に送出するものとしているが、複合現実空間の画像の送出先は特に限定するものではない。例えば、画像処理装置300にCRTや液晶画面等により構成されている表示装置を接続し、この表示装置に複合現実空間の画像を出力するようにしても良い。
In the present embodiment, the mixed reality space image is sent to the
記憶装置310は、上述のように、仮想空間のデータを保持しており、画像生成部307は係るデータを適宜読み出して用いる。更に記憶装置310には、ユーザの手の色を示す画素値のデータ(キーカラーデータ)も記憶保持されている。
As described above, the storage device 310 holds virtual space data, and the
ここで、キーカラーデータについて説明する。キーカラーデータは、多次元色空間における座標値として記述することができる。一般によく知られている表色系の種類には、RGB、YIQ、YCbCr、YUV、HSV、Lu*v*、La*b*など様々なものがある(日本規格協会 JIS色彩ハンドブック)。 Here, the key color data will be described. The key color data can be described as coordinate values in a multidimensional color space. There are various well-known types of color systems such as RGB, YIQ, YCbCr, YUV, HSV, Lu * v *, La * b * (Japanese Standards Association JIS Color Handbook).
キーカラーデータには、被写体の色彩特性に合わせて適当なものを任意に用いてよいが、照明条件の相違による被写体の色彩特性の変化を相殺するために、輝度情報と色相情報とに分離する形式の表色系を用い、色相情報だけを用いることが望ましい。このような表色系の代表的なものとしてはYIQやYCbCrが一般的である。本実施形態では、YCbCr表色系を用いる。従って、記憶装置310に記憶保持されているキーカラーデータとは、ユーザの手の色を予め取得しておき、取得した色をYcbCr表色系のデータとして変換したものである。 The key color data may be arbitrarily selected according to the color characteristics of the subject, but is separated into luminance information and hue information in order to offset changes in the color characteristics of the subject due to differences in illumination conditions. It is desirable to use a format color system and only use hue information. Typical examples of such a color system are YIQ and YCbCr. In this embodiment, the YCbCr color system is used. Accordingly, the key color data stored and held in the storage device 310 is obtained by acquiring the color of the user's hand in advance and converting the acquired color as YcbCr color system data.
次に、画像処理装置300が複合現実空間の画像を生成し、生成した複合現実空間の画像をHMD390が有する表示部309に送出する為の一連の処理について、同処理のフローチャートを示す図5を用いて、以下説明する。
Next, FIG. 5 showing a flowchart of the processing for a series of processes for the
先ずステップS501では、撮影画像取込部302は、撮像部301から送出された現実空間画像をディジタルデータとして取得する。
First, in step S <b> 501, the captured
次に、ステップS502では、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像から、キー領域(第1の領域)を抽出する。そして、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像においてキー領域を特定する為のデータであるキー領域データを生成し、生成したキー領域データを、被写体領域抽出部305に送出する。
Next, in step S502, the key
また動きベクトル検出部304は、ステップS501で撮影画像取込部302が取得した現フレームの現実空間画像と、現フレームより1フレーム前の現実空間画像とを用いて、現フレームの現実空間画像を構成する画素毎にフレーム間の動きベクトルを求める。そして動きベクトル検出部304は、画素毎に求めた動きベクトルのデータを、被写体領域抽出部305に送出する。
In addition, the motion
そして被写体領域抽出部305は、キー領域抽出部303が生成したキー領域データと、動きベクトル検出部304が生成した動きベクトルのデータと、を用いて、ステップS501で撮影画像取込部302が取得した現実空間画像中の被写体領域を抽出する。そして、被写体領域抽出部305は、ステップS501で撮影画像取込部302が取得した現実空間画像中の被写体領域をマスクしたマスク画像のデータを、上記被写体領域データとして生成する。本実施形態では上述の通り、被写体とはユーザの手と腕であるので、現実空間画像から手と腕が存在する領域を抽出し、その領域からマスク画像を生成する。ステップS502における処理の詳細については後述する。
The subject
次にステップS503では、画像生成部307は、位置姿勢計測部306から位置姿勢情報を取得する。係る位置姿勢情報は上述の通り、HMD390を頭部に装着するユーザの視点の位置姿勢であり、撮像部301の位置姿勢である。
In step S <b> 503, the
次にステップS504では、画像生成部307は、記憶装置310から仮想空間のデータを読み出し、読み出したデータに基づいて仮想空間を構築する。そして画像生成部307は、仮想空間の構築後、係る仮想空間中に、ステップS503において位置姿勢計測部306から取得した位置姿勢情報が示す位置姿勢で視点を設定する。そして画像生成部307は、係る視点から見える仮想空間の画像(仮想空間画像)を生成する。
In step S504, the
次にステップS505では、画像合成部308は、ステップS501で撮影画像取込部302が取得したディジタルデータが示す現実空間画像上に、ステップS504で画像生成部307が生成した仮想空間画像を重畳させる処理を行う。係る重畳処理では、ステップS502で被写体領域抽出部305が生成した被写体領域データが示す被写体領域には仮想空間画像が重畳されないようにする。ステップS505における処理の詳細については後述する。
In step S505, the
次にステップS506では、画像合成部308は、ステップS505における重畳処理によって生成した複合現実空間の画像を映像信号に変換してからHMD390が有する表示部309に送出する。
In step S506, the
次に、画像処理装置300が有する不図示の操作部を介して本処理の終了指示がユーザから入力された、若しくは本処理の終了条件が満たされた場合にはステップS507を介して本処理が終了する。一方、画像処理装置300が有する不図示の操作部を介して本処理の終了指示がユーザから入力されていないし、本処理の終了条件も満たされていない場合には、処理はステップS507を介してステップS501に戻す。そして、次のフレームの複合現実空間の画像を表示部309に送出すべく、ステップS501以降の処理を行う。
Next, when an instruction to end the process is input from the user via an operation unit (not shown) included in the
次に、上記ステップS502における処理の詳細について説明する。図6は、上記ステップS502における処理の詳細を示すフローチャートである。 Next, details of the processing in step S502 will be described. FIG. 6 is a flowchart showing details of the processing in step S502.
先ずステップS601では、キー領域抽出部303は、記憶装置310からキーカラーデータを読み出す。そして、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像を構成する各画素のうち、記憶装置310から読み出したキーカラーデータが示す画素値を有する画素の集合をキー領域として抽出する。
First, in step S <b> 601, the key
具体的には、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像を構成する各画素のうち、記憶装置310から読み出したキーカラーデータが示す画素値を有する画素については「1」を割り当てる。一方、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像を構成する各画素のうち、記憶装置310から読み出したキーカラーデータが示す画素値を有していない画素については「0」を割り当てる。即ち、現実空間画像において、手の領域を構成する各画素については「1」を割り当て、それ以外の領域を構成する各画素については「0」を割り当てる。
Specifically, the key
ここで、ステップS601における処理をより詳細に説明する。図7は、上記ステップS601における処理の詳細を示すフローチャートである。なお、図7のフローチャートは、現実空間画像中の画像座標(i,j)における画素について行う処理のフローチャートである。従って、実際にステップS601では、図7のフローチャートに従った処理を、現実空間画像を構成する各画素について行うことになる。 Here, the process in step S601 will be described in more detail. FIG. 7 is a flowchart showing details of the processing in step S601. Note that the flowchart in FIG. 7 is a flowchart of processing performed on a pixel at image coordinates (i, j) in the real space image. Therefore, in step S601, the process according to the flowchart of FIG. 7 is actually performed for each pixel constituting the real space image.
先ずステップS701では、キー領域抽出部303は、ステップS501で撮影画像取込部302が取得した現実空間画像において画像座標(i、j)における画素の画素値(本実施形態ではRGB値で表されているものとする)をYCrCb値に変換する。画像座標(i、j)における画素のR値をR(i、j)、G値をG(i、j)、B値をB(i、j)とする。この場合、ステップS701では、RGB値をYCrCb値に変換する為の関数color_conversion()を用いて、R(i、j)、G(i、j)、B(i、j)を変換し、Y値、Cr値、Cb値を得る。
First, in step S701, the key
次にステップS702では、ステップS701で求めたY、Cr、Cbのそれぞれの値が表現する色が、記憶装置310から読み出したキーカラーデータが示す色に略同じであるのか否かを判断する。例えば、ステップS701で求めたY、Cr、Cbのそれぞれの値が表現する色が、記憶装置310から読み出したキーカラーデータが示す色に略同じであるのか否かを、関数Key_area_func()を用いて判断する。係る関数Key_area_func()は、略同じであれば1を返し、略同じでなければ0を返す関数である。 Next, in step S702, it is determined whether or not the colors represented by the respective values Y, Cr, and Cb obtained in step S701 are substantially the same as the colors indicated by the key color data read from the storage device 310. For example, the function Key_area_func () is used to determine whether or not the colors represented by the values Y, Cr, and Cb obtained in step S701 are substantially the same as the colors indicated by the key color data read from the storage device 310. Judgment. The function Key_area_func () is a function that returns 1 if substantially the same, and returns 0 if not substantially the same.
ここで、関数Key_area_func()による判断方法としては、例えば、Cb、Crで規定されるCbCr平面上における座標値(Cr、Cb)が、キーカラーデータの色分布の領域に属するか否かを判定する。判定結果は、例えば、キーカラーデータの色分布に属するのであれば1、属さないのであれば0と二値で表してもよいが、属する度合いを0から1までの連続値でもって表現するようにしても良い。 Here, as a determination method using the function Key_area_func (), for example, it is determined whether or not the coordinate values (Cr, Cb) on the CbCr plane defined by Cb, Cr belong to the color distribution area of the key color data. To do. The determination result may be expressed as a binary value, for example, 1 if it belongs to the color distribution of the key color data, or 0 if it does not belong, but the degree of belonging is expressed as a continuous value from 0 to 1. Anyway.
そして係る関数Key_area_func()が返す値は、配列Key_area(i、j)に代入される。この配列key_area(i、j)は、画像座標(i、j)における画素がキー領域を構成する画素であるか否かを示す値を格納する為のものである。 The value returned by the function Key_area_func () is assigned to the array Key_area (i, j). This array key_area (i, j) is for storing a value indicating whether or not the pixel at the image coordinate (i, j) is a pixel constituting the key area.
そして、全てのi、jについて図7のフローチャートに従った処理を行うことで、配列Key_areaには、現実空間画像を構成する各画素について「1」若しくは「0」が保持されることになる。係る配列Key_areaが、上記キー領域データとなる。 Then, by performing the processing according to the flowchart of FIG. 7 for all i and j, the array Key_area holds “1” or “0” for each pixel constituting the real space image. The array Key_area is the key area data.
なお、本実施形態では、撮影画像取込部302が取得した現実空間画像を構成する各画素の画素値はRGBで表されているものとしているが、YIQやYUVで表されていても良い。その場合には、ステップS701における処理を省略し、ステップS702において(Cb、Cr)の代わりにそれぞれIQ空間やUV空間における座標値を用いればよい。
In the present embodiment, the pixel value of each pixel constituting the real space image acquired by the captured
以上説明したように、キー領域抽出部303は、撮影画像取込部302が取得した現実空間画像を構成する各画素が、キー領域(手)を構成するものであるのか否かを示すキー領域データを生成する。
As described above, the key
図6に戻って、次にステップS602では、動きベクトル検出部304は、ステップS501で撮影画像取込部302が取得した現フレームの現実空間画像を構成する画素毎にフレーム間の動きベクトルを求める。なお、本実施形態では、動きベクトルは現実空間画像を構成する各画素について求めるものとしたが、これに限定するものではなく、現実空間画像上の複数箇所における動きベクトルを求めれば良い。例えば、キー領域の近辺のみの画素について動きベクトルを求めるようにしても良い。これにより動きベクトルを求める為に要する時間コストを削減することができる。
Returning to FIG. 6, in step S602, the motion
次にステップS603では、被写体領域抽出部305は、ステップS602で求めた各画素についての動きベクトルのうち、キー領域以外(第1の領域以外)の領域(非キー領域、他領域)を構成する各画素について求めた動きベクトルの大きさの平均を求める。そして求めた平均(代表動きベクトルの大きさ)が、予め定めた閾値以上であるか否かを判断する。係る判断の結果、求めた平均が閾値以上であれば処理をステップS604に進め、閾値未満である場合には処理をステップS606に進める。
In step S603, the subject
なお、ここで述べている「動きベクトルの大きさ」とは、動きベクトル距離成分を示している。もちろん、動きベクトルの角度成分から「大きさ」を求めても良い。このように、動きベクトルの大きさを求めるための方法については特に限定するものではない。ここで、ステップS603で行う判断処理の意義について説明する。 The “motion vector magnitude” described here indicates a motion vector distance component. Of course, the “size” may be obtained from the angle component of the motion vector. Thus, the method for obtaining the magnitude of the motion vector is not particularly limited. Here, the significance of the determination process performed in step S603 will be described.
手の領域の動きベクトルと類似度の高い領域は、腕の領域として抽出する。これは手と腕はほとんどの場合において一緒に動作しているので、それぞれの動きベクトルには類似性があるということから実現している。ただし手だけが動いて腕はほとんど動かないという場合も考えられる。例えば、手首のみを回した場合がこれに相当する。この場合、そのまま被写体領域を抽出しようとしても腕は抽出されない。また、手も腕も全く動かずさらには撮像部301も動かない場合は、動きベクトルは算出されないので正常に被写体領域を抽出することができない。
A region having a high similarity to the motion vector of the hand region is extracted as an arm region. This is achieved because the hand and arm are moving together in most cases, and the motion vectors are similar. However, there are cases where only the hand moves and the arm hardly moves. For example, this is the case when only the wrist is turned. In this case, the arm is not extracted even if the subject area is extracted as it is. Further, when neither the hand nor the arm moves at all, and further, the
そこで本実施形態では、ステップS603において、手が動いていない場合と、手と腕と撮像部301の全部が動いていない場合とを判断する処理を行う。つまり、非キー領域の動きベクトルの大きさがほとんど0の場合は、腕の領域が動いていないか、手と腕と撮像部301の全部が動いていないと判断し、その場合はステップS606の処理を行うことで問題を回避する。ステップS606における処理については後述する。
Therefore, in the present embodiment, in step S603, processing is performed to determine whether the hand is not moving and whether the hand, the arm, and all of the
次にステップS604では、被写体領域抽出部305は、ステップS601で抽出したキー領域と、ステップS602で求めた動きベクトルと、に基づいて、キー領域にマージすべき第2の領域を特定する。そして特定した第2の領域とキー領域とをマージした領域を被写体領域として得る。本実施形態では、腕の領域を第2の領域として特定する。そして、特定した腕の領域を、キー領域としての手の領域にマージすることで被写体領域を得る。
In step S604, the subject
ここで、ステップS604における処理の詳細について説明する。図8は、上記ステップS604における処理の詳細を示すフローチャートである。 Here, details of the processing in step S604 will be described. FIG. 8 is a flowchart showing details of the processing in step S604.
先ず、ステップS801では、被写体領域抽出部305は、各動きベクトルを、距離成分と角度成分を特徴としてそれぞれの特徴軸で正規化する。これにより各特徴の単位の違いにより値の重み付けがなされてしまうことを回避する(一般的な正規化)。例えば、特徴のパターン相互の距離を最小にすることで正規化を行う。
First, in step S801, the subject
次に、ステップS802では、被写体領域抽出部305は、ステップS801で正規化された動きベクトルのうち、キー領域の特徴のみを特徴空間上でクラスタリングする。つまり、図9に示すようにベクトル距離成分軸(縦軸)と角度成分軸(横軸)とで規定される特徴空間上で、キー領域の特徴をクラスタリングする(特徴パターンの学習)。図9は、キー領域の特徴のみを特徴空間上でクラスタリングした結果の例を示す図である。
Next, in step S802, the subject
ここで必要に応じてクラスタリングされたキー領域の特徴のうちノイズ成分を除外してもよい。具体的には、特徴の数の少ないクラスや距離成分の小さいクラスなどはノイズとして除外する。 Here, noise components may be excluded from the features of the clustered key regions as necessary. Specifically, a class having a small number of features or a class having a small distance component is excluded as noise.
また、キー領域の特徴をクラスタリングするとしたが、クラスリングする特徴をキー領域のエッジ領域のみの特徴とすることでノイズを除外していもよい。エッジ領域の抽出は既存のラベリングアルゴリズムで実現できる。 Further, although the feature of the key region is clustered, noise may be excluded by making the classing feature only the feature of the edge region of the key region. The edge region extraction can be realized by an existing labeling algorithm.
次に、ステップS803では、被写体領域抽出部305は、正規化した全ての動きベクトルの特徴のうち、ステップS802でクラスタリングされたキー領域のクラスに含まれるものとして判断された特徴を、このクラスに含める処理を行う。即ち、図10に示すように、動きベクトルの特徴空間においてキー領域のクラスに属する特徴は被写体領域クラスであるとみなすことで、被写体領域クラスとそれ以外を識別する。これから、被写体領域は、キーカラーデータを有する領域に加え、キー領域と類似した動きベクトル成分を有する領域も含むこととなる。図10は、キー領域のクラスとその他のクラスに属する特徴とを示す図である。
Next, in step S803, the subject
係る処理は、例えば以下の式に基づいて行われる。 Such processing is performed based on, for example, the following equation.
target_area( i, j ) = discriminant_func( whole_vec( i, j ) )
ここで(i,j)は現実空間画像における画素座標、target_areaは被写体領域である。また、discriminant_func()はキー領域のクラスの動きベクトルの特徴によって学習されている被写体領域識別関数、whole_vecは現実空間画像の全体の動きベクトルである。なお、上述したように、動きベクトルは現実空間画像を構成する全ての画素について求めることに限定するものではないので、ステップS803では、全ての画素について行うのではなく、動きベクトルを求めた全ての画素について行うものである。
target_area (i, j) = discriminant_func (whole_vec (i, j))
Here, (i, j) is a pixel coordinate in the real space image, and target_area is a subject area. Further, discriminant_func () is a subject area identification function learned by the motion vector characteristics of the key area class, and whole_vec is the entire motion vector of the real space image. Note that, as described above, the motion vector is not limited to being obtained for all the pixels constituting the real space image, and therefore, in step S803, not all the pixels are obtained, but all the motion vectors obtained are obtained. This is done for pixels.
次に、ステップS804では、被写体領域抽出部305は、キー領域と類似した動きベクトル成分を有する画素としてステップS803で特定されたそれぞれの画素についてラベリング処理を行う。以下ではラベリングされた画素で構成される領域を追加領域と呼称する。例えば、腕の領域を構成する画素のみをラベリングする。またここでラベリングされる画素にはユーザの手、腕以外の領域を構成する画素が含まれている可能性がある。本来それらの画素は、背景となる領域を構成する画素である。例えばそれはユーザ以外の人間の手や腕かもしれない。
Next, in step S804, the subject
次に、ステップS805では、被写体領域抽出部305は、ステップS804でラベリングされた追加領域が被写体領域として適切か否かを判定する。ステップS805における判定で用いる判定基準は2つある。
In step S805, the subject
1つ目の基準は、追加領域がキー領域と連結しているかどうか(連結関係)である。つまり、被写体となるべき腕はもちろん手とつながっているので、追加領域がキー領域と連結しているかを判定し、連結していればこの追加領域は被写体領域であるとする。そしてそうでないものは被写体領域から除外する。 The first criterion is whether or not the additional area is linked to the key area (linkage relationship). That is, since the arm to be the subject is connected to the hand as a matter of course, it is determined whether the additional area is connected to the key area, and if it is connected, the additional area is assumed to be the subject area. Those that are not are excluded from the subject area.
2つ目の基準は、追加領域が現実空間画像の端の領域に属しているかどうかである。つまり、被写体領域となるべきである腕はもちろんユーザとつながっているので、ユーザは自身の手を見ている際は必ず手につながった腕がユーザの視界の端までつながっているはずである。従って、ユーザが見る画像の端の領域に腕の領域が存在するはずである。これらの理由から、追加領域が現実空間画像の端の領域に属しているか否かを判定し、属していればこの追加領域は被写体領域であるとする。そしてそうでないものは被写体領域から除外する。 The second criterion is whether or not the additional region belongs to the end region of the real space image. In other words, since the arm that should be the subject area is connected to the user as a matter of course, when the user looks at his / her hand, the arm connected to the hand must be connected to the end of the user's field of view. Therefore, there should be an arm region in the end region of the image viewed by the user. For these reasons, it is determined whether or not the additional region belongs to the end region of the real space image, and if it belongs, it is assumed that this additional region is the subject region. Those that are not are excluded from the subject area.
これらの処理によって、背景領域を被写体領域と誤認識することが軽減される。 By these processes, erroneous recognition of the background area as the subject area is reduced.
ここで2つ目の基準をより厳しくするために、追加領域が現実空間画像の左右か下の端の領域に属しているかを判断するようにしても良い。 Here, in order to make the second criterion more strict, it may be determined whether the additional region belongs to the left or right end region of the real space image.
ステップS806では、ステップS805で被写体領域として認識された追加領域を、キー領域にマージすることで、被写体領域を形成する。 In step S806, the subject area is formed by merging the additional area recognized as the subject area in step S805 with the key area.
被写体領域はつまり下記のようになる。 That is, the subject area is as follows.
被写体領域 = キー領域 + 追加領域
ただし、追加領域は、ステップS805で被写体領域として適切であると判定された領域である。
Subject area = Key area + Additional area However, the additional area is an area determined to be suitable as the subject area in step S805.
そして、図6のステップS605にリターンする。 Then, the process returns to step S605 in FIG.
ここで、以上の説明では、動きベクトルの距離成分と角度成分とを特徴として用いたが、距離成分のみを特徴として用いても良い。即ち、動きベクトルの特徴として用いるものは特に限定するものではなく、動きベクトル間の類似性を求めることができるのであれば、何れの特徴を用いても良い。 Here, in the above description, the distance component and the angle component of the motion vector are used as features, but only the distance component may be used as a feature. That is, what is used as the feature of the motion vector is not particularly limited, and any feature may be used as long as the similarity between the motion vectors can be obtained.
図6に戻ってステップS605では、被写体領域抽出部305は、ステップS501で撮影画像取込部302が取得した現実空間画像からステップS604で抽出した被写体領域の領域をマスクしたマスク画像のデータを、上記被写体領域データとして生成する。
Returning to FIG. 6, in step S <b> 605, the subject
ここで、ステップS605における処理の詳細について説明する。図11は、上記ステップS605における処理の詳細を示すフローチャートである。なお、図11のフローチャートは、現実空間画像中の画像座標(i,j)における画素について行う処理のフローチャートである。従って、実際にステップS605では、図11のフローチャートに従った処理を、現実空間画像を構成する各画素について行うことになる。 Here, details of the processing in step S605 will be described. FIG. 11 is a flowchart showing details of the processing in step S605. In addition, the flowchart of FIG. 11 is a flowchart of the process performed about the pixel in the image coordinate (i, j) in a real space image. Therefore, in step S605, the process according to the flowchart of FIG. 11 is actually performed for each pixel constituting the real space image.
ステップS1101では、被写体領域抽出部305は、画像座標(i、j)における画素が被写体領域として上記ステップS805で認識されたのであれば、配列Key_area(i、j)に「1」を書き込む。係る動作は、関数mask_func()を実行することでなされる。これにより、配列Key_area(i、j)は、画像座標(i、j)における画素が被写体領域を構成する画素であるか否かを示す値を格納する為の2次元配列となる。
In step S1101, the subject
そして、全てのi、jについて図11のフローチャートに従った処理を行うことで、配列Key_areaには、現実空間画像を構成する各画素について「1」若しくは「0」が保持されることになる。係る配列Key_areaが、上記被写体領域データとなる。 Then, by performing processing according to the flowchart of FIG. 11 for all i and j, the array Key_area holds “1” or “0” for each pixel constituting the real space image. The array Key_area is the subject area data.
なお、本実施形態では生成された被写体領域データが示すマスク画像はマスク領域内にノイズを含む場合がある。この場合は既存の凸閉方処理を行う。 In the present embodiment, the mask image indicated by the generated subject area data may include noise in the mask area. In this case, the existing convex closing process is performed.
一方、図6に戻って、ステップS606では、被写体領域抽出部305は、1フレーム前に生成した被写体領域データを、現フレームでも使用するものとして設定する。これは前述したように、動きベクトルから被写体領域を正常に抽出できない場合は前回生成したマスク画像で代用する処理である。しかし、ステップS606では、キー領域部分は常に更新し、追加領域のみ更新されていないマスク画像を示す被写体領域データを出力してもよい。キー領域部分を常に更新するということはキーカラーデータに基づいて領域を抽出するということである。従って係る処理を行えば、キー領域の形状(手の形状)は必ずキーカラーデータによって正確に抽出されることが保障される。
On the other hand, returning to FIG. 6, in step S606, the subject
そして、ステップS605,S606の何れの処理の後も、図5のステップS503にリターンする。 Then, after any processing in steps S605 and S606, the process returns to step S503 in FIG.
次に、図5のステップS505における、複合現実空間の画像の生成処理の詳細について説明する。図12は、上記ステップS505における、複合現実空間の画像の生成処理の詳細を示すフローチャートである。なお、図12のフローチャートは、複合現実空間の画像中の画像座標(i,j)における画素について行う処理のフローチャートである。従って、実際にステップS505では、図12のフローチャートに従った処理を、複合現実空間の画像を構成する各画素について行うことになる。 Next, details of the mixed reality space image generation processing in step S505 of FIG. 5 will be described. FIG. 12 is a flowchart showing details of the mixed reality space image generation processing in step S505. Note that the flowchart of FIG. 12 is a flowchart of processing performed on a pixel at image coordinates (i, j) in an image of the mixed reality space. Therefore, in step S505, the process according to the flowchart of FIG. 12 is actually performed for each pixel constituting the mixed reality space image.
先ずステップS1201では、画像合成部308は、次のような処理を行う。即ち、ステップS501で撮影画像取込部302が取得したディジタルデータが示す現実空間画像において画像座標(i,j)の画素real(i,j)を、画像処理装置300内のフレームメモリbuffer(i,j)に転送する。
First, in step S1201, the
次にステップS1202では、上記ステップS502で生成した被写体領域データが示すマスク画像のうち画像座標(i、j)に対応するデータKey_area(i,j)を画像処理装置300内のステンシルバッファstencil(i,j)に転送する。 In step S1202, data Key_area (i, j) corresponding to the image coordinates (i, j) in the mask image indicated by the subject area data generated in step S502 is converted into a stencil buffer stencil (i , j).
次にステップS1203では、画像合成部308は、stencil(i,j)=0である場合には、上記ステップS504で生成した仮想空間画像において画像座標(i,j)の画素CGI(i,j)を、フレームメモリbuffer(i,j)に上書きする。一方、画像合成部308は、stencil(i,j)=1である場合には、フレームメモリbuffer(i,j)に対しては何も処理しない。即ち、被写体領域については、仮想空間画像の重畳対象外とする。
Next, in step S1203, when stencil (i, j) = 0, the
そして、全てのi、jについて図12のフローチャートに従った処理を行うことで、フレームメモリbufferには、複合現実空間の画像が生成されることになる。そして、ステップS506では、この複合現実空間の画像を映像信号としてHMD390が有する表示部309に送出する。
Then, by performing processing according to the flowchart of FIG. 12 for all i and j, an image of the mixed reality space is generated in the frame memory buffer. In step S506, the mixed reality space image is sent to the
以上の説明により本実施形態によれば、現実空間画像上に仮想空間画像を重畳させる際、現実空間画像中に「手」と「腕」とが被写体として含まれている場合は、この被写体は常に仮想空間画像よりも手前に表示されるように、重畳処理を制御することができる。 As described above, according to the present embodiment, when a virtual space image is superimposed on a real space image, if “hand” and “arm” are included as subjects in the real space image, the subject is The superimposition process can be controlled so that it is always displayed in front of the virtual space image.
図13は、本実施形態によって生成される複合現実空間の画像の一例を示す図である。図13に示した複合現実空間の画像1301は、現実空間画像、仮想空間画像がそれぞれ図2に示した現実空間画像201、仮想空間画像202である場合に生成されるものである。図13に示す如く、手の領域150aはもちろんのこと、手の領域150aとは異なる画素値を有する腕の領域150bさえも、仮想空間画像202の手前に表示することができる。
FIG. 13 is a diagram illustrating an example of an image of the mixed reality space generated by the present embodiment. The mixed
[第2の実施形態]
第1の実施形態の冒頭でも述べたように、被写体の領域は、「手」の領域と「腕」の領域とをマージしたものに限定するものではなく、どのような領域をマージして被写体の領域を形成しても良い。即ち、以下の説明は、被写体の領域が異なる複数の画素値で表示されるようなものであれば、どのような被写体の領域でも良い。
[Second Embodiment]
As described at the beginning of the first embodiment, the area of the subject is not limited to the merged area of the “hand” area and the “arm” area. These regions may be formed. That is, in the following description, any subject area may be used as long as the subject area is displayed with a plurality of different pixel values.
例えば、ユーザが手で把持している現実物体を追加領域として判断して被写体領域を決定しても良い。これにより、ユーザの手、腕に加えて、手で把持している現実物体をも、仮想空間画像の手前に表示することができる。 For example, the subject area may be determined by determining a real object held by the user's hand as an additional area. Thereby, in addition to the user's hand and arm, a real object grasped by the hand can be displayed in front of the virtual space image.
この場合、第1の実施形態において、ステップS805における処理を以下のように変更すれば良い。 In this case, what is necessary is just to change the process in step S805 as follows in 1st Embodiment.
第1の実施形態では、ステップS805において2つの判断基準を設けていた。本実施形態ではそのうちの1つの判断基準を次のような判断基準に変更する。 In the first embodiment, two determination criteria are provided in step S805. In the present embodiment, one of the judgment criteria is changed to the following judgment criteria.
具体的には、追加領域が現実空間画像の端の領域に属しているかどうかの判定をなくす。これは、手で把持される現実物体が必ずしも現実空間画像の端にかかっているわけではないためである。 Specifically, it is not determined whether the additional area belongs to the edge area of the real space image. This is because the real object grasped by the hand does not necessarily hang on the edge of the real space image.
本実施形態ではその代わりの判定処理として、キー領域と追加領域(ステップS805の判定済みの領域)とをマージすることで得られる被写体領域が現実空間画像の端にかかっているかどうかを基準として判定を行う。 In this embodiment, as an alternative determination process, a determination is made based on whether the subject area obtained by merging the key area and the additional area (the area determined in step S805) is on the edge of the real space image. I do.
これより手に把持されていない領域の誤認識を回避する。 This avoids erroneous recognition of areas that are not gripped by the hand.
[第3の実施形態]
第1,2の実施形態では、キー領域と追加領域とを毎フレーム毎に算出し、それらに基づいて被写体領域を決定した。即ち、キー領域と追加領域とに基づいて被写体領域を求める処理をフレーム毎に行っていた。本実施形態では、初期領域を指定するためのみキー領域と追加領域とを算出し、その後の被写体領域の更新は自動輪郭抽出処理によって行う。
[Third Embodiment]
In the first and second embodiments, the key area and the additional area are calculated for each frame, and the subject area is determined based on them. That is, the process for obtaining the subject area based on the key area and the additional area is performed for each frame. In the present embodiment, the key area and the additional area are calculated only for designating the initial area, and the update of the subject area thereafter is performed by automatic contour extraction processing.
本実施形態では、初期登録された被写体領域を安定して毎回更新することが可能となる。ここでいう安定とは、例えば新しくキー領域に含まれる現実物体が現れても変わらない領域を抽出可能ということである。ここで、本実施形態では、第1、2の実施形態とステップS502における処理のみが異なる。 In the present embodiment, the initially registered subject area can be stably updated every time. Here, “stable” means that, for example, it is possible to extract a region that does not change even if a new real object included in the key region appears. Here, this embodiment is different from the first and second embodiments only in the processing in step S502.
図14は、本実施形態で行う、ステップS502における処理のフローチャートである。図14に示すフローチャートは、図6に示したフローチャートからステップS603における処理と、ステップS606における処理とが削除されている。そして代わりに、ステップS604とステップS605との間に、ステップS1401の動的輪郭対象登録の処理と、ステップS1402の動的輪郭抽出の処理が追加されている。 FIG. 14 is a flowchart of the processing in step S502 performed in the present embodiment. In the flowchart shown in FIG. 14, the process in step S603 and the process in step S606 are deleted from the flowchart shown in FIG. Instead, between the steps S604 and S605, the dynamic contour object registration processing at step S1401 and the dynamic contour extraction processing at step S1402 are added.
ステップS1401では、被写体領域抽出部305は、ステップS604で抽出された被写体領域を動的輪郭抽出の対象として登録する。
In step S1401, the subject
次にステップS1402では、被写体領域抽出部305は、ステップS1401で登録された被写体領域の動的輪郭抽出を行う。動的輪郭抽出はスネークなどの既存のアルゴリズムを用いればよい。動的輪郭抽出は既存の技術であるので説明は省略する。
In step S1402, the subject
ステップS605では、被写体領域抽出部305は、ステップS1401で抽出された被写体領域に基づきマスク画像(被写体領域データ)を生成して出力する。
In step S605, the subject
[第4の実施形態]
上記実施形態では、撮像部301が撮像した現実空間画像から算出される動きベクトルのみから被写体領域を特定した。しかし、被写体領域の特定は係る方法に限定するものではない。例えば、現実空間画像から算出される動きベクトルを、撮像部301の位置および姿勢の変化から生じる動きベクトルを用いて補正することで得られる動きベクトルから被写体領域を特定してもよい。
[Fourth Embodiment]
In the above embodiment, the subject region is specified only from the motion vector calculated from the real space image captured by the
撮像部301が移動または回転する場合、現実空間画像のみから算出される動きベクトルでは、被写体領域を抽出する際に誤差が生じやすい。なぜならば、現実空間画像のみから算出される動きベクトルは、被写体の動きベクトルだけではなく撮像部301の動きベクトルをも含んでいるからである。例えば、被写体の動きとは逆の方向に撮像部301が動いた場合、被写体の動きベクトルのいくつかを打ち消してしまう可能性がある。
When the
そこで本実施形態では、現実空間画像から算出される動きベクトルから、撮像部301の位置および姿勢変化から生じる動きベクトルの影響を差し引くことで、被写体の動きベクトルを算出する。そして、その算出結果としての動きベクトルから被写体領域を特定する。この場合、第1の実施形態においてステップS502における処理を以下のように変更すればよい。
Therefore, in the present embodiment, the motion vector of the subject is calculated by subtracting the influence of the motion vector resulting from the change in the position and orientation of the
第1の実施形態では、ステップS502内の、更にステップS602では、現実空間画像からのみ動きベクトルを算出するとした。本実施形態では、動きベクトルの算出方法を下記のように変更する。 In the first embodiment, the motion vector is calculated only from the real space image in step S502 and further in step S602. In this embodiment, the motion vector calculation method is changed as follows.
図16は、ステップS602において本実施形態で行う処理のフローチャートである。本実施形態ではステップS602では、撮像部301(撮像装置)の位置および姿勢の変化に基づいて、現実空間画像からのみ動きベクトルを補正する。 FIG. 16 is a flowchart of the processing performed in this embodiment in step S602. In this embodiment, in step S602, the motion vector is corrected only from the real space image based on the change in the position and orientation of the imaging unit 301 (imaging device).
ステップS1501では、動きベクトル検出部304は、現実空間画像から動きベクトルを算出する。ステップS1501における処理は、第1の実施形態で説明したステップS602における処理と同じである。
In step S1501, the motion
次に、ステップS1502では、動きベクトル検出部304は、撮像部301の姿勢変化による動きベクトル(姿勢変化分動きベクトル)の情報を用いて、ステップS1501で算出された動きベクトルを補正する。
Next, in step S1502, the motion
より詳しくは、先ず、動きベクトル検出部304は、位置姿勢計測部306から撮像部301の姿勢情報を得る。ここで、動きベクトル検出部304は、予め前フレームにおける撮像部301の位置および姿勢情報を保持しているとする。動きベクトル検出部304は、前フレームにおける撮像部301の姿勢情報と現フレームにおける撮像部301に姿勢情報とから、姿勢の変化量を算出する。この姿勢変化量から、姿勢変化によって生じる動きベクトル(姿勢変化分動きベクトル)を求める。なお、動きベクトルの算出技術は周知の技術であるので、これについての詳細な説明は省略する。なお、ここで姿勢変化とは、撮像部301のレンズ中心を軸として光軸が回転することをいう。
More specifically, first, the motion
次に、算出された姿勢変化分動きベクトルを、撮像部301の画像平面に射影することで、画像上での動きベクトルとして変換する。
Next, the calculated posture change motion vector is projected onto the image plane of the
そして動きベクトル検出部304は、画像平面に射影された姿勢変化分動きベクトルを用いて、ステップS1501で算出された動きベクトルを補正する。係る補正は以下の式に基づいて行う。
Then, the motion
M’=M−Rv・I (式1)
ここで、M’は姿勢変化分動きベクトルを現実空間画像内の動きベクトルから差し引いた動きベクトルを表す行列、Mは現実空間画像から算出された動きベクトルを表す行列である。また、Rvは画像平面上に射影された姿勢変化ベクトル、Iは単位行列(行列Mと大きさが同じ行列)である。
M '= M−Rv · I (Formula 1)
Here, M ′ is a matrix representing a motion vector obtained by subtracting a motion vector for posture change from a motion vector in the real space image, and M is a matrix representing a motion vector calculated from the real space image. Rv is a posture change vector projected onto the image plane, and I is a unit matrix (a matrix having the same size as the matrix M).
このように、現実空間画像から算出された動きベクトルから姿勢変化による動きベクトルを減じる。 Thus, the motion vector due to the posture change is subtracted from the motion vector calculated from the real space image.
図16に戻って、次に、ステップS1503では、動きベクトル検出部304は、撮像部301の位置変化による動きベクトル(位置変化分動きベクトル)の情報を用いて、ステップS1501で算出された動きベクトルを補正する。
Returning to FIG. 16, next, in step S1503, the motion
より詳しくは、先ず、動きベクトル検出部304は、位置姿勢計測部306から撮像部301の位置情報を得る。動きベクトル検出部304は、前フレームにおける撮像部301の位置情報と現フレームにおける撮像部301の位置情報とから、位置の変化量を算出する。この位置変化量から、位置変化によって生じる動きベクトルを求める。なお位置変化とは、撮像部301のレンズ中心を軸として並進移動した場合の位置変化のことをいう。
More specifically, first, the motion
次に、位置変化分動きベクトルを、撮像部301の画像平面に射影することで、画像上での動きベクトルとして変換する。ここで、位置変化分動きベクトルを画像平面に射影する際は、位置変化分動きベクトルの画像平面射影とは異なり、被写体までの奥行き情報を考慮する必要がある。なぜならば、画像平面上に射影される位置変化分動きベクトルは、被写体までの奥行き距離に応じて異なるからである。具体的には、被写体までの距離が大きくなるにつれて、位置変化分動きベクトルの大きさは大きくなる。
Next, the position change motion vector is projected onto the image plane of the
従って、動きベクトル検出部304は、画像平面上に射影される位置変化分動きベクトルを算出するために被写体までの奥行き距離を測定する。
Therefore, the motion
本実施形態では、被写体はステレオビデオカメラから成るHMD390によって撮像されているので、ステレオマッチング法により奥行き距離を測定する。ステレオマッチング法は周知の技術であるので、これについての説明は省略する。
In this embodiment, since the subject is imaged by the
本実施形態では、奥行き距離の測定をステレオマッチング法によって行うとしているが、係る方法に限定するものではない。例えば、奥行き距離の測定を赤外式距離測定カメラを用いて行っても良い。即ち、距離を測定できる方法であればどのような方法を用いても良い。また、位置変化分動きベクトルを算出するために、ユーザが奥行き距離を設定するようにしても良い。 In the present embodiment, the depth distance is measured by the stereo matching method, but is not limited to this method. For example, the depth distance may be measured using an infrared distance measuring camera. In other words, any method may be used as long as it can measure the distance. Further, the depth distance may be set by the user in order to calculate the position change motion vector.
奥行き距離が測定されると、動きベクトル検出部304は、画像平面上に射影される位置変化分動きベクトルの算出を以下の式に基づいて行う。
When the depth distance is measured, the motion
Tv=f・t/z (式2)
ここで、Tvは画像平面上に射影された位置変化分動きベクトル、fは撮像部301のレンズから結像面までの距離である。また、tは撮像部301の位置変化によって生じた動きベクトル、zは被写体までの奥行き距離である。
Tv = f · t / z (Formula 2)
Here, Tv is a position change motion vector projected onto the image plane, and f is the distance from the lens of the
図17は、画像平面上に射影された位置変化分動きベクトルTvを算出する原理を示す図である。図17では、現在よりも一つ前のフレームから現在のフレームに変わった際に撮像部301が並進移動した(tだけ並進移動した)例を示している(被写体は固定とする)。また、図17では、画像面を規定するXY座標軸のうち、X軸方向に撮像部301が並進した場合を示している。ここでは説明を簡単にするため、X軸方向のみの移動を想定しているが、ここで説明する方法の原理は、移動方向がY軸成分を有する場合にも適用可能であることは言うまでもない。
FIG. 17 is a diagram illustrating the principle of calculating the position change motion vector Tv projected onto the image plane. FIG. 17 shows an example in which the
図17において、O1は現在よりも一つ前のフレーム(前フレーム)おける撮像部301のレンズ中心を示す。O2は現在のフレーム(現フレーム)における撮像部301のレンズ中心を示す。P(x、z)は、撮像部301で撮像された被写体の一点(計測点)を示す。xはx座標の値、zはz座標の値を示す。ここで表現されている座標系は、前フレームにおける撮像部301のレンズ中心を原点とした現実空間の座標系である。つまり、zは撮像部301からの奥行き値である。
In FIG. 17, O 1 indicates the lens center of the
X1は、前フレームにおいて計測点を画像平面上に投影したときのx座標である。X2は現フレームおいて計測点を画像平面上に投影したときのx座標である。つまり、X2-X1が、画像平面上での撮像部301の動きベクトルといえる。その他は(式2)と同じである。
X 1 is an x coordinate when the measurement point is projected on the image plane in the previous frame. X2 is the x coordinate when the measurement point is projected on the image plane in the current frame. That is, X2-X1 can be said to be a motion vector of the
図17から分かるように、位置変化分動きベクトルtが与えられると、撮像部301のレンズから結像面までの距離fと被写体までの距離zとの相似関係から、画像平面上の位置変化分動きベクトルTvを算出することが可能である。
As can be seen from FIG. 17, when a position change motion vector t is given, the position change on the image plane is calculated from the similarity between the distance f from the lens of the
そして動きベクトル検出部304は、画像平面に射影された位置変化分動きベクトルを用いて、ステップS1501で算出された動きベクトルを補正する。係る補正は下記の式に基づいて行う。
The motion
M”=M’−Tv・I
M”は、位置変化分動きベクトルを動きベクトルM’から差し引いた動きベクトルを表す行列、M’はステップS1502の処理において補正された動きベクトルを表す行列である。また、Tvは、画像平面上に射影された位置変化ベクトル、Iは単位行列(行列Mと大きさが同じ行列)である。このように、現実空間画像から算出された動きベクトルから、撮像部301の位置変化による動きベクトルを減じる。
M ”= M′−Tv · I
M ″ is a matrix representing a motion vector obtained by subtracting the position change motion vector from the motion vector M ′, and M ′ is a matrix representing the motion vector corrected in the processing of step S1502. Further, Tv is an image plane. Is a unit matrix (a matrix having the same size as the matrix M.) In this way, a motion vector due to a position change of the
最終的に、撮像部301が撮像した現実空間画像から算出された動きベクトルから、撮像部301の位置及び姿勢によって生じた動きベクトルを減ずることとなる。従って、結果的に撮像部301による動きベクトルを排除した被写体の動きベクトルを算出することとなる。
Finally, the motion vector generated by the position and orientation of the
本実施形態では、このようにして撮像部301の動きの影響を補正した動きベクトルに基づいて、被写体領域の特定を行う。ここで、本実施形態では、位置及び姿勢の両方の変化によって生じる動きベクトル分を補正するとした。しかし、動きベクトルの補正を、撮像部301の姿勢変化のみを考慮して行ってもよいし、移動変化のみを考慮して行っても良い。
In the present embodiment, the subject region is specified based on the motion vector in which the influence of the motion of the
また、本実施形態では、撮像部301の動きによって生じる動きベクトルを、位置姿勢計測部306から得られる位置及び姿勢情報を用いて求めた。しかし、係る動きベクトルは他の方法でもって求めても良い。即ち、必ずしも、磁気センサや光学式センサなどのセンサシステムから得られる位置及び姿勢情報に基づいて動きベクトルを求める必要はない。例えば、撮像部301が撮像した画像を用いて、撮像部301の動きによって生じる動きベクトルを求めるようにしても良い。
In the present embodiment, the motion vector generated by the movement of the
例えば、撮像部301が撮像した画面全体の動きベクトルの平均を、撮像部301の動きにより生じた動きベクトルと仮定するようにしても良い。また、撮像した画像を領域分割することで背景領域が分かっている場合には、背景領域に生じている動きベクトルを、撮像部301の動きにより生じた動きベクトルと仮定するようにしても良い。
For example, the average of the motion vectors of the entire screen imaged by the
[第5の実施形態]
上記各実施形態では、図3に示した画像処理装置300を構成する各部はハードウェアで構成されているものとして説明したが、記憶装置310、撮影画像取込部302を除く他の各部はソフトウェアプログラムの形態で実現させても良い。その場合、記憶装置310、撮影画像取込部302を有するコンピュータに、係るソフトウェアプログラムをインストールし、係るソフトウェアプログラムを、このコンピュータが有するCPUが実行することで、各部の動作を実現させることになる。即ち、画像処理装置300には、一般のPC(パーソナルコンピュータ)などのコンピュータを適用させることができる。
[Fifth Embodiment]
In each of the above embodiments, each unit configuring the
図15は、画像処理装置300に適用可能なコンピュータのハードウェア構成例を示す図である。
FIG. 15 is a diagram illustrating a hardware configuration example of a computer applicable to the
CPU1501は、RAM1502やROM1503に格納されているプログラムやデータを用いて本コンピュータ全体の制御を行うと共に、画像処理装置300が行うものとして上述した各処理を実行する。
The
RAM1502は、外部記憶装置1506からロードされたプログラムやデータ、I/F(インターフェース)1507を介して外部から受信した各種のデータ等を一時的に記憶するためのエリアを有する。更にRAM1502は、CPU1501が各種の処理を実行する際に用いるワークエリアも有する。更に、RAM1502は、上記フレームメモリ、ステンシルバッファとしても機能する。即ち、RAM1502は、各種のエリアを適宜提供することができる。
The
ROM1503は、本コンピュータの設定データや、ブートプログラムなどを格納する。
The
操作部1504は、キーボードやマウスなどにより構成されており、本コンピュータの操作者が操作することで、各種の指示をCPU1501に対して入力することができる。例えば、処理の終了指示等はこの操作部1504を用いて入力することができる。
The
表示部1505は、CRTや液晶画面などにより構成されており、CPU1501による処理結果を画像や文字で表示することができる。例えば、画像処理装置300が行うものとして上述した各処理を本コンピュータ(CPU1501)が実行することで生成された複合現実空間の画像を表示することができる。
The display unit 1505 is configured by a CRT, a liquid crystal screen, or the like, and can display a processing result by the
外部記憶装置1506は、ハードディスクドライブ装置に代表される大容量情報記憶装置である。外部記憶装置1506には、OS(オペレーティングシステム)や、画像処理装置300が行うものとして上述した各処理をCPU1501に実行させるためのプログラムやデータなどが保存されている。係るプログラムには、動きベクトル検出部304、キー領域抽出部303、被写体領域抽出部305、画像合成部308、画像生成部307のそれぞれの機能をCPU1501に実行させるためのプログラムが含まれている。また、外部記憶装置1506は記憶装置310も兼ねている。外部記憶装置1506に保存されているプログラムやデータは、CPU1501による制御に従って適宜RAM1502にロードされる。そしてCPU1501はこのロードされたプログラムやデータを用いて処理を実行するので、本コンピュータは、画像処理装置300が行うものとして上述した各処理(上述の各フローチャートに従った処理)を実行することになる。
The
I/F1507は、上述のHMD390や位置姿勢計測部306を本コンピュータに接続する為のもので、HMD390、位置姿勢計測部306とはこのI/F1507を介して信号の送受信を行う。I/F1507は、撮影画像取込部302も兼ねている。
An I /
1508は上述の各部を繋ぐバスである。
A
なお、画像処理装置300に適用可能なコンピュータのハードウェア構成については図15に示した構成に限定しない。例えば、本コンピュータにグラフィックスカード(ボード)を取り付け、係るグラフィックスカードが仮想空間画像の生成や、複合現実空間の画像の生成を行うようにしても良い。
Note that the hardware configuration of the computer applicable to the
[その他の実施形態]
また、本発明の目的は、以下のようにすることによって達成されることはいうまでもない。即ち、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記録媒体(または記憶媒体)を、システムあるいは装置に供給する。係る記憶媒体は言うまでもなく、コンピュータ読み取り可能な記憶媒体である。そして、そのシステムあるいは装置のコンピュータ(またはCPUやMPU)が記録媒体に格納されたプログラムコードを読み出し実行する。この場合、記録媒体から読み出されたプログラムコード自体が前述した実施形態の機能を実現することになり、そのプログラムコードを記録した記録媒体は本発明を構成することになる。
[Other Embodiments]
Needless to say, the object of the present invention can be achieved as follows. That is, a recording medium (or storage medium) in which a program code of software that realizes the functions of the above-described embodiments is recorded is supplied to the system or apparatus. Needless to say, such a storage medium is a computer-readable storage medium. Then, the computer (or CPU or MPU) of the system or apparatus reads and executes the program code stored in the recording medium. In this case, the program code itself read from the recording medium realizes the functions of the above-described embodiment, and the recording medium on which the program code is recorded constitutes the present invention.
また、コンピュータが読み出したプログラムコードを実行することにより、そのプログラムコードの指示に基づき、コンピュータ上で稼働しているオペレーティングシステム(OS)などが実際の処理の一部または全部を行う。その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。 Further, by executing the program code read by the computer, an operating system (OS) or the like running on the computer performs part or all of the actual processing based on the instruction of the program code. Needless to say, the process includes the case where the functions of the above-described embodiments are realized.
さらに、記録媒体から読み出されたプログラムコードが、コンピュータに挿入された機能拡張カードやコンピュータに接続された機能拡張ユニットに備わるメモリに書込まれたとする。その後、そのプログラムコードの指示に基づき、その機能拡張カードや機能拡張ユニットに備わるCPUなどが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。 Furthermore, it is assumed that the program code read from the recording medium is written in a memory provided in a function expansion card inserted into the computer or a function expansion unit connected to the computer. After that, based on the instruction of the program code, the CPU included in the function expansion card or function expansion unit performs part or all of the actual processing, and the function of the above-described embodiment is realized by the processing. Needless to say.
本発明を上記記録媒体に適用する場合、その記録媒体には、先に説明したフローチャートに対応するプログラムコードが格納されることになる。 When the present invention is applied to the recording medium, program code corresponding to the flowchart described above is stored in the recording medium.
Claims (13)
前記現実空間画像の注目フレームにおいて、所定の条件を満たす画素で構成される領域を第1の領域として設定する第1の設定手段と、
前記注目フレーム内において、前記第1の領域の動きベクトルと前記注目フレーム内の前記第1の領域以外の他の領域の動きベクトルとを取得する取得手段と、
前記取得した他の領域の動きベクトルの大きさが閾値以上であるか否かを判断する第1の判断手段と、
前記第1の判断手段により、前記他の領域の動きベクトルの大きさが閾値以上であると判断された場合に、該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似しているかを判断する第2の判断手段と、
前記第2の判断手段により、該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似していると判断された場合に、該他の領域を第2の領域として設定する第2の設定手段と、
前記設定された前記注目フレーム内の前記第1の領域と前記第2の領域以外の領域に、仮想空間画像を合成する合成手段とを備えることを特徴とする画像処理装置。 Means for acquiring a real space image comprising a plurality of frames;
In the frame of interest of the real space image, a first setting means for setting a region composed of a predetermined pixel satisfying a first region,
Within the frame of interest, and acquisition means you get a motion vector of another region other than the first region of the target frame the motion vector of the first region,
First determination means for determining whether or not the magnitude of a motion vector of the acquired other region is greater than or equal to a threshold ;
When the first determination unit determines that the magnitude of the motion vector of the other area is equal to or greater than a threshold, the motion vector of the other area is similar to the motion vector of the first area. A second judging means for judging whether or not
A second region that sets the other region as a second region when the second determination unit determines that the motion vector of the other region is similar to the motion vector of the first region; Setting means,
To the first region and the region other than the second region in the frame of interest is pre-Symbol set, the image processing apparatus characterized by obtaining Bei a synthesizing means for synthesizing the virtual space image.
前記他の領域の動きベクトルの大きさが閾値以上でないと判断された場合には、前記注目フレームより以前のフレームで設定された第2の領域を、前記注目フレームの第2の領域として設定すること特徴とする請求項1に記載の画像処理装置。 The second setting means includes
If the magnitude of the motion vector of said another region is determined to not more than the threshold value, the second area set in a previous frame from the frame of interest is set as a second area of the frame of interest The image processing apparatus according to claim 1.
前記他の領域の動きベクトルの大きさが閾値以上でないと判断された場合には、前記注目フレームより以前のフレームで設定された第1の領域と第2の領域とを、前記注目フレームの第1の領域および第2の領域として設定することを特徴とする請求項1又は2に記載の画像処理装置。 The second setting means includes
If the magnitude of the motion vector of said another region is determined to not more than the threshold value, a first region and a second region set in a previous frame from the frame of interest, the said frame of interest The image processing apparatus according to claim 1, wherein the image processing apparatus is set as one area and a second area .
前記第1の判断手段により前記他の領域の動きベクトルの大きさが閾値以上であると判定され、かつ、前記第2の判断手段により該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似していると判断され、更に、該他の領域が前記第1の領域と連結している場合に、該他の領域を前記第2の領域として設定することを特徴とする請求項1乃至3の何れか1項に記載の画像処理装置。 The second setting means includes
The first determination means determines that the magnitude of the motion vector of the other area is greater than or equal to a threshold value, and the second determination means determines that the motion vector of the other area is a motion of the first area. The second region is set as the second region when the second region is determined to be similar to a vector and the other region is connected to the first region. The image processing apparatus according to any one of 1 to 3.
撮像装置の姿勢変化量を算出する手段と、
前記姿勢変化量に基づき、前記撮像装置の姿勢変化によって生じる動きベクトルを姿勢変化分動きベクトルとして計算する手段と、
前記姿勢変化分動きベクトルに基づいて、前記第1の領域の動きベクトルを補正する手段と
を備えることを特徴とする請求項1乃至5の何れか1項に記載の画像処理装置。 The acquisition means includes
Means for calculating an attitude change amount of the imaging device;
Means for calculating a motion vector generated by a posture change of the imaging device as a posture change motion vector based on the posture change amount;
6. The image processing apparatus according to claim 1 , further comprising: a unit that corrects a motion vector of the first region based on the posture change amount motion vector.
現実空間の奥行き情報を算出する手段と、
撮像装置の位置変化量を算出する手段と、
前記奥行き情報と前記位置変化量に基づいて、前記撮像装置の位置変化によって生じる動きベクトルを、位置変化分動きベクトルとして計算する手段と、
前記位置変化分動きベクトルに基づいて、前記第1の領域の動きベクトルを補正する手段と
を備えることを特徴とする請求項1乃至6の何れか1項に記載の画像処理装置。 The acquisition means includes
Means for calculating real space depth information;
Means for calculating a position change amount of the imaging device;
Means for calculating a motion vector caused by a position change of the imaging device as a position change motion vector based on the depth information and the position change amount;
The image processing apparatus according to claim 1 , further comprising: a unit that corrects a motion vector of the first area based on the position change motion vector.
ことを特徴とする請求項1乃至10の何れか1項に記載の画像処理装置。 The image processing apparatus according to any one of claims 1 to 10, further comprising means for outputting a composite image obtained by the composition processing by the composition means.
前記現実空間画像の注目フレームにおいて、所定の条件を満たす画素で構成される領域を第1の領域として設定する第1の設定工程と、
前記注目フレーム内において、前記第1の領域の動きベクトルと前記注目フレーム内の前記第1の領域以外の他の領域の動きベクトルとを取得する取得工程と、
前記取得した他の領域の動きベクトルの大きさが閾値以上であるか否かを判定する第1の判断工程と、
前記第1の判断工程で前記他の領域の動きベクトルの大きさが閾値以上であると判断された場合に、該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似しているかを判定する第2の判断工程と、
前記第2の判断工程で該他の領域の動きベクトルが前記第1の領域の動きベクトルと類似していると判断された場合に、該他の領域を第2の領域として設定する第2の設定工程と、
前記設定された前記注目フレーム内の前記第1の領域と前記第2の領域以外の領域に、仮想空間画像を合成する合成工程とを備えることを特徴とする画像処理方法。 Acquiring a physical space image composed of a plurality of frames;
In the frame of interest of the real space image, a first setting step of setting an area consisting of a predetermined pixel satisfying a first region,
Within the frame of interest, an acquisition step get a motion vector of the first area regions other than the first region and the motion vector the target frame of,
A first determination step of determining whether or not the magnitude of a motion vector of the acquired other region is equal to or greater than a threshold ;
Whether the motion vector of the other region is similar to the motion vector of the first region when it is determined in the first determination step that the size of the motion vector of the other region is greater than or equal to a threshold value A second determination step for determining
When it is determined in the second determination step that the motion vector of the other region is similar to the motion vector of the first region, the second region is set as the second region. A setting process;
Image processing method characterized in that the first region and the region other than the second region of the target frame that have been pre-Symbol set, obtain Preparations and synthesis step of synthesizing the virtual space image.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2012260297A JP5474169B2 (en) | 2007-10-30 | 2012-11-28 | Image processing apparatus and image processing method |
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007282352 | 2007-10-30 | ||
JP2007282352 | 2007-10-30 | ||
JP2012260297A JP5474169B2 (en) | 2007-10-30 | 2012-11-28 | Image processing apparatus and image processing method |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008186501A Division JP2009134693A (en) | 2007-10-30 | 2008-07-17 | Image processing apparatus and image processing method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2013077307A JP2013077307A (en) | 2013-04-25 |
JP5474169B2 true JP5474169B2 (en) | 2014-04-16 |
Family
ID=40866485
Family Applications (2)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008186501A Pending JP2009134693A (en) | 2007-10-30 | 2008-07-17 | Image processing apparatus and image processing method |
JP2012260297A Expired - Fee Related JP5474169B2 (en) | 2007-10-30 | 2012-11-28 | Image processing apparatus and image processing method |
Family Applications Before (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008186501A Pending JP2009134693A (en) | 2007-10-30 | 2008-07-17 | Image processing apparatus and image processing method |
Country Status (1)
Country | Link |
---|---|
JP (2) | JP2009134693A (en) |
Families Citing this family (16)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2691935A1 (en) * | 2011-03-29 | 2014-02-05 | Qualcomm Incorporated | System for the rendering of shared digital interfaces relative to each user's point of view |
US9886552B2 (en) | 2011-08-12 | 2018-02-06 | Help Lighting, Inc. | System and method for image registration of multiple video streams |
US9020203B2 (en) | 2012-05-21 | 2015-04-28 | Vipaar, Llc | System and method for managing spatiotemporal uncertainty |
JP5791082B2 (en) | 2012-07-30 | 2015-10-07 | 国立大学法人横浜国立大学 | Image composition apparatus, image composition system, image composition method and program |
US9710968B2 (en) | 2012-12-26 | 2017-07-18 | Help Lightning, Inc. | System and method for role-switching in multi-reality environments |
US9940750B2 (en) | 2013-06-27 | 2018-04-10 | Help Lighting, Inc. | System and method for role negotiation in multi-reality environments |
WO2015079441A1 (en) * | 2013-11-26 | 2015-06-04 | Yoav Shefi | Method and system for constructing a virtual image anchored onto a real-world object |
JP2015191480A (en) * | 2014-03-28 | 2015-11-02 | 株式会社ソニー・コンピュータエンタテインメント | Information processor, operation method of object and operation program of object |
US10080963B2 (en) | 2014-03-28 | 2018-09-25 | Sony Interactive Entertainment Inc. | Object manipulation method, object manipulation program, and information processing apparatus |
JP6786792B2 (en) * | 2015-12-03 | 2020-11-18 | セイコーエプソン株式会社 | Information processing device, display device, information processing method, and program |
WO2018141414A1 (en) * | 2017-02-06 | 2018-08-09 | Photonic Sensors & Algorithms, S.L. | Device and method for obtaining depth information from a scene |
JP6739847B2 (en) | 2018-09-12 | 2020-08-12 | 株式会社アルファコード | Image display control device and image display control program |
WO2021039395A1 (en) * | 2019-08-30 | 2021-03-04 | 株式会社Nttドコモ | Projection control device and projection system |
JP6804624B2 (en) * | 2019-11-22 | 2020-12-23 | 株式会社ミツトヨ | Measurement data collection device and program |
JP7127659B2 (en) | 2020-02-07 | 2022-08-30 | カシオ計算機株式会社 | Information processing device, virtual/reality synthesis system, method for generating learned model, method for executing information processing device, program |
TWI813072B (en) * | 2021-11-17 | 2023-08-21 | 瑞昱半導體股份有限公司 | Electronic apparatus and method used for object tracking |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH10108198A (en) * | 1996-09-30 | 1998-04-24 | Sanyo Electric Co Ltd | Image area integration method |
JP2000261828A (en) * | 1999-03-04 | 2000-09-22 | Toshiba Corp | Stereoscopic video image generating method |
JP4136420B2 (en) * | 2002-03-29 | 2008-08-20 | キヤノン株式会社 | Information processing method and apparatus |
JP4163914B2 (en) * | 2002-09-04 | 2008-10-08 | 日本放送協会 | Cutout video generation device, cutout video generation method, and cutout video generation program |
JP4481663B2 (en) * | 2004-01-15 | 2010-06-16 | キヤノン株式会社 | Motion recognition device, motion recognition method, device control device, and computer program |
JP2006127530A (en) * | 2005-10-31 | 2006-05-18 | Toshiba Corp | Method and device for extracting object in moving image |
-
2008
- 2008-07-17 JP JP2008186501A patent/JP2009134693A/en active Pending
-
2012
- 2012-11-28 JP JP2012260297A patent/JP5474169B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2013077307A (en) | 2013-04-25 |
JP2009134693A (en) | 2009-06-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5474169B2 (en) | Image processing apparatus and image processing method | |
US8280115B2 (en) | Image processing apparatus and image processing method | |
JP4136420B2 (en) | Information processing method and apparatus | |
US10339712B2 (en) | Image processing apparatus and image processing method | |
US8760470B2 (en) | Mixed reality presentation system | |
JP4847203B2 (en) | Information processing method and information processing apparatus | |
US9767611B2 (en) | Information processing apparatus and method for estimating depth values using an approximate plane | |
US20060239525A1 (en) | Information processing apparatus and information processing method | |
US9779699B2 (en) | Image processing device, image processing method, computer readable medium | |
US8699749B2 (en) | Computer-readable storage medium, image processing apparatus, image processing system, and image processing method | |
US20090168027A1 (en) | Projector system employing depth perception to detect speaker position and gestures | |
JP2005293141A (en) | Method and device for detecting marker, and method for estimating position and attitude | |
JP6744747B2 (en) | Information processing apparatus and control method thereof | |
JP2017204673A (en) | Image processing system, image processing method and program | |
CN114742863A (en) | Method and apparatus with slip detection and correction | |
JP2018067115A (en) | Program, tracking method and tracking device | |
US11079840B2 (en) | Operation determination device and operation determination method | |
JP2007293453A (en) | Method for acquiring color information from image | |
WO2020032254A1 (en) | Attention target estimating device, and attention target estimating method | |
JP2008146108A (en) | Index, image processor and image processing method | |
US11275434B2 (en) | Information processing apparatus, information processing method, and storage medium | |
JP4745724B2 (en) | Image processing method and image processing apparatus | |
JP4323910B2 (en) | Image composition apparatus and method | |
CN109765990B (en) | Picture display control method and picture display control system | |
JP2010039999A (en) | Image segmentation method, program and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20130925 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20131011 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20131209 |
|
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: 20140106 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20140204 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 5474169 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |
|
LAPS | Cancellation because of no payment of annual fees |