JP2019012516A - Image processor and image processing method - Google Patents
Image processor and image processing method Download PDFInfo
- Publication number
- JP2019012516A JP2019012516A JP2018076383A JP2018076383A JP2019012516A JP 2019012516 A JP2019012516 A JP 2019012516A JP 2018076383 A JP2018076383 A JP 2018076383A JP 2018076383 A JP2018076383 A JP 2018076383A JP 2019012516 A JP2019012516 A JP 2019012516A
- Authority
- JP
- Japan
- Prior art keywords
- image data
- image
- processing apparatus
- interest
- image processing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000003672 processing method Methods 0.000 title claims 2
- 238000006243 chemical reaction Methods 0.000 claims abstract description 12
- 238000001514 detection method Methods 0.000 claims description 21
- 238000013459 approach Methods 0.000 claims description 6
- 230000002194 synthesizing effect Effects 0.000 claims description 4
- 230000015572 biosynthetic process Effects 0.000 claims description 3
- 238000003786 synthesis reaction Methods 0.000 claims description 3
- 238000003384 imaging method Methods 0.000 claims 2
- 238000000034 method Methods 0.000 abstract description 40
- 239000011159 matrix material Substances 0.000 description 16
- 238000010586 diagram Methods 0.000 description 8
- 230000006870 function Effects 0.000 description 3
- 230000005484 gravity Effects 0.000 description 3
- 230000003287 optical effect Effects 0.000 description 2
- 239000003086 colorant Substances 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 239000012634 fragment Substances 0.000 description 1
- 238000005070 sampling Methods 0.000 description 1
Images
Abstract
Description
本発明は、球状の画像表す平面の画像データを保持するための画像処理技術に関する。 The present invention relates to an image processing technique for holding plane image data representing a spherical image.
ヘッドマウントディスプレイなどを装着した視聴者に対して、視聴者の視線の動きに合わせて画像を表示する技術が知られている。ある位置における周囲360度すべての画像を表す全天球画像のうち、視聴者の視線の方向に合わせて一部の画像を表示することにより、視聴者はその場にいるかのような臨場感を体感することができる。全天球画像は、全方向の画像を表すため、データ量が膨大である。そこで近年、全天球画像を適切に保存する方法が検討されている。特許文献1に開示された方法では、全天球画像を複数の断片画像に分割し、変化の乏しい空や地面などの上下の極部分は平面円に投影して極座標で表現し、極部分以外の部分は長方形に補間して直交座標系に基づく圧縮処理を適用する。これにより、全天球画像を効率的に圧縮している。
A technique for displaying an image in accordance with the movement of the viewer's line of sight for a viewer wearing a head-mounted display or the like is known. By displaying a part of the omnidirectional image representing all 360-degree images at a certain position in accordance with the direction of the viewer's line of sight, the viewer can feel as if they are present. You can experience it. Since the omnidirectional image represents an image in all directions, the amount of data is enormous. Therefore, in recent years, methods for appropriately storing omnidirectional images have been studied. In the method disclosed in
しかしながら特許文献1に開示された方法では、全天球画像が領域によって異なる座標系で表現されているため、全天球画像から表示画像を生成するためには、領域ごとに異なる処理が必要になってしまう。そこで本発明は、全天球画像を分割して領域ごとに異なる処理を必要とせず、適切に平面画像に変換することを目的とする。
However, in the method disclosed in
上記課題を解決するため本発明は、球状の画像を表すための少なくとも1つ以上の入力画像データを取得する取得手段と、前記入力画像データにおける注目領域を決定する決定手段と、前記注目領域に基づいて、前記入力画像データを、正距円筒図法により球状の画像の少なくとも一部を表す出力画像データに変換する変換手段とを有することを特徴とする。 In order to solve the above problems, the present invention provides an acquisition unit that acquires at least one input image data for representing a spherical image, a determination unit that determines a region of interest in the input image data, And converting means for converting the input image data into output image data representing at least a part of a spherical image by equirectangular projection.
本発明によれば、全天球画像を適切に平面画像に変換することができる。 According to the present invention, an omnidirectional image can be appropriately converted into a planar image.
以下、本発明の実施形態について、図面を参照して説明する。なお、以下の実施形態は本発明を必ずしも限定するものではなく、また、本実施形態で説明されている特徴の組み合わせの全てが本発明の解決手段に必須のものとは限らない。なお、同一の構成については、同じ符号を付して説明する。 Hereinafter, embodiments of the present invention will be described with reference to the drawings. It should be noted that the following embodiments do not necessarily limit the present invention, and not all combinations of features described in the present embodiment are essential for the solution means of the present invention. In addition, about the same structure, the same code | symbol is attached | subjected and demonstrated.
<第1実施形態>
第1実施形態では、全天球画像において高解像度に保存したい注目領域を決定し、注目領域が極付近の位置に相当するように全天球画像の軸を変更した上で、正距円筒法により平面画像に変換する方法について説明する。なお全天球画像とは、球状の画像であり全方位画像、全天周画像などとも呼ばれ、ある位置からの360度全方位のシーンを表す画像を意味する。また本実施形態における画像処理装置は、頭に装着して画像を視聴できるヘッドマウントディスプレイ(以下、HMD)に用いられる全天球画像を保存する。HMDでは、装着した視聴者の視線に応じて、本実施形態により適切に保存された全天球画像における視線方向の部分的な画像がディスプレイに表示される。HMDに表示する画像は、HMDあるいはHMDへの画像出力を実行する画像処理装置が行うものとする。HMDに表示される画像は、本実施形態における画像処理が保存する全天球画像、またはその一部に各種画像処理を施した後に得られる画像である。
<First Embodiment>
In the first embodiment, an attention area to be stored at a high resolution is determined in the omnidirectional image, the axis of the omnidirectional image is changed so that the attention area corresponds to a position near the pole, and then the equirectangular cylinder method is used. A method for converting to a flat image will be described. The omnidirectional image is a spherical image and is also called an omnidirectional image, an omnidirectional image, or the like, and means an image representing a 360-degree omnidirectional scene from a certain position. In addition, the image processing apparatus according to the present embodiment stores an omnidirectional image used in a head mounted display (hereinafter, HMD) that can be worn on the head and viewed. In the HMD, a partial image in the line-of-sight direction in the omnidirectional image appropriately stored according to the present embodiment is displayed on the display according to the line of sight of the viewer who wears it. The image displayed on the HMD is assumed to be performed by the image processing apparatus that executes image output to the HMD or HMD. The image displayed on the HMD is an omnidirectional image stored by image processing in the present embodiment, or an image obtained after various image processing is performed on a part thereof.
本実施形態における画像処理装置のハードウェア構成について、図1を用いて説明する。本実施形態における画像処理装置は、画像データを読み込んで各種画像処理を実行するパーソナルコンピュータを例に説明する。CPU101は、RAM102をワークメモリとして、ROM103及びハードディスクドライブ(HDD)105に格納されたプログラムを実行し、システムバス110を介して後述する各構成を制御する。これにより、後述する様々な処理が実行される。HDDインタフェイス(I/F)104は、HDD105や光ディスクドライブなどの二次記憶装置を接続する。例えばシリアルATA(SATA)等のインタフェイスである。CPU101は、HDDI/F104を介して、HDD105からのデータ読み出し、およびHDD105へのデータ書き込みが可能である。さらにCPU101は、HDD105に格納されたデータをRAM102に展開し、同様に、RAM102に展開されたデータをHDD105に保存することが可能である。そしてCPU101は、RAM102に展開したデータをプログラムとみなし、実行することができる。入力インタフェイス(I/F)106は、キーボードやマウス、デジタルカメラ、スキャナなどの入力デバイス107を接続する、例えばUSBやIEEE1394等のシリアルバスインタフェイスである。CPU101は、入力I/F106を介して入力デバイス107からデータを読み込むことが可能である。出力インタフェイス(I/F)108は、ディスプレイなどの画像表示装置の出力デバイス109を接続する。出力インタフェイス108は例えばDVIやHDMI(登録商標)等の映像出力インタフェイスである。CPU101は、出力I/F108を介して出力デバイス109にデータを送り、表示を実行させることができる。前述の通り本実施形態では、出力デバイス109としてHMDを想定している。
A hardware configuration of the image processing apparatus according to the present embodiment will be described with reference to FIG. The image processing apparatus according to the present embodiment will be described using a personal computer that reads image data and executes various image processes as an example. The
図2は、本実施形態における画像処理装置の論理構成を示すブロック図である。CPU101は、ROM103又はHDD105に格納されたプログラムを読み出してRAM102をワークエリアとして実行することで、図2に示す各機能ブロックとしての役割を果たす。なお、全ての機能ブロックの役割をCPU101が果たす必要はなく、各機能ブロックに対応する専用の処理回路を設けるようにしてもよい。
FIG. 2 is a block diagram illustrating a logical configuration of the image processing apparatus according to the present embodiment. The
画像取得部201は、全天球を表す入力画像データを取得する。全天球を表す入力画像データは、ある地点における全ての向きの入射光線の色を保存した画像データのことである。ここで取得する入力画像データは、正距円筒図法により平面に展開された画像データである。図5は、正距円筒図法により表された全天球画像を示す。正距円筒図法とは、地図投影法の1つとして知られ、地球の緯度・経度を平面の縦・横それぞれに割り当てることで平面に展開する図法である。全天球画像の画像データを保存する方式として、正距円筒図法が用いられることが知られている。正距円筒図法では画像データの横軸を方位角θとする。方位角θの範囲は[−π π]である。また、縦軸を仰角φとし、仰角φの範囲は[−π/2 π/2]である。画像データは、方位角θおよび仰角φを離散化した位置における色情報を画素値として格納された画素からなる。画像データにおいて幅はw画素、高さはh画素とする。正距円筒図法における仰角φの変化に対する分解能の変化を示すグラフを図6に示す。分解能とは、全天球画像の1画素に入射する光線の角度を表す。図6に示すグラフは、仰角0度における画像の分解能に対する各仰角における分解能の比率を表している。図6に示すグラフによれば、仰角の絶対値が70度を超えるような領域では、仰角が0度の領域と比べて分解能が3倍以上になっている。このように仰角の絶対値が大きな領域ほど分解能が高くなることがわかる。
The
正距円筒図法により平面に展開された全天球画像を球面にマッピングしたときに、北極(天頂)、南極(天底)にあたる位置を極と呼ぶことにする。正距円筒図法により表された画像においては、極は1点ではなく広がりを持っており、画像の最上部の行と最下部の行が極の位置に相当する。一方、球面における赤道の位置は、全天球画像における中央横線に相当する。図6に示す通り、正距円筒図法により平面に展開された全天球画像では、極の位置が最も高い分解能を持ち、赤道に相当する領域に比べて、極に近い領域ほど分解能は高くなる。従って、極領域に色情報を格納された被写体は、そのほかの領域に色情報を格納された被写体と比較して、多くの画素を使って高い解像度で保存することができることになる。 The positions corresponding to the north pole (zenith) and the south pole (nadir) when the omnidirectional image developed on a plane by equirectangular projection is mapped to a spherical surface are called poles. In an image represented by equirectangular projection, the poles are not single points but have a spread, and the uppermost row and the lowermost row of the image correspond to the positions of the poles. On the other hand, the position of the equator on the spherical surface corresponds to the central horizontal line in the omnidirectional image. As shown in FIG. 6, in the omnidirectional image developed on a plane by equirectangular projection, the position of the pole has the highest resolution, and the resolution is higher in the region closer to the pole than in the region corresponding to the equator. . Therefore, a subject whose color information is stored in the polar region can be stored with a higher resolution using more pixels than a subject whose color information is stored in other regions.
HMDを装着した視聴者の視線方向に合わせて、全天球画像の部分的な領域(以降、部分画像とする)をHMDのディスプレイに表示する際には、部分画像に対して各種画像処理を施されることが想定される。縮小などの画像処理を全天球画像または部分画像に実行した結果、部分画像の画質は低下してしまう場合がある。そこで本実施形態では、正距円筒図法により展開された平面の画像では、極に近い領域ほど分解能が高いことを利用する。全天球画像においてより高解像度に保存しておくことが望ましい領域を注目領域として特定し、注目領域の位置が極領域の位置に相当するように、全天球画像を変換した上で保存しておく。 When displaying a partial area of the omnidirectional image (hereinafter referred to as a partial image) on the display of the HMD in accordance with the viewing direction of the viewer wearing the HMD, various image processing is performed on the partial image. It is assumed that it will be applied. As a result of performing image processing such as reduction on the omnidirectional image or the partial image, the image quality of the partial image may deteriorate. Therefore, in the present embodiment, it is used that the resolution closer to the pole is higher in the planar image developed by the equirectangular projection. Identify the region of the omnidirectional image that should be stored at a higher resolution as the region of interest, convert the omnidirectional image so that the position of the region of interest corresponds to the position of the polar region, and save it. Keep it.
注目領域決定部202は、入力画像データにおいて高解像度に保存したい領域を特定する。本実施形態では、出力I/F108を介して出力デバイス109であるディスプレイに処理対象とする全天球画像を表示し、ユーザに高解像度に保存したい被写体を指定させる。指定は、マウスやタッチなどの入力デバイス107を介して行う。本実施形態では、ユーザは注目領域としたい被写体を、マウスを用いてクリックするものとする。
The attention
変換部206は、入力画像データを注目領域の位置に応じて変換する。変換部206は、回転量算出部203と画像回転部204からなる。回転量算出部203は、指定された注目点の位置を全天球画像の極領域に対応づけるための回転量を算出する。なお全天球画像は、正距円筒図法によって平面図に展開されているものの、球状の画像と対応している。ここで回転量とは、全天球画像を球面にマッピングした場合に座標軸を回転させ、極の位置を変更するために必要な回転の角度を意味するものである。画像回転部204は、回転量算出部203が算出した回転量に従って、画像取得部206が取得した全天球画像を実質的に回転させる。
The
出力部205は、画像回転部204により指定された注目点の位置を全天球画像の極領域に対応づけるように入力画像データを変換した出力画像データを出力する。
The
また、図7に全天球画像から作成した表示画像の例を示す。前述の通り、本実施形態における画像処理装置が保持する全天球画像を、他の画像処理装置またはHMDが読み出し、図7に示すような表示画像を生成する。表示画像は、内側に全天球画像を張り付けた球を仮想カメラで撮影することで作成できる。図7からわかるように、表示画像は全天球画像の一部の領域を参照して作成される。従って本実施形態では球状の全天球画像を入力としているが、表示画像に必要な半球状の画像など全天球のうちの一部だけが画素データを持ち、一部の領域の画素データが無くても構わない。 FIG. 7 shows an example of a display image created from the omnidirectional image. As described above, the omnidirectional image held by the image processing apparatus according to the present embodiment is read by another image processing apparatus or HMD, and a display image as shown in FIG. 7 is generated. A display image can be created by shooting a sphere with a celestial sphere image on the inside with a virtual camera. As can be seen from FIG. 7, the display image is created with reference to a partial region of the omnidirectional image. Therefore, in this embodiment, a spherical omnidirectional image is input, but only a part of the omnisphere such as a hemispherical image necessary for the display image has pixel data, and pixel data of a part of the region has pixel data. It does n’t matter.
図3は、第1実施形態における画像処理の流れを示すフローチャートである。CPU101は、図3に示すフローチャートを実行可能なプログラムを読み出して実行することによって実現される。なお、以下のフローチャートの説明において、各ステップの符号をSと表記することとする。まずS301において画像取得部201は、全天球を平面画像に展開した入力画像データを取得する。
FIG. 3 is a flowchart showing the flow of image processing in the first embodiment. The
S302において注目領域決定部202は、ユーザによる入力に従い、注目したい領域を定義可能な注目点を決定する。注目点とは、注目領域を代表する点である。前述の通りユーザは、ディスプレイに表示された全天球画像において、注目被写体の位置をクリックする。注目領域決定部202は、クリックされた位置を注目点(xi、yi)とする。ここでxとyは、画像中の座標を示し、iは決定した注目点のインデックスを示す。なお、クリックではなく、被写体を含む領域を注目領域として指定された場合は、領域の重心位置を注目点(xi、yi)とする。
In step S <b> 302, the attention
S303において回転量算出部203は、注目点の位置に基づいて入力画像データの回転量を算出する。本実施形態では画像の回転は回転行列Rを使って表す。回転はオイラー角やクォータニオンなど、別の表現形式を用いてもよい。この回転量算出処理の詳細については後述する。
In S303, the rotation
S304において画像回転部204は、全天球画像である入力画像データIに回転処理を実行して、画像における極領域に注目被写体が相当するように変換した全天球画像である出力画像データI’を出力する。ここで、全天球画像の回転処理は画像座標系で回転するのではなく、球面座標系で回転させる。すなわち、2次元平面上で回転するのではなく、全天球画像を球面にマッピングして、マッピングした球を回転させ、回転させた後に再度正距円筒図法により展開した平面上の画像に変換する。回転後の出力画像データI’における各画素は回転を考慮して入力画像データIから画素値をサンプリングして算出する。これは、まず、回転後の出力画像データI’における各画素(x’,y’)に対して、その画素に対応する取得した入力画像データIの座標(x、y)を計算する。次に、座標(x、y)の画素値をサンプリングして出力画像データI’における画素(x’,y’)の画素値とする。以下では、回転処理後の出力画像データI’の座標(x’,y’)に対応する入力画像データIの座標(x、y)を求める方法について述べる。まず、画像座標系の(x’,y’)を方位角と仰角に変換する。入力画像データIの幅をw、高さをhとすると、(x’,y’)に対応する方位角θ’、仰角φ’は式(1)により計算する。
In S304, the
次に方位角θ’、仰角φ’を回転行列で表し、S303において算出した全天球画像の回転行列Rの逆行列R−1と積算した行列Mを方位角、仰角の表現に変換することにより、取得した全天球画像における方位角θ、仰角φを算出する。方位角θ、仰角φを算出は、式(2)により算出される。 Next, the azimuth angle θ ′ and the elevation angle φ ′ are represented as rotation matrices, and the matrix M integrated with the inverse matrix R −1 of the rotation matrix R of the omnidirectional image calculated in S303 is converted into representations of azimuth angles and elevation angles. Thus, the azimuth angle θ and the elevation angle φ in the acquired omnidirectional image are calculated. The azimuth angle θ and the elevation angle φ are calculated by equation (2).
ここで、atanはアークタンジェント、asinはアークサイン関数を表す。 Here, atan represents an arc tangent and asin represents an arc sine function.
そして方位角θ、仰角φを取得した全天球画像における座標(x、y)に変換する。この変換は式(3)で計算できる。 Then, the azimuth angle θ and the elevation angle φ are converted into coordinates (x, y) in the acquired omnidirectional image. This conversion can be calculated by equation (3).
最後に、取得した入力画像データIの座標(x、y)の画素値を算出し、回転後の出力画像データI’の座標(x’,y’)の画素値とする。ここでは、座標(x、y)近傍の4画素から先見補間により画素値を算出し、回転後の出力画像データI’の座標(x’,y’)の画素値とする。ただし、線形補間に限らず、バイキュービックなどの補間法を利用してもよい。 Finally, the pixel value at the coordinates (x, y) of the acquired input image data I is calculated and set as the pixel value at the coordinates (x ′, y ′) of the output image data I ′ after rotation. Here, a pixel value is calculated by look-ahead interpolation from four pixels in the vicinity of the coordinates (x, y), and set as the pixel value of the coordinates (x ′, y ′) of the output image data I ′ after rotation. However, not only linear interpolation but also an interpolation method such as bicubic may be used.
S305において出力部205は、回転処理後の出力画像データと回転処理に用いた回転行列RをHDD105またはRAM102に出力する。以上が本実施形態の画像処理装置で行われる処理の流れである。
In step S <b> 305, the
ここで、S303において回転量算出部203が実行する回転量算出処理の詳細について説明する。回転量算出処理は、注目被写体が分解能の高い領域に相当するように入力画像データの回転量を算出する。全天球画像が正距円筒図法の場合は球の極である上下に近づくほど分解能が高く、全天球画像の中心の高さ(赤道付近)では分解能が低い。そのため、注目被写体が画像の上か下の領域、すなわち仰角の絶対値が大きくなる位置へ移動するような回転量を算出する。注目被写体が1つである場合はその点が片方の極に移動するように回転量を算出し、注目被写体が複数ある場合は1つもしくは2つの極に振り分けられるように回転量を算出する。図4は、回転量算出処理のフローチャートである。
Here, details of the rotation amount calculation processing executed by the rotation
S401において、注目点の数に応じて次に行う処理を選択する。注目領域決定部202が出力した注目点の数が1つの場合はS402、2つの場合はS403、3つ以上の場合はS409を実行する。
In step S401, a process to be performed next is selected according to the number of attention points. When the number of attention points output by the attention
S402では注目点を極の位置へ移動する回転行列を算出する。極は正距円筒図法により表された画像において上下の2つあるが、どちらを選択してもよい。図8は、取得した全天球画像の一例を示す。点801が与えられた1点の注目点であったとする。図9は、正距円筒図法により展開された全天球画像において、点801を極のうちの天頂の1点を表す点901に移動するように回転した場合の例を示す。S402では、注目点801が点901の位置に移動する回転量を算出する。全天球画像を球として考えたとき、極は全天球画像の1番上の行に相当するため、任意の位置にある点を極に移動するような回転はピッチ方向のみの回転で表せる。この場合の回転は、注目点801の仰角φaから点901の仰角π/2まで移動する回転であるため、回転量はπ/2−φaである。以上の通り、1つの注目点を極に移動するような回転量は、ピッチ方向π/2−φaにより算出する。
In S402, a rotation matrix for moving the attention point to the pole position is calculated. There are two poles at the top and bottom in the image represented by equirectangular projection, either of which may be selected. FIG. 8 shows an example of the acquired omnidirectional image. Assume that the
S403において、指定された2つの注目点の角度差に応じてさらに処理を分岐する。2点の角度差が90度未満であればS404へ、角度差が90度以上であればS409へ進む。S404では、2つの注目点が同じ極に近づくような回転量を算出する。一方S405からS407の処理では、2つの注目点が異なる極に近づくような回転量を算出する。 In S403, the process is further branched according to the angle difference between the two specified points of interest. If the angle difference between the two points is less than 90 degrees, the process proceeds to S404, and if the angle difference is 90 degrees or more, the process proceeds to S409. In S404, a rotation amount is calculated such that the two attention points approach the same pole. On the other hand, in the processing from S405 to S407, the rotation amount is calculated such that the two attention points approach different poles.
S404において、2つ注目点(θa、φa)(θb、φb)の中点を、片方の極へ移動するような回転量を算出する。この場合の極は上下2つのどちらを選択してもよい。球の回転を考えるため、2つの注目点の中点は画像座標上ではなく、球面座標上で計算する必要がある。たとえば中点の計算には、球面線形補間などが利用できる。中点(θc、φc)の1つを極に移動する回転量は、S402と同様に、仰角がπ/2になるようにピッチ方向にのみπ/2−φaを回転量として算出する。図10は、注目点802および803の2つを指定された場合の回転結果を示す図である。2つの注目点の中点が点1001のように天頂の極すなわち先頭の行に移動する回転量を算出する。一方S405では、指定された2つの注目点(θa、φa)(θb、φb)のうち、一方の注目点を極へ移動するための回転量を算出する。選択する注目点はどちらでもよいが、ここでは最初に指定された注目点(θa、φa)を選択するものとする。注目点の方位角と仰角をそれぞれθa、φaとすると、方位角はθaのまま、仰角をπ/2になるように、ピッチ方向にπ/2−φaだけ回転するような回転行列RAを式(4)の通りに算出する。
In S404, the amount of rotation is calculated so that the middle point of the two points of interest (θ a , φ a ) (θ b , φ b ) moves to one pole. In this case, either the upper or lower pole may be selected. In order to consider the rotation of the sphere, the midpoint of the two points of interest must be calculated on the spherical coordinates, not on the image coordinates. For example, spherical linear interpolation can be used to calculate the midpoint. The amount of rotation to move one of the midpoints (θ c , φ c ) to the pole is calculated as π / 2−φ a only in the pitch direction so that the elevation angle is π / 2, as in S402. To do. FIG. 10 is a diagram illustrating a rotation result when two
S406では、S405において算出した回転行列RAを入力画像データに適用した後、全天球画像においてS405で選択されなかった注目点(θb、φb)の方位角が0度となるようなヨー方向の回転量を算出する。これは、注目点の方位角をθbとしたとき、−θbだけ回転する回転行列RBを式(5)の通りに計算する。 In S406, after applying the rotation matrix RA calculated in S405 to the input image data, the azimuth of the attention point (θ b , φ b ) not selected in S405 in the omnidirectional image becomes 0 degree. The amount of rotation in the yaw direction is calculated. This is to calculate a rotation matrix R B that rotates by −θ b when the azimuth angle of the target point is θ b as shown in Equation (5).
S407において、入力画像データに回転行列RA、RBを適用した後の2つの注目点の中点(θc、φc)が正面となるようなピッチ方向の回転を行う回転行列Rcを算出する。回転行列RA、RBを適用することで、1つの注目点は極に移動し、もう1つの注目点は方位角0の位置(0、φB2)に移動している。そのため、2つの注目点の中点は式(6)によって表される。
(θ、φ)=(0、(π/2−φb2)×1/2) (6)
In step S407, a rotation matrix R c that performs rotation in the pitch direction so that the midpoints (θ c , φ c ) of the two attention points after applying the rotation matrices R A and R B to the input image data is the front surface. calculate. By applying the rotation matrices R A and R B , one point of interest has moved to the pole, and the other point of interest has moved to the position (0, φ B2 ) at the azimuth angle 0. Therefore, the midpoint between the two attention points is expressed by Equation (6).
(Θ, φ) = (0, (π / 2−φ b2 ) × 1/2) (6)
中点を正面(θ、φ)=(0、0)に移動するための回転を求めるには、ピッチ方向に−(π/2−φb2)×1/2だけ回転を行う回転行列RCを式(7)の通りに計算する。 In order to obtain rotation for moving the midpoint to the front (θ, φ) = (0, 0), a rotation matrix R C that rotates by − (π / 2−φ b2 ) × 1/2 in the pitch direction. Is calculated as in equation (7).
S408では、2つの注目点(θa、φa)(θb、φb)が互いに異なる極に近づくような回転を計算する。これはS405〜S407で計算した回転行列RA、RB、RCを積算することで計算できる。 In S408, the rotation is calculated such that the two points of interest (θ a , φ a ) (θ b , φ b ) approach different poles. This can be calculated by accumulating the rotation matrices R A, R B , and R C calculated in S405 to S407.
S409では、指定された3つ以上の注目点を2つのグループに分類する。本実施形態では、k−means法を用いて分類する。その際の注目点間の距離は球面座標上での距離を利用する。S409以降の処理では、分類された2つのグループの重心をそれぞれ2つの注目点として扱う。これにより、注目点が2つの場合と同様の処理を行うことができる。例えば、図8の点802、803、804が注目点として入力された場合、1つ目のグループが点804、2つ目のグループが点802と点803となる。1つ目のグループは点804が注目点となり、2つ目のグループは点802と点803の重心位置が注目点となる。以上が本実施形態の回転量算出部203で行われる回転量算出処理を完了する。
In S409, the specified three or more attention points are classified into two groups. In this embodiment, classification is performed using the k-means method. In this case, the distance between the points of interest uses the distance on the spherical coordinates. In the processing after S409, the centroids of the two classified groups are treated as two attention points, respectively. As a result, the same processing as in the case where there are two attention points can be performed. For example, when the
以上の通り第1実施形態では、全天球画像など球状の画像において分解能の高い領域に保存しておくことが望まれる被写体(領域)を特定し、特定した被写体が全天球画像において極領域に相当するように回転した全天球画像に変換して保存しておく。これにより、全天球画像または全天球画像の部分画像に対して、縮小などの画像処理を行う際には、注目被写体を高解像度に維持することができる。 As described above, in the first embodiment, a subject (region) that is desired to be stored in a high-resolution region in a spherical image such as a spherical image is specified, and the specified subject is a polar region in the spherical image. Is converted into a omnidirectional image rotated so as to correspond to and saved. Thereby, when performing image processing such as reduction on the omnidirectional image or a partial image of the omnidirectional image, the subject of interest can be maintained at a high resolution.
<第2実施形態>
第1実施形態では、1枚の全天球画像を入力画像データとして、所望の回転処理後の全天球画像を保存する方法について説明した。第2実施形態においては、複数枚の全天球画像ではない撮像画像を合成して全天球画像を保存する場合に、注目被写体を高解像度に保存する方法について説明する。この例では、合成後の画像ではなく、合成前に座標系を回転して全天球画像を生成する。なお、第1実施形態と同様の構成、処理については同一の符号を付し、詳細な説明を省略する。
Second Embodiment
In the first embodiment, the method of storing a omnidirectional image after a desired rotation process using one omnidirectional image as input image data has been described. In the second embodiment, a method for storing a subject of interest with high resolution when a plurality of captured images that are not omnidirectional images are combined and the omnidirectional image is stored will be described. In this example, not the synthesized image but the omnidirectional image is generated by rotating the coordinate system before the synthesis. In addition, about the structure and process similar to 1st Embodiment, the same code | symbol is attached | subjected and detailed description is abbreviate | omitted.
図12は、第2実施形態における画像処理装置の論理構成を示すブロック図である。また、図13は、図12に示す各構成が実行する処理のフローチャートを示す。CPU101は、ROM103又はHDD105に格納された図13のフローチャートを実現できるプログラムを読み出してRAM102をワークエリアとして実行することで、図12に示す各構成としての役割を果たす。
FIG. 12 is a block diagram illustrating a logical configuration of the image processing apparatus according to the second embodiment. FIG. 13 is a flowchart of processing executed by each configuration shown in FIG. The
S1301において画像取得部1201は、HDD105またはRAM102から取得した複数枚の画像データを姿勢取得部1202へ出力する。なお、複数枚の画像データは同じ視点から撮影したものとする。本実施形態でも第1実施形態と同様に全天球画像は正距円筒図法により展開された平面画像であるものとして扱う。また、説明を簡単にするため、画像データはレンズの光軸と画像面の交点が画像の中心で、歪みがなく、同一視点から撮影されたものを考えるが、以下のステップでは、これらを考慮した処理を行うようにしてもよい。
In step S <b> 1301, the
S1302において姿勢取得部1202は、画像取得部1201から入力された画像を撮影した際のカメラの姿勢を示す姿勢情報をHDD105またはRAM102から取得する。カメラの姿勢はカメラがどちらを向いているかという情報であり、回転行列で表現される。ここでは、カメラの姿勢があらかじめ計算されているものとしたが、画像から算出しても構わない。
In step S <b> 1302, the
S1303において注目領域決定部1203は、1つ以上の注目領域を注目点として決定する。注目点(xi、yi)を極座標系に変換し、方位角θi,仰角φi算出する。これは、注目点を含む画像を撮影したカメラの姿勢を表す回転行列Rjを基にカメラの視点から画像中の注目点(xi、yi)を通る光線の角度θi,φiを算出することで取得する。ここで、jは画像のインデックスを表す。カメラの焦点距離をfとすると、光線と画像平面の交点の座標Xは式(8)により計算できる。
In step S1303, the attention
原点からみたときの3次元点Xの方位角と仰角をθi,φiとし、注目領域決定部1203は注目点(θi,φi)を回転量算出部1204に出力する。
The azimuth and elevation angles of the three-dimensional point X when viewed from the origin are θ i and φ i , and the attention
S1304において回転量算出部1204は、注目点(θi,φi)の位置に基づいて画像の回転量を算出し、姿勢更新部1205に出力する。本実施形態では、第1実施形態と同様にして全天球画像の回転量を計算する。
In step S <b> 1304, the rotation
S1305において姿勢更新部1205は、全天球画像の回転量を表す回転行列Rと各画像を撮影したカメラの姿勢Rjに基づいて、カメラの姿勢情報を更新する。カメラの姿勢Rjに画像の回転量を表す回転行列Rを積算した姿勢Rj’次の処理でカメラの姿勢として利用する。この更新により、入力画像の座標系を回転した座標系で合成できるため、合成で得られる全天球画像を回転することができる。
S1306において画像合成部1206は、複数の画像データIjと更新した姿勢Rjを入力として、画像を合成する。画像合成部1206は、入力された各カメラの姿勢に基づいて各カメラにより撮像された画像を球面座標系の全天球画像に投影する。そして、各画像を投影した際の重複領域において、重複する画像の画素値をブレンドする。画像合成部1206は、合成した全天球画像データを出力部1207に出力する。
In step S < b> 1306, the
S1307では、出力部1207が回転後の全天球画像とその回転行列RをHDD105またはRAM102に出力する。以上で第2実施形態における画像処理は完了する。本実施形態によれば、複数枚の入力画像から全天球画像を合成する際においても、注目領域が高解像度に保存できる位置に格納されるような座標系で合成することで、注目被写体を高解像度に保存することができる。
In step S <b> 1307, the
<第3実施形態>
上述の実施形態では、手動で設定した注目領域に基づいて1枚の全天球画像に回転処理した後に保存する方法について説明した。第3実施形態においては、自動で注目被写体を検出して保存する方法について説明する。この例では、設定した検出モードに基づいて注目被写体を検出する。なお、第1実施形態と同様の構成、処理については同一の符号を付し、詳細な説明を省略する。
<Third Embodiment>
In the above-described embodiment, a method has been described in which a single omnidirectional image is stored after being rotated based on a manually set attention area. In the third embodiment, a method for automatically detecting and storing a subject of interest will be described. In this example, the subject of interest is detected based on the set detection mode. In addition, about the structure and process similar to 1st Embodiment, the same code | symbol is attached | subjected and detailed description is abbreviate | omitted.
図14は、第3実施形態における画像処理装置の論理構成を示すブロック図である。また、図15は、図14に示す各構成が実行する処理のフローチャートを示す。CPU101は、ROM103又はHDD105に格納された図14のフローチャートを実現できるプログラムを読み出してRAM102をワークエリアとして実行することで、図14に示す各構成としての役割を果たす。
FIG. 14 is a block diagram illustrating a logical configuration of the image processing apparatus according to the third embodiment. FIG. 15 is a flowchart of processing executed by each configuration shown in FIG. The
S1401では、検出モード選択部1401は画像から注目領域を検出する方法を決定するためのモードを選択する。検出モードは、入力された全天球画像において注目領域として設定する特徴を特定するモードである。ここでは検出モードの例として、人の顔を検出する人物モード、動物を検出するペットモードがあるものとする。人物モードとペットモードのうちいずれかをユーザが選択する。検出モード選択部1401は、指定されたモードを注目領域決定部1402に出力する。検出モードは、統計情報を検出に利用する統計モード、撮影時の情報を利用する撮影時着目モード、周波数の高い領域を検出する風景モードなど別のモードを選択できるようにしてもよい。また実施形態では、指定した検出モードにおいて注目領域が検出されない場合に使用される既定の検出モードも設定する。
In S1401, the detection
S1402において、注目領域決定部1402が検出モード選択部1401から出力された検出モードに基づいて、自動的に入力画像データから注目点を決定する。検出モードが人物モードである場合、入力画像データに対して顔検出処理を行い、検出された顔領域を注目領域とする。ペットモードである場合、入力画像データから動物検出処理を行い、検出された動物領域を注目領域とする。注目領域が1つも検出されない場合は、既定の検出モードを使用して検出を行う。ここでは既定の検出モードとして、風景モードが設定されている。風景モードでは、入力された全天球画像を、複数の領域に分割して、各領域において周波数を計算し、高周波成分の多い領域を注目領域とする。注目領域決定部1402は、全天球画像において検出された領域の重心位置を注目点(xi、yi)とする。
In step S <b> 1402, the attention
以上で第3実施形態における画像処理は完了する。本実施形態によれば、検出モードに基づいて注目領域を自動で指定することができ、シーンに合わせて注目被写体を高解像度に保存することができる。 Thus, the image processing in the third embodiment is completed. According to the present embodiment, the attention area can be automatically specified based on the detection mode, and the subject of interest can be stored at a high resolution according to the scene.
<その他の実施形態>
前述の実施形態では、高解像度に保存しておくことが望ましい注目領域を特定し、注目領域が極付近の位置に相当するように、全天球画像を生成した。前述の通り、正距円筒図法により展開された平面図面では、赤道付近はもっとも分解能が低い。そこで全天球画像における被写体のうち、地面や床、または空など非注目領域を特定し、非注目領域を優先的に赤道付近の位置に相当するように全天球画像を生成してもよい。これは、分解能が高い位置に非注目領域が対応することのないように全天球画像を生成することで、分解能が高い位置に保存しておくことが望まれる注目領域を間接的に特定していることに他ならない。
<Other embodiments>
In the above-described embodiment, an attention area that is desired to be stored at a high resolution is specified, and an omnidirectional image is generated so that the attention area corresponds to a position near the pole. As described above, in the plan view developed by the equirectangular projection, the resolution near the equator is the lowest. Therefore, among the subjects in the omnidirectional image, a non-focused area such as the ground, floor, or sky may be specified, and the omnidirectional image may be generated so that the non-focused area preferentially corresponds to a position near the equator. . This is because an omnidirectional image is generated so that a non-attention area does not correspond to a position with a high resolution, thereby indirectly identifying an attention area that is desired to be stored at a position with a high resolution. It is none other than that.
本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。 The present invention supplies a program that realizes one or more functions of the above-described embodiments to a system or apparatus via a network or a storage medium, and one or more processors in a computer of the system or apparatus read and execute the program This process can be realized. It can also be realized by a circuit (for example, ASIC) that realizes one or more functions.
201 画像取得部
202 注目領域決定部
203 回転量算出部
204 画像回転部
205 出力部
DESCRIPTION OF
Claims (20)
前記入力画像データにおける注目領域を決定する決定手段と、
前記注目領域に基づいて、前記入力画像データを、正距円筒図法により前記画像の少なくとも一部を表す出力画像データに変換する変換手段とを有することを特徴とする画像処理装置。 Obtaining means for obtaining at least one or more input image data for representing an image;
Determining means for determining a region of interest in the input image data;
An image processing apparatus comprising: conversion means for converting the input image data into output image data representing at least a part of the image by equirectangular projection based on the attention area.
前記出力画像データが表す全天球画像は、前記入力画像データが表す全天球画像における被写体の位置を変更された画像であることを特徴とする請求項1または2に記載の画像処理装置。 The input image data and the output image data represent a spherical image,
The image processing apparatus according to claim 1, wherein the omnidirectional image represented by the output image data is an image obtained by changing a position of a subject in the omnidirectional image represented by the input image data.
前記変換手段は、前記取得手段が取得した入力画像データを球面座標系において回転することにより、前記出力画像データを得ることを特徴とする請求項1乃至7の何れか一項に記載の画像処理装置。 The acquisition means acquires one input image data representing a spherical image,
The image processing according to claim 1, wherein the conversion unit obtains the output image data by rotating the input image data acquired by the acquisition unit in a spherical coordinate system. apparatus.
前記回転量に従って前記入力画像データを回転する回転処理手段とを有することを特徴とする請求項8に記載の画像処理装置。 The conversion means calculates a rotation amount of the attention point in a spherical coordinate system so that the coordinates of the attention point representing the attention area approach the upper part or the lower part of the output image data;
The image processing apparatus according to claim 8, further comprising a rotation processing unit that rotates the input image data according to the rotation amount.
前記決定手段は、前記検出モードに基づいて複数の注目領域を自動で検出することを特徴とする請求項1乃至9の何れか一項に記載の画像処理装置。 Furthermore, it has a selection means for selecting a mode for determining the region of interest,
The image processing apparatus according to claim 1, wherein the determination unit automatically detects a plurality of regions of interest based on the detection mode.
前記姿勢情報に基づいて、前記複数の撮像装置から全天球画像を合成する合成手段を有し、
前記変換手段は、前記合成手段が合成した全天球画像を、前記出力画像データに変換することを特徴とする請求項14に記載の画像処理装置。 Furthermore, posture acquisition means for acquiring posture information indicating the posture of the camera when each of the plurality of imaging devices is photographed,
Based on the posture information, comprising a synthesizing unit for synthesizing an omnidirectional image from the plurality of imaging devices;
The image processing apparatus according to claim 14, wherein the conversion unit converts the omnidirectional image synthesized by the synthesis unit into the output image data.
前記注目領域に基づいて、前記入力画像データを、正距円筒図法により球状の画像を表す出力画像データに変換する変換工程とを有し、
前記変換工程は、前記出力画像データを球面にマッピングした場合に、前記注目領域が球面の極付近の位置に相当するように、前記入力画像データを前記出力画像データに変換することを特徴とする画像処理方法。 An acquisition step of acquiring at least one or more input image data for representing a spherical image; a determination step of determining a region of interest in the input image data;
Converting the input image data into output image data representing a spherical image by equirectangular projection based on the region of interest;
The converting step converts the input image data into the output image data so that the region of interest corresponds to a position near a pole of a spherical surface when the output image data is mapped onto a spherical surface. Image processing method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US16/007,323 US10664947B2 (en) | 2017-06-30 | 2018-06-13 | Image processing apparatus and image processing method to represent part of spherical image in planar image using equidistant cylindrical projection |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2017128956 | 2017-06-30 | ||
JP2017128956 | 2017-06-30 |
Publications (3)
Publication Number | Publication Date |
---|---|
JP2019012516A true JP2019012516A (en) | 2019-01-24 |
JP2019012516A5 JP2019012516A5 (en) | 2021-05-27 |
JP7150460B2 JP7150460B2 (en) | 2022-10-11 |
Family
ID=65228014
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2018076383A Active JP7150460B2 (en) | 2017-06-30 | 2018-04-11 | Image processing device and image processing method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP7150460B2 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022259296A1 (en) * | 2021-06-07 | 2022-12-15 | 三菱電機株式会社 | Image generation system and image processing method |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012129814A (en) * | 2010-12-15 | 2012-07-05 | Sanyo Electric Co Ltd | Image processor |
JP2015220706A (en) * | 2014-05-21 | 2015-12-07 | 三菱電機株式会社 | Imaging apparatus |
JP2016167739A (en) * | 2015-03-10 | 2016-09-15 | 株式会社リコー | Image processing system, image processing method, and program |
-
2018
- 2018-04-11 JP JP2018076383A patent/JP7150460B2/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012129814A (en) * | 2010-12-15 | 2012-07-05 | Sanyo Electric Co Ltd | Image processor |
JP2015220706A (en) * | 2014-05-21 | 2015-12-07 | 三菱電機株式会社 | Imaging apparatus |
JP2016167739A (en) * | 2015-03-10 | 2016-09-15 | 株式会社リコー | Image processing system, image processing method, and program |
Non-Patent Citations (1)
Title |
---|
中澤正和. 外1名: ""全天球ボールカメラによる撮影動画の視点固定手法の提案"", 第24回インタラクティブシステムとソフトウェアに関するワークショップ, JPN6022011780, 16 December 2016 (2016-12-16), JP, ISSN: 0004736579 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022259296A1 (en) * | 2021-06-07 | 2022-12-15 | 三菱電機株式会社 | Image generation system and image processing method |
Also Published As
Publication number | Publication date |
---|---|
JP7150460B2 (en) | 2022-10-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101885778B1 (en) | Image stitching for three-dimensional video | |
AU2017246470B2 (en) | Generating intermediate views using optical flow | |
US11748906B2 (en) | Gaze point calculation method, apparatus and device | |
JP6672315B2 (en) | Image generation device and image display control device | |
TW200825984A (en) | Modeling and texturing digital surface models in a mapping application | |
US10664947B2 (en) | Image processing apparatus and image processing method to represent part of spherical image in planar image using equidistant cylindrical projection | |
JP2010109783A (en) | Electronic camera | |
US11272153B2 (en) | Information processing apparatus, method for controlling the same, and recording medium | |
WO2022242395A1 (en) | Image processing method and apparatus, electronic device and computer-readable storage medium | |
CN110945868B (en) | Apparatus and method for generating a tiled three-dimensional image representation of a scene | |
CN110998671B (en) | Three-dimensional reconstruction method, device, system and storage medium | |
WO2020151268A1 (en) | Generation method for 3d asteroid dynamic map and portable terminal | |
JP6708444B2 (en) | Image processing apparatus and image processing method | |
CN107862652B (en) | Aerial view generation method and device | |
WO2020262392A1 (en) | Information processing device, information processing method, and program | |
JP7150460B2 (en) | Image processing device and image processing method | |
KR20210115281A (en) | Apparatus and Method for Selecting Camera Providing Input Images to Synthesize Virtual View Images | |
JP6685814B2 (en) | Imaging device and control method thereof | |
JP3660108B2 (en) | Image storage method and machine-readable medium | |
WO2018150086A2 (en) | Methods and apparatuses for determining positions of multi-directional image capture apparatuses | |
JP2005063012A (en) | Full azimuth camera motion and method and device for restoring three-dimensional information and program and recording medium with the same recorded | |
EP3591609B1 (en) | Horizontal calibration method and system for panoramic image or video, and portable terminal | |
JP5001400B2 (en) | Shield removal display device | |
JP2020088571A (en) | Management system, information processing system, information processing method and program | |
JP2020160756A (en) | Image generation device, image generation method, and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20210409 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20210409 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20220314 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20220329 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20220527 |
|
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: 20220830 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20220928 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 7150460 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |