JP6665917B2 - Image processing device - Google Patents

Image processing device Download PDF

Info

Publication number
JP6665917B2
JP6665917B2 JP2018218280A JP2018218280A JP6665917B2 JP 6665917 B2 JP6665917 B2 JP 6665917B2 JP 2018218280 A JP2018218280 A JP 2018218280A JP 2018218280 A JP2018218280 A JP 2018218280A JP 6665917 B2 JP6665917 B2 JP 6665917B2
Authority
JP
Japan
Prior art keywords
image
template
images
target
unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2018218280A
Other languages
Japanese (ja)
Other versions
JP2019053758A (en
Inventor
竹中 博一
博一 竹中
吉田 和弘
和弘 吉田
啓一 河口
啓一 河口
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ricoh Co Ltd
Original Assignee
Ricoh Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP2018218280A priority Critical patent/JP6665917B2/en
Publication of JP2019053758A publication Critical patent/JP2019053758A/en
Application granted granted Critical
Publication of JP6665917B2 publication Critical patent/JP6665917B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Description

本発明は、画像処理装置に関し、より詳細には、複数の入力画像をつなぎ合わせるための画像処理装置に関する。   The present invention relates to an image processing apparatus, and more particularly, to an image processing apparatus for joining a plurality of input images.

魚眼レンズや超広角レンズなどの広角なレンズを複数使用して全方位(以下、全天球という。)を一度に撮像する全天球撮像システムが知られている。上記全天球撮像システムでは、各々のレンズからの像をセンサ面に投影し、得られる各画像を画像処理によって結合することで、全天球画像を生成する。例えば、180度を超える画角を有する2つの広角なレンズを用いて、全天球画像を生成することができる。   2. Description of the Related Art An omnidirectional imaging system that uses a plurality of wide-angle lenses such as a fish-eye lens and an ultra-wide-angle lens to capture images in all directions (hereinafter, omnidirectional) at once is known. In the omnidirectional imaging system, an omnidirectional image is generated by projecting an image from each lens onto a sensor surface and combining the obtained images by image processing. For example, a spherical image can be generated using two wide-angle lenses having an angle of view exceeding 180 degrees.

上記画像処理では、各レンズ光学系により撮影された部分画像に対して、所定の射影モデルに基づいて、また理想的なモデルからの歪みを考慮して、歪み補正および射影変換を施す。そして、部分画像に含まれる重複部分を用いて部分画像をつなぎ合わせ、1枚の全天球画像とする処理が行われる。画像をつなぎ合わせる処理においては、部分画像間の重複部分において、パターンマッチングなどを用いて被写体が重なるつなぎ位置が検出される。   In the above-described image processing, distortion correction and projection transformation are performed on a partial image captured by each lens optical system based on a predetermined projection model and in consideration of distortion from an ideal model. Then, the partial images are connected using the overlapping portion included in the partial images, and a process of forming one omnidirectional image is performed. In the process of joining images, in an overlapping portion between partial images, a joining position at which a subject overlaps is detected using pattern matching or the like.

しかしながら、従来技術のパターンマッチングによるつなぎ位置検出技術では、マッチングを行う対象領域が、その画像が平坦であったり、同じ模様が繰り返された領域であったりして特徴が少ない場合に、適切なつなぎ位置を検出することが難しかった。このため、部分画像を良好につなぎ合わせることができず、得られる全天球画像の品質が低下してしまう可能性があった。   However, in the splicing position detection technology based on the conventional pattern matching, an appropriate splicing is performed when the target area to be matched is a flat image or an area where the same pattern is repeated and has few features. It was difficult to detect the position. For this reason, the partial images cannot be satisfactorily stitched, and the quality of the obtained omnidirectional image may be reduced.

複数のカメラを用いて撮像された複数の部分画像をつなぎ合わせる種々の技術が知られている。例えば、特開2001−148779号公報(特許文献1)は、パターンマッチングを行う際に、不適切なマッチング領域が使用されることに起因するパターンマッチングの誤りを回避し、高精度に画像の合成を行うことを目的とした画像処理装置を開示する。特許文献1の従来技術では、マッチング領域抽出部によって抽出されたマッチング領域に対し、そのマッチング領域が適切か否かの判定を行い、不適切なマッチング領域については再度抽出をやり直すよう構成されている。また、パターンマッチング部によるマッチング結果についても、その適否を判定し、マッチング結果が適切でなければ、マッチング領域の抽出をやり直すよう構成されている。   Various techniques for joining a plurality of partial images captured using a plurality of cameras are known. For example, Japanese Patent Application Laid-Open No. 2001-148779 (Patent Literature 1) discloses that when performing pattern matching, it is possible to avoid an error in pattern matching caused by the use of an inappropriate matching area, and to synthesize images with high accuracy. An image processing apparatus for performing the above is disclosed. In the related art of Patent Literature 1, it is configured to determine whether or not the matching region extracted by the matching region extracting unit is appropriate, and to re-extract the inappropriate matching region. . In addition, the matching result of the pattern matching unit is also determined to be appropriate, and if the matching result is not appropriate, the matching area is extracted again.

上記特許文献1の従来技術は、マッチング領域として相応しくない領域、例えば、全面白画素や黒画素の領域や、縦方向、横方向、斜め方向に連続する直線が存在する領域を事前に除去してパターンマッチングを行うことにより、画像の合成の精度を向上させている。   The prior art disclosed in Patent Document 1 removes in advance areas that are not suitable as matching areas, such as areas of white pixels and black pixels on the entire surface, and areas in which straight lines extending in the vertical, horizontal, and oblique directions exist. By performing pattern matching, the accuracy of image synthesis is improved.

しかしながら、上記特許文献1の従来技術は、マッチング領域が不適切な場合にはマッチング領域を再抽出するという技術である。このため、不適切と判断したマッチング領域に対する適切なつなぎ位置を決定することは依然として難しかった。   However, the conventional technique of Patent Document 1 is a technique of re-extracting a matching area when the matching area is inappropriate. For this reason, it was still difficult to determine an appropriate connection position for a matching area determined to be inappropriate.

本発明は、上記従来技術の不充分な点に鑑みてなされたものであり、本発明は、入力画像の特徴が少ない部分領域に対しても適切なつなぎ位置で複数の入力画像を合成することが可能な画像処理装置を提供することを目的とする。   The present invention has been made in view of the above-described inadequacy of the related art, and the present invention has been made to combine a plurality of input images at an appropriate joint position even in a partial region having a small feature of the input image. It is an object of the present invention to provide an image processing apparatus capable of performing the following.

本発明では、上記課題を解決するために、下記特徴を有した、複数の入力画像を合成する画像処理装置を提供する。本画像処理装置は、第1の入力画像における複数の対象画像の特徴量を取得する特徴量取得手段と、複数の対象画像のうち注目する注目対象画像よりも特徴量が大きな他の対象画像の第2の入力画像に対するつなぎ位置を使って検出されたつなぎ位置に基づいて第1の入力画像と、第2の入力画像とを合成する合成手段とを備えたことを特徴とする。   The present invention provides an image processing apparatus for synthesizing a plurality of input images, having the following features, in order to solve the above-mentioned problems. The image processing apparatus includes: a feature amount obtaining unit configured to obtain a feature amount of a plurality of target images in the first input image; The image processing apparatus further includes a combining unit that combines the first input image and the second input image based on the connection position detected using the connection position with respect to the second input image.

上記構成によれば、入力画像の特徴が少ない部分領域に対しても適切なつなぎ位置で複数の入力画像を合成することが可能となる。   According to the above configuration, it is possible to combine a plurality of input images at an appropriate connection position even in a partial region having few features of the input image.

本実施形態による全天球撮像システムを示す断面図。FIG. 1 is a cross-sectional view showing a spherical imaging system according to the embodiment. 本実施形態による全天球撮像システムのハードウェア構成図。FIG. 2 is a hardware configuration diagram of the celestial sphere imaging system according to the embodiment. 本実施形態による全天球撮像システムにおける画像処理全体の流れを示す図。FIG. 2 is a diagram showing a flow of entire image processing in the celestial sphere imaging system according to the embodiment. 本実施形態による全天球撮像システム上に実現される全天球画像合成処理の主要な機能ブロック図。FIG. 3 is a main functional block diagram of a omnidirectional image combining process realized on the omnidirectional imaging system according to the embodiment. 本実施形態による全天球撮像システムが実行する、全天球画像合成処理の全体的な流れを示すフローチャート。6 is a flowchart illustrating an overall flow of a celestial sphere image synthesis process executed by the celestial sphere imaging system according to the embodiment. 魚眼レンズを用いた全天球撮像システムにおける射影関係を説明する図。FIG. 3 is a diagram illustrating a projection relationship in a celestial sphere imaging system using a fisheye lens. 本実施形態で用いられる全天球画像フォーマットの画像データのデータ構造を説明する図。FIG. 2 is a diagram illustrating a data structure of image data in a spherical image format used in the embodiment. 位置検出用歪み補正部および画像合成用歪み補正部が参照する変換データを説明する図。FIG. 7 is a diagram illustrating conversion data referred to by a position detection distortion correction unit and an image synthesis distortion correction unit. 位置検出処理の際における2つの魚眼レンズで撮像された2つの部分画像の球面座標系へのマッピングを説明する図。FIG. 7 is a diagram for explaining mapping of two partial images captured by two fisheye lenses to a spherical coordinate system in a position detection process. 本実施形態によるつなぎ位置検出部の機能ブロック図。FIG. 3 is a functional block diagram of a connection position detection unit according to the embodiment. 特定の実施形態によるテンプレート特徴量算出部のブロック図。FIG. 4 is a block diagram of a template feature amount calculation unit according to a specific embodiment. 本実施形態による全天球撮像システムが実行する、つなぎ位置検出処理を示すフローチャート。5 is a flowchart illustrating a connection position detection process executed by the celestial sphere imaging system according to the embodiment. 本実施形態によるテンプレート生成部によるテンプレート画像の生成方法を説明する図。FIG. 4 is a diagram illustrating a method for generating a template image by a template generation unit according to the embodiment. (A)本実施形態によるテンプレート画像の順位付け、および(B,C)本実施形態による仮位置算出部が行う順位付けに基づくテンプレート画像の仮位置の算出方法を説明する図。6A and 6B are diagrams illustrating a method of calculating a temporary position of a template image based on the ranking performed by the temporary position calculation unit according to the embodiment. 本実施形態による探索範囲設定部が行う探索範囲の設定方法を説明する図。FIG. 4 is a diagram illustrating a search range setting method performed by a search range setting unit according to the embodiment. (A)テンプレート画像と、(B)パターンマッチングにより探索範囲でテンプレート画像を探索する処理を説明する図。FIG. 9A is a diagram illustrating a template image, and FIG. 9B is a diagram illustrating a process of searching for a template image in a search range by pattern matching. (A)オフセット関数のグラフ、並びに(B,C)補正前のスコアおよび補正後のスコアを探索位置でプロットしたグラフを補正前のスコアに基づくマッチング位置および補正後のスコアに基づくマッチング位置とともに示す図。(A) A graph of the offset function, and (B, C) a graph in which the score before correction and the score after correction are plotted at the search position are shown together with the matching position based on the score before correction and the matching position based on the score after correction. FIG. 本実施形態において、つなぎ位置検出部により生成される検出結果データのデータ構造を示す図。FIG. 4 is a diagram illustrating a data structure of detection result data generated by a connection position detection unit in the embodiment. 本実施形態のつなぎ位置検出部による検出結果データを生成する処理を説明する図。FIG. 4 is a diagram for describing processing for generating detection result data by a connection position detection unit according to the embodiment. 本実施形態による全天球撮像システムが実行する、画像合成用変換テーブルの生成処理を示すフローチャート。9 is a flowchart illustrating a process of generating an image synthesis conversion table, which is performed by the omnidirectional imaging system according to the embodiment. 画像合成処理の際における2つの魚眼レンズで撮像された2つの部分画像の球面座標系へのマッピングを説明する図。FIG. 8 is a diagram illustrating mapping of two partial images captured by two fisheye lenses to a spherical coordinate system during image synthesis processing. 他の実施形態における全天球撮像システムの概略図。The schematic diagram of the celestial sphere imaging system in other embodiments. 他の実施形態における全天球撮像システムにおける全天球画像合成処理の全体的な流れを示すフローチャート図。FIG. 11 is a flowchart showing an overall flow of a celestial sphere image synthesis process in a celestial sphere imaging system according to another embodiment.

以下、本発明の実施形態について説明するが、本発明の実施形態は、以下に説明する実施形態に限定されるものではない。なお、以下の実施形態では、画像処理装置および撮像システムの一例として、2つの魚眼レンズを光学系に含む撮像体を備えるとともに、2つの魚眼レンズで自身が撮像した2つの部分画像に対し歪曲補正および射影変換を行い、画像つなぎ合わせを行って、全天球画像を生成する画像処理機能を備えた、全天球撮像システム10を用いて説明する。   Hereinafter, embodiments of the present invention will be described, but embodiments of the present invention are not limited to the embodiments described below. In the following embodiments, as an example of an image processing apparatus and an imaging system, an image pickup body including two fish-eye lenses in an optical system is provided, and distortion correction and projection are performed on two partial images captured by the two fish-eye lenses. A description will be given using an omnidirectional imaging system 10 having an image processing function of performing conversion, connecting images, and generating an omnidirectional image.

[全体構成]
以下、図1〜図3を参照しながら、本実施形態による全天球撮像システムの全体構成について説明する。図1は、本実施形態による全天球撮像システム(以下、単に、撮像システムと参照する。)10を示す断面図である。図1に示す撮像システム10は、撮像体12と、上記撮像体12およびコントローラやバッテリなどの部品を保持する筐体14と、上記筐体14に設けられたシャッター・ボタン18とを備える。図1に示す撮像体12は、2つの結像光学系20A,20Bと、CCD(Charge Coupled Device)センサやCMOS(Complementary Metal Oxide Semiconductor)センサなどの2つの固体撮像素子22A,22Bとを含む。結像光学系20と固体撮像素子22とを1個ずつ組み合わせたものを撮像光学系と参照する。結像光学系20各々は、例えば6群7枚の魚眼レンズとして構成することができる。上記魚眼レンズは、図1に示す実施形態では、180度(=360度/n;n=2)より大きい全画角を有し、好適には、185度以上の画角を有し、より好適には、190度以上の画角を有する。
[overall structure]
Hereinafter, the overall configuration of the omnidirectional imaging system according to the present embodiment will be described with reference to FIGS. FIG. 1 is a cross-sectional view showing a spherical imaging system (hereinafter, simply referred to as an imaging system) 10 according to the present embodiment. An imaging system 10 shown in FIG. 1 includes an imaging body 12, a housing 14 that holds the imaging body 12, components such as a controller and a battery, and a shutter button 18 provided on the housing 14. The imaging body 12 shown in FIG. 1 includes two imaging optical systems 20A and 20B, and two solid-state imaging devices 22A and 22B such as a charge coupled device (CCD) sensor and a complementary metal oxide semiconductor (CMOS) sensor. A combination of the imaging optical system 20 and the solid-state imaging device 22 one by one is referred to as an imaging optical system. Each of the imaging optical systems 20 can be configured as, for example, seven groups of seven fish-eye lenses. In the embodiment shown in FIG. 1, the fisheye lens has a total angle of view larger than 180 degrees (= 360 degrees / n; n = 2), preferably has an angle of view of 185 degrees or more, and is more preferably. Has an angle of view of 190 degrees or more.

2つの結像光学系20A,20Bの光学素子(レンズ、プリズム、フィルタおよび開口絞り)は、固体撮像素子22A,22Bに対して位置関係が定められる。位置決めは、結像光学系20A,20Bの光学素子の光軸が、対応する固体撮像素子22の受光領域の中心部に直交して位置するように、かつ、受光領域が、対応する魚眼レンズの結像面となるように行われる。固体撮像素子22各々は、受光領域が面積エリアを成す2次元の固体撮像素子であり、組み合わせられる結像光学系20により集光された光を画像信号に変換する。   The optical elements (lens, prism, filter, and aperture stop) of the two imaging optical systems 20A and 20B have a positional relationship with respect to the solid-state imaging elements 22A and 22B. The positioning is performed so that the optical axes of the optical elements of the imaging optical systems 20A and 20B are orthogonal to the center of the light receiving area of the corresponding solid-state imaging device 22, and the light receiving area is formed by the corresponding fisheye lens. This is performed so as to be on the image plane. Each of the solid-state imaging devices 22 is a two-dimensional solid-state imaging device in which a light receiving region forms an area, and converts light collected by the imaging optical system 20 to be combined into an image signal.

図1に示す実施形態では、結像光学系20A,20Bは、同一仕様のものであり、それぞれの光軸が合致するようにして、互いに逆向きに組み合わせられる。固体撮像素子22A,22Bは、受光した光分布を画像信号に変換して、図示しないコントローラ上の画像処理手段に出力する。画像処理手段では、詳細は後述するが、固体撮像素子22A,22Bからそれぞれ入力される部分画像をつなぎ合わせて合成し、立体角4πラジアンの画像(以下「全天球画像」と参照する。)を生成する。全天球画像は、撮影地点から見渡すことのできる全ての方向を撮影したものとなる。ここで、図1に示す実施形態では、全天球画像を生成しているが、水平面のみ360度を撮影した、いわゆるパノラマ画像であってもよい。   In the embodiment shown in FIG. 1, the imaging optical systems 20A and 20B are of the same specification, and are combined in opposite directions so that their optical axes match. The solid-state imaging devices 22A and 22B convert the received light distribution into an image signal and output the image signal to an image processing unit on a controller (not shown). Although the image processing means will be described in detail later, the partial images input from the solid-state imaging devices 22A and 22B are connected and combined to form an image having a solid angle of 4π radians (hereinafter, referred to as an “omnidirectional image”). Generate The celestial sphere image is obtained by shooting in all directions that can be seen from the shooting location. Here, in the embodiment shown in FIG. 1, a spherical image is generated, but a so-called panoramic image obtained by photographing only the horizontal plane at 360 degrees may be used.

また、ここで、固体撮像素子22A,22Bの走査方向を、互いに一致させることで、各々の撮像画像をつなぎ合わせやすくすることができる。つまり、それぞれの固体撮像素子22の走査方向と順序を、互いにつなぎ合わせる部分で一致させることで、互いのカメラの境界にある物体、特に、移動物体のつなぎ合わせに効果が得られる。例えば、固体撮像素子22Aで撮影された撮像画像の左上の部分と、固体撮像素子22Bで撮影された撮像画像の左下の部分が、画像のつなぎ合わせる部分として一致する場合は、固体撮像素子22Aの走査は、固体撮像素子の上から下に向かって、右から左に走査する。一方、固体撮像素子22Bの走査は、固体撮像素子の下から上に向かって、右から左に走査する。このように、画像のつなぎ合わせる部分に基づいて、各固体撮像素子の走査方向を一致させるように制御することで、つなぎ合わせ易いという効果が得られる。   Here, by making the scanning directions of the solid-state imaging devices 22A and 22B coincide with each other, it is possible to easily join the captured images. In other words, by making the scanning directions and the order of the solid-state imaging devices 22 coincide with each other at the portions where they are connected to each other, an effect can be obtained for connecting objects at the boundary between the cameras, particularly moving objects. For example, when the upper left portion of the image captured by the solid-state imaging device 22A and the lower left portion of the image captured by the solid-state imaging device 22B match as a portion to be joined, the solid-state imaging device 22A The scanning is performed from right to left from top to bottom of the solid-state imaging device. On the other hand, the solid-state imaging device 22B scans from right to left from bottom to top of the solid-state imaging device. As described above, by controlling the scanning directions of the respective solid-state imaging devices to coincide based on the portion to be joined of the images, an effect that joining is easy can be obtained.

上述したように、魚眼レンズが180度を超える全画角を有するため、全天球画像を構成する際には、各撮像光学系による撮影画像において、重複する画像部分が、同一像を表す基準データとして画像つなぎ合わせの参考とされる。生成された全天球画像は、例えば、撮像体12に備えられる、または撮像体12に接続されているディスプレイ装置、印刷装置、SD(登録商標)カードやコンパクトフラッシュ(登録商標)などの外部記憶媒体などに出力される。   As described above, since the fisheye lens has a full angle of view exceeding 180 degrees, when composing a celestial sphere image, in an image captured by each imaging optical system, an overlapping image portion is a reference data representing the same image. It is used as a reference for image stitching. The generated celestial sphere image is stored in an external storage such as a display device, a printing device, an SD (registered trademark) card, or a compact flash (registered trademark) provided in or connected to the imaging body 12. Output to a medium or the like.

図2は、本実施形態による撮像システム10のハードウェア構成を示す。撮像システム10は、デジタル・スチルカメラ・プロセッサ(以下、単にプロセッサと参照する。)100と、鏡胴ユニット102と、プロセッサ100に接続される種々のコンポーネントから構成される。鏡胴ユニット102は、上述した2組のレンズ光学系20A,20Bと、固体撮像素子22A,22Bとを有する。固体撮像素子22は、プロセッサ100内の後述するCPU130からの制御指令により制御される。   FIG. 2 shows a hardware configuration of the imaging system 10 according to the present embodiment. The imaging system 10 includes a digital still camera processor (hereinafter, simply referred to as a processor) 100, a lens barrel unit 102, and various components connected to the processor 100. The lens barrel unit 102 has the above-described two sets of lens optical systems 20A and 20B, and the solid-state imaging devices 22A and 22B. The solid-state imaging device 22 is controlled by a control command from a CPU 130 described later in the processor 100.

プロセッサ100は、ISP(Image Signal Processor)108と、DMAC(Direct Memory Access Controller)110と、メモリアクセスの調停のためのアービタ(ARBMEMC)112と、メモリアクセスを制御するMEMC(Memory Controller)114と、歪曲補正・画像合成ブロック118とを含む。ISP108A,108Bは、それぞれ、固体撮像素子22A,22Bの信号処理を経て入力された画像データに対し、ホワイト・バランス設定やガンマ設定を行う。MEMC114には、SDRAM116が接続される。SDRAM116には、ISP108A,180Bおよび歪曲補正・画像合成ブロック118において処理を施す際にデータが一時的に保存される。歪曲補正・画像合成ブロック118は、2つの撮像光学系から得られた2つの部分画像に対し、3軸加速度センサ120からの情報を利用して、歪曲補正とともに天地補正を施し、画像合成する。   The processor 100 includes an ISP (Image Signal Processor) 108, a DMAC (Direct Memory Access Controller) 110, an arbiter (ARBMEMC) 112 for arbitrating memory access, an MEMC (Memory Controller) 114 for controlling memory access, And a distortion correction / image synthesis block 118. The ISPs 108A and 108B perform white balance setting and gamma setting on image data input through signal processing of the solid-state imaging devices 22A and 22B, respectively. The SDRAM 116 is connected to the MEMC 114. The SDRAM 116 temporarily stores data when the ISPs 108A and 180B and the distortion correction / image synthesis block 118 perform processing. The distortion correction / image synthesis block 118 performs distortion correction and top / bottom correction on two partial images obtained from the two imaging optical systems using information from the three-axis acceleration sensor 120, and synthesizes images.

プロセッサ100は、さらに、DMAC122と、画像処理ブロック124と、CPU130と、画像データ転送部126と、SDRAMC128と、メモリカード制御ブロック140と、USBブロック146と、ペリフェラル・ブロック150と、音声ユニット152と、シリアルブロック158と、LCD(Liquid Crystal Display)ドライバ162と、ブリッジ168とを含む。   The processor 100 further includes a DMAC 122, an image processing block 124, a CPU 130, an image data transfer unit 126, an SDRAM 128, a memory card control block 140, a USB block 146, a peripheral block 150, and an audio unit 152. , A serial block 158, an LCD (Liquid Crystal Display) driver 162, and a bridge 168.

CPU130は、当該撮像システム10の各部の動作を制御する。画像処理ブロック124は、リサイズブロック132、JPEGブロック134、H.264ブロック136などを用いて、画像データに対し各種画像処理を施す。リサイズブロック132は、画像データのサイズを補間処理により拡大または縮小するためのブロックである。JPEGブロック134は、JPEG圧縮および伸張を行うコーデック・ブロックである。H.264ブロック136は、H.264などの動画圧縮および伸張を行うコーデック・ブロックである。画像データ転送部126は、画像処理ブロック124で画像処理された画像を転送する。SDRAMC128は、プロセッサ100に接続されるSDRAM138制御し、SDRAM138には、プロセッサ100内で画像データに各種処理を施す際に、画像データを一時的に保存する。   The CPU 130 controls the operation of each unit of the imaging system 10. The image processing block 124 includes a resize block 132, a JPEG block 134, Various image processing is performed on the image data using the H.264 block 136 and the like. The resize block 132 is a block for enlarging or reducing the size of image data by interpolation processing. The JPEG block 134 is a codec block that performs JPEG compression and decompression. H. The H.264 block 136 is a H.264 block. This is a codec block for compressing and expanding moving images such as H.264. The image data transfer unit 126 transfers the image processed by the image processing block 124. The SDRAM 128 controls the SDRAM 138 connected to the processor 100, and temporarily stores the image data when performing various processes on the image data in the processor 100.

メモリカード制御ブロック140は、メモリカードスロット142に挿入されたメモリカードおよびフラッシュROM144に対する読み書きを制御する。メモリカードスロット142は、撮像システム10にメモリカードを着脱可能に装着するためのスロットである。USBブロック146は、USBコネクタ148を介して接続されるパーソナル・コンピュータなどの外部機器とのUSB通信を制御する。ペリフェラル・ブロック150には、電源スイッチ166が接続される。音声ユニット152は、ユーザが音声信号を入力するマイク156と、記録された音声信号を出力するスピーカ154とに接続され、音声入出力を制御する。シリアルブロック158は、パーソナル・コンピュータなどの外部機器とのシリアル通信を制御し、無線NIC(Network Interface Card)160が接続される。LCDドライバ162は、LCDモニタ164を駆動するドライブ回路であり、LCDモニタ164に各種状態を表示するための信号に変換する。   The memory card control block 140 controls reading from and writing to the memory card inserted into the memory card slot 142 and the flash ROM 144. The memory card slot 142 is a slot for detachably mounting a memory card on the imaging system 10. The USB block 146 controls USB communication with an external device such as a personal computer connected via the USB connector 148. A power switch 166 is connected to the peripheral block 150. The audio unit 152 is connected to a microphone 156 to which the user inputs an audio signal and a speaker 154 to output a recorded audio signal, and controls audio input / output. The serial block 158 controls serial communication with an external device such as a personal computer, and is connected to a wireless NIC (Network Interface Card) 160. The LCD driver 162 is a drive circuit for driving the LCD monitor 164, and converts the signal into a signal for displaying various states on the LCD monitor 164.

フラッシュROM144には、CPU130が解読可能なコードで記述された制御プログラムや各種パラメータが格納される。電源スイッチ166の操作によって電源がオン状態になると、上記制御プログラムがメインメモリにロードされる。CPU130は、メインメモリに読み込まれたプログラムに従って、装置各部の動作を制御するとともに、制御に必要なデータをSDRAM138と、図示しないローカルSRAMとに一時的に保存する。   The flash ROM 144 stores a control program and various parameters described in codes readable by the CPU 130. When the power is turned on by operating the power switch 166, the control program is loaded into the main memory. The CPU 130 controls the operation of each unit of the apparatus according to the program read into the main memory, and temporarily stores data necessary for the control in the SDRAM 138 and a local SRAM (not shown).

図3は、本実施形態による撮像システム10における画像処理全体の流れを示す図である。まず、ステップS101A,101Bでは、固体撮像素子22A,22B各々によって、画像が撮像される。ステップS102A,102Bでは、固体撮像素子22A,22B各々から出力されたベイヤーRAWの画像に対し、図2に示したISP108により、オプティカル・ブラック補正処理、欠陥画素補正処理、リニア補正処理、シェーディング処理および領域分割平均処理が行われる。ステップS103A,103Bでは、メモリに保存される。ステップS104A,104Bでは、図2に示したISP108により、さらに、ホワイト・バランス処理、ガンマ補正処理、ベイヤー補間処理、YUV変換処理、エッジ強調処理および色補正処理が行われ、ステップS105A,105Bで、メモリに保存される。   FIG. 3 is a diagram illustrating a flow of the entire image processing in the imaging system 10 according to the present embodiment. First, in steps S101A and 101B, an image is captured by each of the solid-state imaging devices 22A and 22B. In steps S102A and 102B, the ISP 108 shown in FIG. 2 performs an optical black correction process, a defective pixel correction process, a linear correction process, a shading process, and the like on the Bayer RAW image output from each of the solid-state imaging devices 22A and 22B. An area division averaging process is performed. In steps S103A and 103B, the data is stored in the memory. In steps S104A and 104B, the ISP 108 shown in FIG. 2 further performs white balance processing, gamma correction processing, Bayer interpolation processing, YUV conversion processing, edge enhancement processing, and color correction processing. In steps S105A and 105B, Stored in memory.

2つの固体撮像素子22A,22B各々について上述した処理が完了すると、ステップS106では、上記処理が施された各部分画像に対し、歪曲補正および合成処理が行われる。ステップS107では、適宜タグ付けされて、全天球画像が内蔵メモリまたは外部ストレージにファイル保存される。また、上記歪曲補正および合成処理の過程では、適宜、3軸加速度センサ120からの情報を得て傾き天地補正が行われてもよい。また、保存される画像ファイルには、適宜圧縮処理が施されても良い。   When the above-described processing is completed for each of the two solid-state imaging devices 22A and 22B, in step S106, distortion correction and synthesis processing are performed on each of the partial images subjected to the above processing. In step S107, the celestial sphere image is appropriately filed and saved as a file in the internal memory or the external storage. Further, in the process of the distortion correction and the synthesis processing, the tilt and the vertical correction may be performed by appropriately obtaining information from the three-axis acceleration sensor 120. Further, the image file to be stored may be subjected to an appropriate compression process.

[全天球画像合成機能]
以下、図4〜図21を参照しながら、本実施形態による撮像システム10が備える全天球画像合成機能について詳細を説明する。図4は、本実施形態による撮像システム10上に実現される全天球画像合成処理の主要な機能ブロック200を示す。歪曲補正・画像合成ブロック118は、図4に示すように、位置検出用歪み補正部202と、つなぎ位置検出部204と、テーブル修正部206と、テーブル生成部208と、画像合成用歪み補正部210と、画像合成部212とを含み構成される。
[Spherical image composition function]
Hereinafter, the omnidirectional image combining function of the imaging system 10 according to the present embodiment will be described in detail with reference to FIGS. FIG. 4 shows main functional blocks 200 of the spherical image synthesis processing realized on the imaging system 10 according to the present embodiment. As shown in FIG. 4, the distortion correction / image synthesis block 118 includes a position detection distortion correction unit 202, a joint position detection unit 204, a table correction unit 206, a table generation unit 208, and an image synthesis distortion correction unit. 210 and an image synthesizing unit 212.

また、歪曲補正・画像合成ブロック118には、2つの固体撮像素子22A,22Bから、ISP108A,108Bによる各画像信号処理を経て、2つの部分画像が入力される。ここで、固体撮像素子22A,22Bに対し「0」および「1」の番号を付して参照し、固体撮像素子22Aをソースとする画像を「部分画像0」のように参照し、固体撮像素子22Bをソースとする画像を「部分画像1」のように参照する。さらに、歪曲補正・画像合成ブロック118には、それぞれのレンズ光学系の設計データ等に基づいて、所定の投影モデルに従い製造元等で予め作成された、位置検出用変換テーブル220が提供される。   In addition, two partial images are input to the distortion correction / image synthesis block 118 from the two solid-state imaging devices 22A and 22B through image signal processing by the ISPs 108A and 108B. Here, reference is made to the solid-state imaging devices 22A and 22B by attaching numbers “0” and “1”, and an image using the solid-state imaging device 22A as a source is referred to as “partial image 0”. An image using the element 22B as a source is referred to as “partial image 1”. Further, the distortion correction / image synthesis block 118 is provided with a position detection conversion table 220 created in advance by a manufacturer or the like according to a predetermined projection model based on design data of each lens optical system.

位置検出用歪み補正部202は、つなぎ位置検出処理の前段の処理として、入力される部分画像0および部分画像1に対し、位置検出用変換テーブル220を用いて歪み補正を施し、位置検出用補正画像(以下、単に補正画像と参照する場合がある。)0および位置検出用補正画像1を生成する。入力される部分画像0,1は、受光領域が面積エリアを成す2次元の固体撮像素子で撮像されたものであり、平面座標系(x,y)で表現された画像データとなる。これに対し、位置検出用変換テーブル220を用いて歪み補正がかけられた補正画像は、入力画像とは異なる座標系の画像データであり、より具体的には、球面座標系(動径を1とし、2つの偏角θ,φを有する極座標系である。)で表現された全天球画像フォーマットの画像データとなる。   The position detection distortion correction unit 202 performs distortion correction on the input partial image 0 and partial image 1 using the position detection conversion table 220 as a process preceding the connection position detection process. An image (hereinafter, simply referred to as a corrected image) 0 and a corrected image for position detection 1 are generated. The input partial images 0 and 1 are images captured by a two-dimensional solid-state image sensor whose light receiving region forms an area, and are image data expressed in a plane coordinate system (x, y). On the other hand, the corrected image subjected to distortion correction using the position detection conversion table 220 is image data in a coordinate system different from that of the input image. And a polar coordinate system having two declination angles θ and φ).

図6は、魚眼レンズを用いた撮像システムにおける射影関係を説明する図である。本実施形態において、1つ魚眼レンズで撮影された画像は、撮影地点から概ね半球分の方位を撮影したものとなる。また、魚眼レンズは、図6に示すように、光軸に対する入射角度φに対応した像高hで画像生成される。像高hと、入射角度φとの関係は、所定の投影モデルに応じた射影関数で決定される。射影関数は、魚眼レンズの性質によって異なるが、等距離射影方式と呼ばれる投影モデルの魚眼レンズでは、fを焦点距離として、下記式(1)で表現される。   FIG. 6 is a diagram illustrating a projection relationship in an imaging system using a fisheye lens. In the present embodiment, an image captured by one fish-eye lens is obtained by capturing a direction substantially equivalent to a hemisphere from a capturing point. As shown in FIG. 6, the fisheye lens generates an image at an image height h corresponding to the incident angle φ with respect to the optical axis. The relationship between the image height h and the incident angle φ is determined by a projection function according to a predetermined projection model. The projection function varies depending on the characteristics of the fisheye lens. However, in a fisheye lens of a projection model called an equidistant projection method, f is a focal length and is expressed by the following equation (1).

上記投影モデルとしては、その他、中心投影方式(h=f・tanφ)、立体射影方式(h=2f・tan(φ/2))、等立体角射影方式(h=2f・sin(φ/2))および正射影方式(h=f・sinφ)を挙げることができる。いずれの方式においても、光軸からの入射角度φと焦点距離fとに対応して結像の像高hが決定される。また、本実施形態では、画像対角線よりもイメージサークル径が小さな、いわゆる円周魚眼レンズの構成を採用するものとし、得られる部分画像は、図6(B)に示すように、撮影範囲の概ね半球分が投影されたイメージサークル全体を含む平面画像となる。   Other examples of the projection model include a center projection method (h = f · tan φ), a stereoscopic projection method (h = 2f · tan (φ / 2)), and an equal solid angle projection method (h = 2f · sin (φ / 2)). )) And the orthogonal projection method (h = f · sin φ). In either method, the image height h of the image is determined according to the incident angle φ from the optical axis and the focal length f. In the present embodiment, a configuration of a so-called circular fisheye lens having a smaller image circle diameter than the image diagonal line is adopted, and the obtained partial image is substantially hemispherical in the shooting range as shown in FIG. The plane image includes the entire projected image circle.

図7は、本実施形態で用いられる全天球画像フォーマットの画像データのデータ構造を説明する図である。図7に示すように、全天球画像フォーマットの画像データは、所定の軸に対するなす角度に対応する垂直角度φと、上記軸周りの回転角に対応する水平角度θとを座標とした画素値の配列として表現される。水平角度θは、0〜360度(−180度〜+180度とも表現できる。)の範囲となり、垂直角度φは、0〜180度(同様に−90度〜+90度とも表現できる。)の範囲となる。各座標値(θ,φ)は、撮影地点を中心とした全方位を表す球面上の各点と対応付けられており、全方位が全天球画像上にマッピングされる。魚眼レンズで撮影された画像の平面座標と、全天球画像フォーマットの球面上の座標との関係は、図6で説明したような射影関数を用いることによって対応付けることができる。   FIG. 7 is a diagram illustrating the data structure of image data in the spherical image format used in the present embodiment. As shown in FIG. 7, the image data in the spherical image format has pixel values with coordinates of a vertical angle φ corresponding to an angle with respect to a predetermined axis and a horizontal angle θ corresponding to a rotation angle around the axis. Is represented as an array of The horizontal angle θ ranges from 0 to 360 degrees (also expressed as −180 degrees to +180 degrees), and the vertical angle φ ranges from 0 to 180 degrees (also expressed as −90 degrees to +90 degrees). Becomes Each coordinate value (θ, φ) is associated with each point on the spherical surface that represents the omnidirectional centering on the imaging point, and the omnidirectional is mapped on the omnidirectional image. The relationship between the plane coordinates of the image captured by the fisheye lens and the coordinates on the spherical surface in the spherical image format can be associated by using the projection function described with reference to FIG.

図8は、位置検出用歪み補正部202および画像合成用歪み補正部210が参照する変換データを説明する図である。変換テーブル220,224は、平面座標系で表現される部分画像から、球面座標系で表現される画像への射影を規定する。変換テーブル220,224は、図8(A)および(B)に示すように、各魚眼レンズ毎に、補正後画像の座標値(θ,φ)と、該座標値(θ,φ)にマッピングされる補正前の部分画像の座標値(x、y)とを対応付ける情報を、全座標値(θ,φ)(θ=0,・・・360度,φ=0,・・・,180度)に対して保持する。図8の例示では、1画素が担当する角度は、φ方向およびθ方向いずれも1/10度であり、変換テーブル220,224は、各魚眼レンズについて、3600×1800の対応関係を示す情報を有することになる。   FIG. 8 is a diagram illustrating conversion data referred to by the position detection distortion correction unit 202 and the image synthesis distortion correction unit 210. The conversion tables 220 and 224 define the projection from a partial image expressed in a plane coordinate system to an image expressed in a spherical coordinate system. As shown in FIGS. 8A and 8B, the conversion tables 220 and 224 are mapped to the coordinate values (θ, φ) of the corrected image and the coordinate values (θ, φ) for each fisheye lens. The information for associating the coordinate values (x, y) of the partial image before correction with all coordinate values (θ, φ) (θ = 0,... 360 degrees, φ = 0,. Hold against. In the example of FIG. 8, the angle assigned to one pixel is 1/10 degrees in both the φ direction and the θ direction, and the conversion tables 220 and 224 have information indicating a 3600 × 1800 correspondence relationship for each fisheye lens. Will be.

つなぎ位置検出で使用する位置検出用変換テーブル220は、事前に製造元等で、レンズ設計データなどを元に、図6で説明したレンズの射影関係に基づき、放射歪曲および偏心歪曲等に起因した理想的なレンズモデルからの歪みを補正した上で計算され、テーブル化されたものである。これとは対照的に、画像合成用変換テーブル224は、詳細は後述するが、位置検出用変換テーブル220から所定の変換処理よって生成されるものである。なお、説明する実施形態では、変換データは、座標値の対応関係がテーブル化されたデータとしている。しかしながら、他の実施形態では、変換データは、平面座標系で表現される部分画像(x,y)から、球面座標系で表現される画像(θ,φ)への射影を規定する1または複数の関数の係数データとしてもよい。   The conversion table 220 for position detection used in the splice position detection is based on the lens design data and the like, based on the projection relationship of the lens described in FIG. It is calculated after correcting distortion from a typical lens model, and is tabulated. In contrast, the image synthesis conversion table 224 is generated from the position detection conversion table 220 by a predetermined conversion process, as will be described in detail later. In the embodiment to be described, the conversion data is data in which the correspondence between coordinate values is tabulated. However, in other embodiments, the transformed data is one or more that defines the projection from a partial image (x, y) represented in a planar coordinate system to an image (θ, φ) represented in a spherical coordinate system. May be used as coefficient data of the function.

再び図4を参照すると、位置検出用歪み補正部202は、位置検出用変換テーブル220を参照して、部分画像0および部分画像1を変換し、位置検出用補正画像0および位置検出用補正画像1を生成する。より具体的には、位置検出用歪み補正部202は、変換後の補正画像の全座標値(θ,φ)について、位置検出用変換テーブル220を参照し、各座標値(θ,φ)にマッピングされる変換前の部分画像の座標値(x,y)を求め、該座標値(x,y)の部分画像における画素値を参照する。これによって、補正画像が生成される。   Referring again to FIG. 4, the position detection distortion correction unit 202 converts the partial image 0 and the partial image 1 with reference to the position detection conversion table 220, and outputs the position detection corrected image 0 and the position detection corrected image. 1 is generated. More specifically, the position detection distortion correction unit 202 refers to the position detection conversion table 220 for all coordinate values (θ, φ) of the converted corrected image, and converts each coordinate value (θ, φ) into The coordinate value (x, y) of the partial image before conversion to be mapped is obtained, and the pixel value of the coordinate value (x, y) in the partial image is referred to. As a result, a corrected image is generated.

図9は、位置検出処理の際における、2つの魚眼レンズで撮像された2つの部分画像の球面座標系へのマッピングを説明する図である。位置検出用歪み補正部202による処理の結果、魚眼レンズで撮像された2つの部分画像0,1は、図9に示すように、全天球画像フォーマット上に展開される。魚眼レンズ0により撮影された部分画像0は、典型的には、全天球のうちの概ね上半球にマッピングされ、魚眼レンズ1により撮影された部分画像1は、全天球のうちの概ね下半球にマッピングされる。全天球フォーマットで表現された補正画像0および補正画像1は、魚眼レンズの全画角が180度を超えるため、それぞれ半球からはみ出し、その結果、補正画像0および補正画像1を重ね合わせると、画像間で撮影範囲が重複する重複領域が発生する。   FIG. 9 is a diagram illustrating mapping of two partial images captured by two fisheye lenses to a spherical coordinate system in the position detection process. As a result of the processing performed by the position detection distortion correction unit 202, the two partial images 0 and 1 captured by the fisheye lens are developed in a spherical image format as shown in FIG. The partial image 0 captured by the fisheye lens 0 is typically mapped to a substantially upper hemisphere of the whole celestial sphere, and the partial image 1 captured by the fisheye lens 1 is generally mapped to a lower hemisphere of the whole celestial sphere. Is mapped. Since the corrected image 0 and the corrected image 1 expressed in the omnidirectional format exceed the 180-degree angle of view of the fisheye lens, they respectively protrude from the hemisphere. As a result, when the corrected image 0 and the corrected image 1 are superimposed, the image becomes Overlapping areas where the photographing ranges overlap each other occur.

詳細を後述するように、位置検出用歪み補正部202による補正後は、つなぎ位置検出部204により、上記重複領域において、画像間のつなぎ位置が検出されることになる。本実施形態による位置検出用変換テーブル220では、図9に示すように、2つのレンズ光学系各々の光軸を球面の2つの極(φ=0度,180度)に射影するとともに、画像間の重複領域を球面の赤道近傍(φ=90度±((全画角−180度)/2))に射影するように作成される。球面座標系では、垂直角度φが0度または180度である極に近接するほど、歪みが大きくなり、つなぎ位置検出精度が劣化してしまう。これに対し、上述したような射影とすることによって、θ方向にずれたときの歪み量が小さな垂直角度90度付近に、重複領域を位置させて、つなぎ位置検出が行われることになり、つなぎ位置検出精度を向上させることができる。ひいては、歪みの大きなレンズ光学系で撮像された画像であっても、高い精度でつなぎ位置を検出することが可能となる。   As will be described in detail later, after the correction by the position detection distortion correction unit 202, the connection position between the images is detected by the connection position detection unit 204 in the overlapping area. In the conversion table 220 for position detection according to the present embodiment, as shown in FIG. 9, the optical axes of the two lens optical systems are projected onto the two poles (φ = 0 degrees, 180 degrees) of the spherical surface, and the image Are projected to the vicinity of the equator of the spherical surface (φ = 90 degrees ± ((full angle of view−180 degrees) / 2)). In the spherical coordinate system, the closer the vertical angle φ is to 0 ° or 180 ° to the pole, the greater the distortion and the lower the connection position detection accuracy. On the other hand, by performing the projection as described above, the overlapping region is positioned near the vertical angle of 90 degrees where the distortion amount when displaced in the θ direction is small, and the connection position detection is performed. Position detection accuracy can be improved. As a result, it is possible to detect the connection position with high accuracy even for an image captured by a lens optical system having large distortion.

ここで、再び図4を参照すると、つなぎ位置検出部204は、位置検出用歪み補正部202により変換された補正画像0,1の入力を受けて、パターンマッチング処理により、入力された補正画像0,1間のつなぎ位置を検出し、検出結果データ222を生成する。   Here, referring to FIG. 4 again, the joint position detection unit 204 receives the input of the corrected images 0 and 1 converted by the position detection distortion correction unit 202, and performs the pattern matching process to perform the input of the corrected image 0 , 1 are detected, and detection result data 222 is generated.

パターンマッチングでは、典型的には、マッチングを行う対象領域が、その画像が平坦であったり、同じ模様が繰り返された領域であったりして特徴が少ないと、精度高くつなぎ位置を検出することが難しくなる。そこで、本実施形態によるつなぎ位置検出部204は、マッチングを行う対象領域の画像が有する特徴の程度を指標する特徴量を測定し、この測定された特徴量を用いて、対象領域のつなぎ位置を決定する構成を採用する。これにより、特徴の大きな領域で優先してつなぎ合わせを行って、得られる全天球画像の品質の向上を図っている。   In pattern matching, typically, if the target region to be matched is a flat image or a region where the same pattern is repeated and has few features, the connection position can be detected with high accuracy. It becomes difficult. Therefore, the connection position detection unit 204 according to the present embodiment measures a feature amount that indicates the degree of the feature of the image of the target region to be matched, and uses the measured feature amount to determine the connection position of the target region. Adopt a configuration to determine. As a result, the stitching is performed preferentially in a region having a large feature, thereby improving the quality of the obtained omnidirectional image.

図10は、図4に示した本実施形態によるつなぎ位置検出部の機能ブロックを示す図である。図10に示すつなぎ位置検出部204は、より詳細には、テンプレート生成部232と、テンプレート特徴量算出部234と、テンプレート順位付け部236と、仮位置算出部238と、探索範囲設定部240と、マッチング計算部242と、スコア補正部244と、つなぎ位置決定部246と、検出結果生成部248とを含み構成される。以下、テンプレート・マッチングによるつなぎ位置検出処理について説明するが、説明の便宜上、テンプレート側を位置検出用補正画像1とし、探索される側を位置検出用補正画像0とする。   FIG. 10 is a diagram showing functional blocks of the connection position detection unit according to the present embodiment shown in FIG. More specifically, the connection position detection unit 204 shown in FIG. 10 includes a template generation unit 232, a template feature amount calculation unit 234, a template ranking unit 236, a temporary position calculation unit 238, a search range setting unit 240, , A matching calculation unit 242, a score correction unit 244, a connection position determination unit 246, and a detection result generation unit 248. In the following, a description will be given of the connection position detection processing by template matching. For convenience of explanation, the template side is referred to as a position detection correction image 1 and the searched side is referred to as a position detection correction image 0.

テンプレート生成部232は、テンプレート・マッチングにおけるテンプレート用画像として位置検出用補正画像1を用い、位置検出用補正画像1から、それぞれ探索用画像内で探索する対象となる複数の画像(以下、テンプレート画像という。)を生成する。テンプレート・マッチングによるつなぎ位置検出処理では、それぞれ位置検出用補正画像1の一部分であるテンプレート画像各々に対し、位置検出用補正画像0へのつなぎ位置が求められる。ここでは、両補正画像0,1間の重複領域におけるつなぎ位置を目的としているので、位置検出用補正画像1全体のうちの重複領域の部分から複数のテンプレート画像が生成される。   The template generation unit 232 uses the position detection correction image 1 as a template image in template matching, and from the position detection correction image 1, a plurality of images to be searched in the search image (hereinafter, template images). Is generated.) In the connection position detection processing by template matching, a connection position to the position detection correction image 0 is obtained for each template image that is a part of the position detection correction image 1. Here, since the purpose is to connect the overlapping areas between the corrected images 0 and 1, a plurality of template images are generated from the overlapping area in the entire position detection corrected image 1.

テンプレート特徴量算出部234は、テンプレート生成部232により生成された複数のテンプレート画像各々に対し特徴量を算出する。ここで、特徴量とは、テンプレート画像が有する特徴の程度を定量する指標する値であり、本実施形態において、特徴量が大きいとは、画像に大きな特徴が認められることを意味し、特徴量が小さいとは、画像の特徴が少なく無個性であることを意味するものとする。特徴量としては、テンプレート画像から抽出されるエッジ量、テンプレート画像から算出される分散および標準偏差の少なくとも1つを用いることができるが、特に限定されるものではない。   The template feature amount calculation unit 234 calculates a feature amount for each of the plurality of template images generated by the template generation unit 232. Here, the feature amount is a value that is an index for quantifying the degree of the feature of the template image. In the present embodiment, a large feature amount means that a large feature is recognized in the image. Is small means that the image has few features and is individual. As the feature amount, at least one of an edge amount extracted from the template image, a variance calculated from the template image, and a standard deviation can be used, but is not particularly limited.

図11は、特定の実施形態によるテンプレート特徴量算出部のブロック図を示す。図11(A)〜(C)は、エッジ量を指標とする実施形態によるテンプレート特徴量算出部234Aの構成を示す。これに対し図11(D)は、標準偏差または分散を指標とする実施形態によるテンプレート特徴量算出部234Bの構成を示す。   FIG. 11 shows a block diagram of a template feature amount calculation unit according to a specific embodiment. FIGS. 11A to 11C show a configuration of the template feature amount calculation unit 234A according to the embodiment using the edge amount as an index. On the other hand, FIG. 11D illustrates a configuration of the template feature amount calculation unit 234B according to the embodiment using the standard deviation or the variance as an index.

テンプレート画像の特徴量としてエッジ量を用いる場合は、図11(A)に示すようなエッジ強調を行うためのエッジ強調ブロックを用いることができる。図11(A)に示すエッジ強調ブロックは、エッジ抽出フィルタ部250と、ゲイン乗算部252と、LPF(Low-Pass Filter)部254とを含み構成される。エッジ強調ブロックでは、エッジ抽出フィルタ部250で抽出されたエッジ量に対しゲイン乗算部252でゲインを掛けてエッジ量を調整した信号が生成される。そして、調整された信号と、LPF部254で入力信号にLPF処理してノイズ除去した信号とを加算部256で足し合わせた信号が、エッジ強調された信号として出力される。   When the edge amount is used as the feature amount of the template image, an edge enhancement block for performing edge enhancement as shown in FIG. 11A can be used. The edge enhancement block shown in FIG. 11A includes an edge extraction filter unit 250, a gain multiplication unit 252, and an LPF (Low-Pass Filter) unit 254. In the edge emphasizing block, a signal in which the edge amount is adjusted by multiplying the edge amount extracted by the edge extraction filter unit 250 by the gain by the gain multiplication unit 252 is generated. Then, a signal obtained by adding the adjusted signal and a signal from which the input signal has been subjected to the LPF processing to the input signal in the LPF section 254 and removing the noise in the adding section 256 is output as an edge-emphasized signal.

本実施形態では、エッジのみを抽出すればよい。このため、例えば図11(C)に示すようなLPF係数を用いることでLPF処理した信号をゼロにし、図11(B)に示すエッジ抽出フィルタ係数を用いてエッジ抽出フィルタ部250で抽出したエッジ量のみを出力させればよい。図11(A)に示すエッジ強調ブロックにテンプレート画像を入力することにより、各画素毎のエッジ量が出力される。テンプレート画像に対する特徴量としては、テンプレートの全画素のエッジ量の合計を用いてもよいし、エッジ量の平均としてもよい。テンプレート画像のエッジ合計量が大きいほど、画像に明るさが不連続に変化している箇所が多く含まれることを意味する。したがって、平坦な画像は、典型的には、エッジ量が小さくなり、特徴量が小さくなる。   In this embodiment, only the edges need to be extracted. Therefore, for example, the LPF-processed signal is made zero by using the LPF coefficient as shown in FIG. 11C, and the edge extracted by the edge extraction filter unit 250 using the edge extraction filter coefficient shown in FIG. 11B. Only the quantity needs to be output. By inputting the template image to the edge enhancement block shown in FIG. 11A, the edge amount for each pixel is output. As the feature amount for the template image, the sum of the edge amounts of all the pixels of the template may be used, or the average of the edge amounts may be used. The larger the total edge amount of the template image, the more the image includes a portion where the brightness changes discontinuously. Therefore, a flat image typically has a small edge amount and a small feature amount.

テンプレート画像の特徴量として画像の標準偏差(または分散)を用いる場合は、図11(D)に示すような構成を備えることができる。図11(D)に示す標準偏差(または分散)計算部258は、テンプレート画像の標準偏差σ(または分散σ)を下記算出式(2)で求める。なお、下記式(2)においては、テンプレート画像の総画素数をN(=W画素×H画素)とし、テンプレート画像の座標(i,j)における輝度をT(i,j)としている。テンプレート画像の標準偏差(または分散)が大きいほど、ヒストグラムにおいて輝度が広く分布していることを意味する。したがって、平坦な画像は、典型的には画像の輝度の分布が狭くなり、特徴量が小さくなる。 When the standard deviation (or variance) of the image is used as the feature amount of the template image, a configuration as shown in FIG. 11D can be provided. The standard deviation (or variance) calculation unit 258 illustrated in FIG. 11D obtains the standard deviation σ (or variance σ 2 ) of the template image using the following calculation formula (2). In the following equation (2), the total number of pixels of the template image is N (= W pixels × H pixels), and the luminance at the coordinates (i, j) of the template image is T (i, j). The larger the standard deviation (or variance) of the template image, the wider the luminance is distributed in the histogram. Therefore, a flat image typically has a narrow image luminance distribution and a small feature amount.

なお、テンプレート画像の特徴量として、標準偏差および分散を例示したが、テンプレート画像から求められる濃度ヒストグラムにおける尖度(ヒストグラムの分布が平均値周りに集中しているか裾の方へ広がっているかの程度を表す。)や歪度(ヒストグラムの形状が対称な形から歪んでいる程度を表す)などの濃度ヒストグラムに基づく指標、差分統計量に基づくコントラストなど他の統計的な指標を計算し、これらの指標を用いて、テンプレート画像を特徴付けてもよい。また、上述した説明では、輝度値を用いて特徴量を計算するものとして説明したが、RGBの各色毎に特徴量を計算し、その総和としてテンプレート画像の特徴量を計算してもよい。エッジ量や標準偏差、分散などの特徴量は、目的とする画像から簡単に算出することができ、演算コストが少なく、良好な検出結果が得られることから、好適である。しかしながら、これに限定されるものではなく、画像が有する特徴の程度を指標する如何なる指標値を採用することができる。   Although the standard deviation and the variance are illustrated as the feature amounts of the template image, the kurtosis in the density histogram obtained from the template image (the degree to which the distribution of the histogram is concentrated around the average value or spreads toward the tail) ), And other statistical indices such as contrast based on difference statistics, such as an index based on a density histogram such as skewness (indicating the degree to which the shape of the histogram is distorted from a symmetric shape). The index may be used to characterize the template image. In the above description, the feature value is calculated using the luminance value. However, the feature value may be calculated for each of the RGB colors, and the feature value of the template image may be calculated as the sum of the feature values. The feature amounts such as the edge amount, the standard deviation, and the variance can be easily calculated from the target image, the calculation cost is low, and a good detection result is obtained. However, the present invention is not limited to this, and any index value that indicates the degree of the feature of the image can be adopted.

再び図10を参照すると、テンプレート順位付け部236は、テンプレート特徴量算出部234で算出された特徴量に基づいて、複数のテンプレート画像の処理の順序を順位付けし、テンプレート画像間の特徴量の相対的な関係を規定する。   Referring again to FIG. 10, the template ranking unit 236 ranks the order of processing of the plurality of template images based on the feature amounts calculated by the template feature amount calculation unit 234, and calculates the feature amount between the template images. Define relative relationships.

仮位置算出部238は、生成された複数のテンプレート画像のうちの、注目する注目テンプレート画像について、後述するテンプレート・マッチング処理の基準とする仮位置を算出する。ここでは、注目テンプレート画像と、その位置検出用補正画像1上でその周辺にある周辺テンプレート画像各々との間の特徴量の相対的な関係に基づいて仮位置が算出される。   The provisional position calculation unit 238 calculates a provisional position as a reference of a template matching process to be described later, with respect to the template image of interest out of the plurality of generated template images. Here, the provisional position is calculated based on the relative relationship between the feature amounts between the template image of interest and each of the peripheral template images around the position detection corrected image 1.

テンプレート・マッチングは、テンプレート画像を、探索する対象となる探索用画像の中から探索する処理であるが、ある程度テンプレート画像に対応する領域が特定されている場合は、探索用画像中の探索範囲を限定することができる。探索範囲設定部240は、上記注目テンプレート画像について、注目テンプレート画像と周辺テンプレート画像各々との間の特徴量の相対的な関係に基づいて、テンプレート・マッチングでの探索範囲を設定する。典型的には、上記仮位置算出部238により算出された仮位置を中心とした位置検出用画像0における所定の探索範囲が設定される。また、周辺テンプレート画像について決定済みのつなぎ位置に基づいて、さらに、絞り込まれた探索範囲を設定してもよい。   The template matching is a process of searching for a template image from a search image to be searched. If a region corresponding to the template image is specified to some extent, the search range in the search image is determined. Can be limited. The search range setting unit 240 sets a search range for template matching based on the relative relationship between the feature amounts of the template image of interest and the peripheral template images. Typically, a predetermined search range in the position detection image 0 centering on the temporary position calculated by the temporary position calculation unit 238 is set. Further, a further narrowed search range may be set based on the determined connection position of the peripheral template image.

マッチング計算部242は、上記注目テンプレート画像について、典型的にはテンプレート・マッチング方式により、上記算出された仮位置に基づいて、上記注目テンプレート画像と、位置検出用補正画像における各部分とのマッチングを計算する。マッチングの計算では、上記探索範囲設定部240によって設定された仮位置を中心とした探索範囲で、テンプレート画像を移動させながら、各位置での画像の類似度に基づく評価値であるマッチング・スコアが計算される。   The matching calculation unit 242 performs matching of the target template image with each part of the position detection corrected image based on the calculated temporary position, typically by a template matching method. calculate. In the matching calculation, the matching score, which is an evaluation value based on the similarity of the image at each position, is calculated while moving the template image within the search range centered on the temporary position set by the search range setting unit 240. Is calculated.

スコア補正部244は、上記注目テンプレート画像について、上述したマッチング計算部242により算出された画像の類似度に基づくスコアに対し、上記算出された仮位置を中心として優先的にスコアが高くなるようなオフセット補正を行う。これにより、テンプレート画像間の特徴量の相対的な関係に基づいて算出された仮位置を加味したスコアが計算される。   The score correction unit 244 preferentially increases the score of the template image of interest with respect to the score based on the similarity of the image calculated by the matching calculation unit 242 described above, with the calculated temporary position as the center. Perform offset correction. As a result, a score is calculated in consideration of the provisional position calculated based on the relative relationship between the feature amounts between the template images.

つなぎ位置決定部246は、上記注目テンプレート画像に対して、位置検出用補正画像0上で上記補正されたスコアが最大化される位置につなぎ位置を決定する。このとき決定されるつなぎ位置は、注目テンプレート画像よりも特徴量が大きい周辺テンプレート画像のつなぎ位置が加味されたものとなる。   The connection position determination unit 246 determines a connection position of the target template image at a position where the corrected score is maximized on the position detection correction image 0. The connection position determined at this time is a position in which the connection position of the peripheral template image having a larger feature amount than the template image of interest is added.

上述した仮位置算出部238、探索範囲設定部240、マッチング計算部242、スコア補正部244およびつなぎ位置決定部246による処理が、複数のテンプレート画像各々について行われると、テンプレート画像各々に対応した位置検出用補正画像0上のつなぎ位置が求められる。検出結果生成部248は、ここで求められた各テンプレート画像に対応するつなぎ位置のデータ・セットに基づいて、全天球フォーマットの各画素(θ,φ)毎のつなぎ位置を計算し、検出結果データ222を生成する。   When the above-described processing by the provisional position calculation unit 238, the search range setting unit 240, the matching calculation unit 242, the score correction unit 244, and the connection position determination unit 246 is performed for each of the plurality of template images, the position corresponding to each of the template images is determined. The connection position on the correction image for detection 0 is obtained. The detection result generation unit 248 calculates the connection position for each pixel (θ, φ) in the spherical format based on the data set of the connection position corresponding to each template image obtained here, and Generate data 222.

再び図4を参照すると、テーブル修正部206は、検出結果データ222に基づいて、事前準備された位置検出用変換テーブル220に対して修正を施し、テーブル生成部208に渡す。テーブル生成部208は、上記テーブル修正部206により修正された変換データから、回転座標変換に基づき、画像合成用変換テーブル224を生成する。   Referring again to FIG. 4, the table correction unit 206 corrects the previously prepared position detection conversion table 220 based on the detection result data 222 and passes the correction to the table generation unit 208. The table generation unit 208 generates an image synthesis conversion table 224 from the conversion data corrected by the table correction unit 206 based on rotational coordinate conversion.

画像合成用歪み補正部210は、画像合成処理の前段の処理として、元の部分画像0および部分画像1に対し、画像合成用変換テーブル224を用いて歪み補正をかけ、画像合成用補正画像0および画像合成用補正画像1を生成する。生成される画像合成用補正画像は、位置検出用補正画像と同様に、球面座標系で表現されている一方で、上記回転座標変換により、位置検出用補正画像とは座標軸の定義が異なったものとなる。画像合成部212は、得られた画像合成用補正画像0および画像合成用補正画像1を合成し、全天球画像フォーマットの合成画像を生成する。なお、つなぎ位置検出部204、テーブル修正部206、テーブル生成部208、画像合成用歪み補正部210および画像合成部212が実行する処理については、処理フローの説明とともに詳細を後述する。   The image synthesis distortion correction unit 210 performs distortion correction on the original partial image 0 and the partial image 1 using the image synthesis conversion table 224 as a process prior to the image synthesis process. And a corrected image 1 for image synthesis. The generated corrected image for image synthesis is expressed in a spherical coordinate system similarly to the corrected image for position detection, but the definition of the coordinate axis is different from that of the corrected image for position detection due to the rotation coordinate conversion. Becomes The image synthesizing unit 212 synthesizes the obtained corrected image for synthesizing image 0 and the obtained corrected image for synthesizing image 1 to generate a synthesized image in the spherical image format. Note that the processing executed by the joint position detection unit 204, the table correction unit 206, the table generation unit 208, the image synthesis distortion correction unit 210, and the image synthesis unit 212 will be described later in detail together with the description of the processing flow.

図4に示す機能ブロック200は、さらに、表示画像生成部214を含むことができる。上記生成された合成画像は、全天球画像フォーマットで表現されるため、そのまま、ディスプレイなどの平面表示デバイスに表示させると、垂直角度0度および180度に近づくほど画像が歪んで表示されることになる。表示画像生成部214は、全天球画像を平面表示デバイスに投影するための画像処理を実行する手段である。表示画像生成部214は、例えば、全天球画像フォーマットの合成画像から、球面座標系から特定方向および特定画角の平面座標系へ変換し、ユーザが指定する特定の視野方向の一定画角の画像に投影する処理を行うことができる。   The functional block 200 illustrated in FIG. 4 can further include a display image generation unit 214. Since the generated composite image is expressed in a spherical image format, if it is displayed as it is on a flat display device such as a display, the image is distorted as the vertical angles approach 0 and 180 degrees. become. The display image generation unit 214 is a unit that executes image processing for projecting a spherical image on a flat display device. The display image generation unit 214 converts, for example, a composite image in the spherical image format from a spherical coordinate system to a planar coordinate system with a specific direction and a specific angle of view, and converts the image into a specific angle of view in a specific viewing direction specified by the user. A process of projecting an image can be performed.

[全天球画像合成処理の流れ]
以下、図5、図12および図20を参照して、本実施形態による全天球画像合成処理の流れを説明する。図5は、本実施形態による撮像システム10が実行する全天球画像合成処理の全体的な流れを示すフローチャートである。図5に示す処理は、例えば、シャッター・ボタン18の押下により2つの撮像光学系で撮影が指示され、CPU130から指令が発行されたことに応答して、ステップS200から開始される。
[Flow of spherical image synthesis processing]
Hereinafter, the flow of the omnidirectional image synthesis processing according to the present embodiment will be described with reference to FIGS. FIG. 5 is a flowchart illustrating an overall flow of the omnidirectional image combining process performed by the imaging system 10 according to the present embodiment. The process illustrated in FIG. 5 is started from step S200 in response to, for example, pressing of the shutter button 18 instructing shooting with the two imaging optical systems and issuing a command from the CPU 130.

ステップS201では、撮像システム10は、位置検出用歪み補正部202により、2つの固体撮像素子22A,22Bによって取得された部分画像0および部分画像1に対し、位置検出用変換テーブル220を用いて歪み補正を行う。これによって、位置検出用補正画像0および位置検出用補正画像1が得られる。これにより、図9に示すような全天球画像フォーマットの補正画像が得られる。ステップS202では、撮像システム10は、つなぎ位置検出部204により、位置検出用補正画像0および位置検出用補正画像1の重複領域において、画像間のつなぎ位置検出を行う。   In step S201, the imaging system 10 uses the position detection conversion table 220 to correct the partial image 0 and the partial image 1 acquired by the two solid-state imaging devices 22A and 22B by the position detection distortion correction unit 202. Make corrections. Thus, a corrected image for position detection 0 and a corrected image for position detection 1 are obtained. Thereby, a corrected image in the spherical image format as shown in FIG. 9 is obtained. In step S <b> 202, the imaging system 10 causes the connection position detection unit 204 to detect a connection position between images in an overlapping area of the position detection correction image 0 and the position detection correction image 1.

図12は、本実施形態による撮像システム10が実行する、つなぎ位置検出処理を示すフローチャートである。図12に示す処理は、図5に示したステップS202で呼び出されて、ステップS300から開始される。ステップS301では、撮像システム10は、テンプレート用画像、探索される探索用画像、テンプレートのブロック・サイズ、テンプレートを生成する開始座標、テンプレートの生成間隔および全ブロック数の初期設定を行う。   FIG. 12 is a flowchart illustrating the connection position detection processing executed by the imaging system 10 according to the present embodiment. The process illustrated in FIG. 12 is called in step S202 illustrated in FIG. 5 and is started from step S300. In step S301, the imaging system 10 initializes a template image, a search image to be searched, a template block size, a template generation start coordinate, a template generation interval, and the total number of blocks.

図13は、本実施形態によるテンプレート生成部によるテンプレート画像の生成方法を説明する図である。説明する実施形態では、テンプレート用画像300は、位置検出用補正画像1の重複領域の部分の画像であり、探索用画像310は、位置検出用補正画像0の重複領域の部分の画像である。上記ブロック・サイズは、テンプレート画像を構成する画素サイズであり、上記生成間隔は、隣接するテンプレート画像が生成される間隔である。上記生成開始座標は、最初のテンプレート画像を切り出す座標である。なお、ブロック・サイズおよび生成間隔は、つなぎ合わせの所望の精度および処理量を勘案して定めればよい。   FIG. 13 is a diagram illustrating a method for generating a template image by the template generating unit according to the present embodiment. In the embodiment to be described, the template image 300 is an image of the overlapping area of the position detection corrected image 1, and the search image 310 is an image of the overlapping area of the position detection corrected image 0. The block size is a pixel size of a template image, and the generation interval is an interval at which adjacent template images are generated. The generation start coordinates are coordinates at which the first template image is cut out. Note that the block size and the generation interval may be determined in consideration of the desired accuracy and the processing amount of the connection.

ブロック・サイズをW画素×H画素とし、生成開始座標を(sx,sy)とし、生成間隔をstep画素とすると、図13に示すような態様で複数のテンプレート画像302−1〜302−#が生成される。生成されるテンプレートのブロック数#は、テンプレート生成用画像300の水平方向サイズ(説明する実施形態で全天球フォーマットの幅サイズ=3600画素)を生成間隔(step)で割った値の整数値となる。   Assuming that the block size is W pixels × H pixels, the generation start coordinates are (sx, sy), and the generation interval is step pixels, a plurality of template images 302-1 to 302- # are formed as shown in FIG. Generated. The number of blocks # of the template to be generated is an integer value of a value obtained by dividing a horizontal size of the template generation image 300 (width size of the spherical format in the embodiment to be described = 3600 pixels) by a generation interval (step). Become.

ここで生成された複数のテンプレート画像302−1〜302−#に対し、探索用画像310上での対応部分314が所定の探索範囲312内で探索されることになる。なお、全天球画像フォーマットのθ座標の両端(0度および360度)はつながっているため、テンプレート画像の生成やテンプレート・マッチングの際は、右端の隣は左端として、左端の隣は右端として取り扱うことができる。   For the plurality of template images 302-1 to 302- # generated here, a corresponding portion 314 on the search image 310 is searched within a predetermined search range 312. Since both ends (0 degrees and 360 degrees) of the θ coordinate in the spherical image format are connected, when generating a template image or template matching, the right end is set as the left end, and the left end is set as the right end. Can handle.

図12を参照すると、ステップS302では、現在の座標(sx,sy)に基づいて、テンプレート画像を生成する。第1回目のループでは、ステップS301で初期設定された生成開始座標(sx,sy)からブロック・サイズの領域(W画素×H画素)が切り出されてテンプレート画像が生成される。テンプレート画像生成後は、座標を(sx+step,sy)に更新し、2回目以降のテンプレート生成は、同様にして更新された座標からブロック・サイズの領域を指定して生成されることになる。テンプレート画像が生成されると、生成されたテンプレート画像に対し、図13に模式的に示すようなテンプレート番号(以下、単に番号と参照することもある。)が付与される。なお、特に限定されるものではないが、説明する実施形態では、テンプレート画像は、重複領域においてθ方向に一列、一周分、生成されるものとする。   Referring to FIG. 12, in step S302, a template image is generated based on the current coordinates (sx, sy). In the first loop, a block-size area (W pixels × H pixels) is cut out from the generation start coordinates (sx, sy) initialized in step S301 to generate a template image. After the template image is generated, the coordinates are updated to (sx + step, sy), and the second and subsequent template generations are generated by specifying a block size area from the updated coordinates in the same manner. When the template image is generated, a template number (hereinafter, may be simply referred to as a number) as schematically shown in FIG. 13 is assigned to the generated template image. Although not particularly limited, in the embodiment to be described, it is assumed that the template images are generated in the overlapping region for one line and one turn in the θ direction.

ステップS303では、撮像システム10は、ステップS302で生成されたテンプレート画像から特徴量を算出する。ステップS304では、撮像システム10は、生成されるべき全てのブロックの処理が終了しているか否かを判定する。ステップS304で、終了していないと判定された場合(NO)は、ステップS302へループさせて、次のテンプレート画像の生成および特徴量の算出に処理を進める。一方、ステップS304で、全てのブロックの処理が終了したと判定された場合(YES)は、ステップS305へ処理を分岐させる。   In step S303, the imaging system 10 calculates a feature amount from the template image generated in step S302. In step S304, the imaging system 10 determines whether or not processing of all blocks to be generated has been completed. If it is determined in step S304 that the process has not been completed (NO), the process loops to step S302, and proceeds to the generation of the next template image and the calculation of the feature amount. On the other hand, if it is determined in step S304 that the processing of all blocks has been completed (YES), the processing branches to step S305.

ステップS305では、撮像システム10は、全てのブロックのテンプレート画像を、その特徴量の大きい方から小さい方へ順位付ける。これにより、ステップS306以降の処理順序が規定される。図14(A)は、本実施形態によるテンプレート画像の順位付けを説明する図である。図14(A)に示すように、各番号のテンプレート画像に対し、特徴量の大きい順にテンプレート順位が付される。図12に示すステップS306〜ステップS311の処理は、ステップS305で決定された順序で、順位の高いテンプレート画像から順に処理対象として選択され処理が行われる。   In step S305, the imaging system 10 ranks the template images of all the blocks from the largest feature amount to the smallest feature amount. Thereby, the processing order after step S306 is defined. FIG. 14A is a diagram illustrating the ranking of template images according to the present embodiment. As shown in FIG. 14A, the template order of each number is assigned to the template image in the descending order of the feature amount. The processes of steps S306 to S311 shown in FIG. 12 are selected and processed in the order determined in step S305, starting from the template image having the highest rank.

図12を参照すると、ステップS306では、撮像システム10は、処理対象として注目する注目テンプレート画像に対し、仮位置を算出する。図14(B)は、本実施形態による仮位置算出部が行う、順位付けに基づくテンプレート画像の仮位置の第1の算出方法を説明する図である。第1の計算方法においては、まず、注目テンプレート画像の周辺に位置する周辺テンプレート画像に対して設定されているつなぎ位置を取得する。   Referring to FIG. 12, in step S306, the imaging system 10 calculates a tentative position for a template image of interest to be processed. FIG. 14B is a diagram illustrating a first calculation method of the temporary position of the template image based on the ranking performed by the temporary position calculation unit according to the present embodiment. In the first calculation method, first, a connection position set for a peripheral template image located around the template image of interest is acquired.

説明する実施形態では、テンプレート画像は、重複領域においてθ方向に一列に生成され、左側から順にテンプレート番号が付されているので、番号で隣接関係が識別される。図14(B)に示す例では、注目テンプレート画像(図中では番号3のもの)の前後のテンプレート画像(図中では番号2および番号4のもの)のつなぎ位置が取得される。テンプレート画像各々には、図12のステップS305でテンプレート順位が付されており、図12のステップS306〜ステップS311までのつなぎ位置を検出する処理は、順位の高いものから実施される。このため、注目テンプレート画像よりも大きな特徴量を有し、順位がより高いテンプレート画像に対しては、既につなぎ位置が決定していることになる。   In the embodiment to be described, the template images are generated in a line in the θ direction in the overlapping area, and the template numbers are assigned in order from the left side, so that the adjacent relation is identified by the number. In the example shown in FIG. 14B, the connection positions of the template images (numbered 2 and 4 in the figure) before and after the target template image (numbered 3 in the figure) are acquired. The template order is assigned to each template image in step S305 in FIG. 12, and the process of detecting the connection position from step S306 to step S311 in FIG. 12 is performed in descending order. For this reason, for a template image having a feature amount larger than that of the template image of interest and having a higher rank, the connection position has already been determined.

したがって、図14(B)の例示では、注目テンプレート画像(番号3)の順位が3位であるため、テンプレート順位が1位および2位であるテンプレート画像(番号4および番号1のもの)のつなぎ位置が既に決定済みということになる。一方、図14(B)において反転表示されている4位〜6位のテンプレート画像(番号2、番号5および番号6のもの)に対しては、つなぎ位置が未決定であり、初期つなぎ位置として(0,0)が設定されている。なお、注目テンプレート画像(番号3)のつなぎ位置も、現時点では初期つなぎ位置(0,0)となっている。つなぎ位置は、補正画像1の重複領域におけるテンプレート画像の座標と、補正画像0の重複領域における対応する領域の座標とのズレ量を表し、つなぎ位置(0,0)は、テンプレート画像が、補正画像1上の座標位置そのままでつなぎ合わされることを意味する。   Therefore, in the example of FIG. 14B, since the order of the template image of interest (number 3) is third, the template images (number 4 and number 1) whose template order is first and second are connected. The position has already been determined. On the other hand, for the fourth to sixth template images (numbered 2, 5, and 6) highlighted in FIG. 14B, the connection position is not determined, and the initial connection position is determined. (0, 0) is set. The connection position of the template image of interest (No. 3) is also the initial connection position (0, 0) at the present time. The joint position indicates the amount of deviation between the coordinates of the template image in the overlap area of the corrected image 1 and the coordinates of the corresponding area in the overlap area of the corrected image 0. The joint position (0, 0) indicates that the template image is This means that the images are connected as they are at the coordinate position on the image 1.

よって、図14(B)の例示では、周辺テンプレート画像のつなぎ位置として、注目テンプレート画像(図中では番号3のもの)の右側のテンプレート画像(図中では番号4のもの)の決定済みのつなぎ位置と、左側のテンプレート画像(図中では番号2のもの)の初期つなぎ位置とが取得される。   Therefore, in the example of FIG. 14B, as the connection position of the peripheral template images, the determined connection of the template image (the one with the number 4 in the figure) on the right side of the template image of interest (the one with the number 3 in the figure) is determined. The position and the initial connection position of the template image on the left (the number 2 in the figure) are acquired.

そして、取得された周辺テンプレート画像のつなぎ位置を平均処理し、その平均値を注目テンプレートの仮位置とすることができる。この際、単純な相加平均を計算してもよいが、好適には、決定済みのつなぎ位置と、未決定のつなぎ位置(初期つなぎ位置)とで重みを変えて、重み付き平均を行うことができる。具体的には、決定済みのつなぎ位置の方の影響が強くなるように重みを大きくすることができる。   Then, the averaging process is performed on the connection positions of the acquired peripheral template images, and the average value can be used as the provisional position of the template of interest. At this time, a simple arithmetic average may be calculated, but it is preferable to perform weighted averaging by changing the weight between the determined connection position and the undetermined connection position (initial connection position). Can be. Specifically, the weight can be increased so that the influence of the determined connection position becomes stronger.

注目テンプレート画像(番号i)の仮位置(tx,ty)は、下記計算式(3)により計算することができる。下記式(3)においては、左側のテンプレート画像(番号i−1)のつなぎ位置を(xi−1,yi−1)、その重みをwとし、右側のテンプレート画像(i+1)のつなぎ位置を(xi+1,yi+1)、その重みをwとしている。wおよびwは、対応する隣接テンプレート画像のつなぎ位置が決定済みか否かに応じた重み値である。 Temporary position of the target template image (No. i) (tx i, ty i) can be calculated by the following equation (3). In the following formula (3), the splice point of the left side of the template image (No. i-1) (x i- 1, y i-1), the weight w - a, joint of the right template image (i + 1) The position is (x i + 1 , y i + 1 ), and the weight is w + . w and w + are weight values according to whether or not the connection position of the corresponding adjacent template image has been determined.

図14(B)の例示において、例えば、決定済みの重み係数wを「0.7」、未決定の重み係数wを「0.3」とし、決定済みのテンプレート番号4のつなぎ位置を(2,−2)、未決定のテンプレート番号2のつなぎ位置を初期値(0,0)とすると、上記計算式(3)により、注目テンプレート画像(番号3)の仮位置は(1.4,−1.4)となる。 In the exemplary FIG. 14 (B), the example, the already determined weighting factor w H "0.7", the weighting factor w L undecided as "0.3", the joint position of the determined template number 4 (2, -2), assuming that the connection position of the undecided template number 2 is an initial value (0, 0), the provisional position of the template image of interest (number 3) is (1.4) by the above formula (3). , -1.4).

図14(C)は、本実施形態による仮位置算出部が行う、順位付けに基づくテンプレート画像の仮位置の第2の算出方法を説明する図である。図14(C)に示す第2の算出方法においては、まず、注目テンプレート画像の周辺テンプレート画像として、すべてのテンプレート画像について、注目テンプレート画像からの距離と、設定されているつなぎ位置とが取得される。つなぎ位置が未決定のものについては、上記と同様に初期つなぎ位置(0,0)が取得される。テンプレート画像間の距離は、単純にブロック数を単位とすればよい。図14(C)においては、例えば、注目テンプレートをテンプレート番号3として、番号2および番号4のテンプレート画像に対しては距離1が、番号1および番号5のものに対しては距離2が、番号6のものに対しては距離3が与えられる。   FIG. 14C is a diagram illustrating a second method of calculating the temporary position of the template image based on the ranking performed by the temporary position calculation unit according to the present embodiment. In the second calculation method shown in FIG. 14C, first, as a peripheral template image of the template image of interest, the distance from the template image of interest and the set connection position are obtained for all template images. You. If the connection position has not been determined, the initial connection position (0, 0) is obtained in the same manner as described above. The distance between template images may simply be based on the number of blocks. In FIG. 14C, for example, the template of interest is set as template number 3, and distance 1 is set for template images of numbers 2 and 4, distance 2 is set for those of numbers 1 and 5, and A distance of 3 is given to the six.

そして、取得された周辺テンプレート画像のつなぎ位置を距離で重み付けして平均処理し、その平均値を注目テンプレート画像の仮位置とすることができる。距離に基づく重み付けは、距離が近いほど大きくなるような関数を用いることができる。例えば、距離の逆数(1/距離)を重み値として使用することができる。   Then, the obtained connection positions of the peripheral template images are weighted by distance and averaged, and the average value can be used as the temporary position of the template image of interest. For the weighting based on the distance, a function that increases as the distance decreases can be used. For example, the reciprocal of the distance (1 / distance) can be used as the weight value.

注目テンプレート画像(番号i)の仮位置を(tx,ty)として、各テンプレート画像(番号j=1〜N)のつなぎ位置を(x,y)、その距離をDijとすると、下記計算式(4)により、仮位置(tx,ty)を計算することができる。図14(C)に示す第2の算出方法によれば、隣接以外の遠くのテンプレート画像のつなぎ位置も考慮されるので、周辺との連続性をより良好に維持することができる。なお、注目テンプレート画像の周辺テンプレート画像として、すべてのテンプレート画像の距離およびつなぎ位置を取得するものとしたが、距離で所定の打ち切りを行ってもよい。 Target template image (No. i) the temporary position (tx i, ty i) As a connecting position of each template image (ID j = 1~N) (x j, y j), when the distance is D ij , The temporary position (tx i , ty i ) can be calculated by the following formula (4). According to the second calculation method shown in FIG. 14 (C), the continuity with the surroundings can be more favorably maintained because the connection position of a distant template image other than the adjacent one is also considered. Note that, as the peripheral template images of the template image of interest, the distances and connection positions of all the template images are acquired, but a predetermined cutoff may be performed at the distances.

なお、上記説明では、隣接テンプレート画像のつなぎ位置が決定済みか否かに応じた重み値、またはテンプレート画像間の距離に応じた重み値を用いるものとして説明した。しかしながら、上述した計算方法は、一例であり、特に限定されるものではない。他の実施形態では、隣接テンプレート画像のつなぎ位置が決定済みか否かに応じ、かつ、テンプレート画像間の距離に応じて、重み付けを行ってもよい。   In the above description, the weight value according to whether the connection position of the adjacent template images has been determined or the weight value according to the distance between the template images is used. However, the above calculation method is an example, and is not particularly limited. In another embodiment, weighting may be performed according to whether or not the connection position between adjacent template images has been determined and according to the distance between the template images.

再び図12を参照すると、ステップS307では、撮像システム10は、テンプレート・マッチングを行う探索領域の探索範囲を設定する。図15は、本実施形態による探索範囲設定部が行う探索範囲の設定方法を説明する図である。テンプレート・マッチングでは、注目テンプレート画像について、所定サイズの探索領域が探索用画像から切り出される。探索用画像である位置検出用画像0と、テンプレート用画像である位置検出用画像1とは、事前定義された位置検出用変換テーブルによって生成されるので、ある程度の精度で重ね合わせられている。このため、テンプレート画像に対応する部分は、対応する補正画像0上の座標の近傍に見出されることが予測されるので、この座標を基準として探索領域が切り出される。上記探索範囲は、探索領域においてテンプレート・マッチングを行う範囲を決めるもので、この探索範囲内でテンプレート画像を縦横に位置をずらしながら探索領域の画像とマッチングが行われる。このため、探索範囲が広くなるにつれて処理時間が長くなる。   Referring to FIG. 12 again, in step S307, the imaging system 10 sets a search range of a search area for performing template matching. FIG. 15 is a diagram illustrating a search range setting method performed by the search range setting unit according to the present embodiment. In the template matching, a search area of a predetermined size is cut out from the search image for the template image of interest. The position detection image 0 that is the search image and the position detection image 1 that is the template image are generated by a predefined position detection conversion table, and are thus superimposed with a certain degree of accuracy. For this reason, since it is predicted that a portion corresponding to the template image will be found near the coordinates on the corresponding corrected image 0, the search area is cut out based on the coordinates. The search range determines the range in which the template matching is performed in the search area. The template image is matched with the image in the search area while shifting the position of the template image vertically and horizontally within the search range. Therefore, the processing time becomes longer as the search range becomes wider.

図15(A)は、通常の探索範囲360の設定方法を説明するものであり、通常の設定方法では、初期位置(○:テンプレート画像の座標と一致)を中心にした探索領域330をそのまま探索範囲360Aとする。この場合、探索領域330と探索範囲360Aとが同じとなり、探索領域全てでマッチング計算を行う必要がある。   FIG. 15A illustrates a method for setting the normal search range 360. In the normal setting method, the search area 330 centered on the initial position (○: coincident with the coordinates of the template image) is directly searched. The range is 360A. In this case, the search area 330 and the search range 360A are the same, and it is necessary to perform matching calculation in all the search areas.

これに対して、図15(B)は、算出された仮位置に基づいて探索範囲を設定する方法を説明する。通常、決定された仮位置(図では●で示す。)334は、特徴のあるテンプレートの影響を受けて初期位置(図では○で示す。)332から移動しているため、仮位置(●)を中心にして探索領域を移動させ(350)、元の探索領域330と重なる領域を探索範囲360Bとすることにより、探索範囲を狭め、処理時間を短縮することができる。   On the other hand, FIG. 15B illustrates a method for setting a search range based on the calculated temporary position. Normally, the determined tentative position (indicated by ● in the figure) 334 is moved from the initial position (indicated by ○ in the figure) 332 under the influence of the characteristic template. Is moved around the search area (350), and the area overlapping with the original search area 330 is set as the search range 360B, thereby narrowing the search range and shortening the processing time.

図15(C)は、さらに、隣接するテンプレート画像について決定済みのつなぎ位置に基づいて探索範囲を設定する方法を説明するものである。図15(B)に示す方法と同様に、決定された仮位置(●)を中心にして探索領域を移動させ(350)、元の探索領域330と重なる領域を求める。続いて、隣接するテンプレート画像について決定済みのつなぎ位置を参照し、さらに絞り込んだ探索範囲360Cを決定する。例えば、両側の隣接テンプレート画像のつなぎ位置が決定済みの場合には、注目テンプレートのつなぎ位置は、概ねその間に限定されると考えられる。そこで、図15(C)のように両側のテンプレート画像の縦方向のつなぎ位置336U,336Lを利用して縦方向に制限を与えて、探索範囲360Bを狭めることで、さらに処理時間を短縮することができる。   FIG. 15C further describes a method of setting a search range based on a determined connection position for adjacent template images. As in the method shown in FIG. 15B, the search area is moved around the determined temporary position (●) (350), and an area overlapping the original search area 330 is obtained. Subsequently, referring to the determined connection positions of the adjacent template images, the search range 360C further narrowed down is determined. For example, if the joining positions of the adjacent template images on both sides have already been determined, the joining positions of the template of interest are considered to be limited substantially between them. Therefore, as shown in FIG. 15C, the processing time is further shortened by using the vertical connection positions 336U and 336L of the template images on both sides to restrict in the vertical direction and narrow the search range 360B. Can be.

再び図12を参照すると、ステップS308では、撮像システム10は、ステップS307で設定された探索範囲内で、探索領域上でテンプレート画像を縦方向および横方向にずらしながら、マッチングを計算し、類似度のスコアを求める。   Referring again to FIG. 12, in step S308, the imaging system 10 calculates matching while shifting the template image vertically and horizontally in the search area within the search range set in step S307, and calculates the similarity. Find the score of

以下、図16を参照して、テンプレート・マッチングの一例として、ゼロ平均正規化相互相関(Zero-mean Normalized Cross-Correlation)法について説明する。図16は、(A)テンプレート画像と、(B)パターンマッチングにより探索範囲でテンプレート画像を探索する処理を説明する図である。テンプレートの全画素数をN(=W画素×H画素)とし、探索範囲上での探索位置を(kx,ky)で表す。探索位置(kx,ky)を基準座標(0,0)とした場合の座標(i,j)におけるテンプレート画像の輝度値をT(i,j)とし、探索用画像上の輝度値をS(kx+i,ky+j)とすると、ZNCC法によるマッチング・スコアM(kx,ky)は、下記式(5)で求めることができる。なお、図16では、探索位置(kx,ky)をテンプレート画像の左上に設定しているが、座標の取り方は、特に限定されるものではなく、テンプレート画像の中心に設定してもよい。   Hereinafter, a zero-mean normalized cross-correlation method will be described as an example of template matching with reference to FIG. FIG. 16 is a diagram illustrating a process of searching for a template image in a search range by (A) a template image and (B) pattern matching. The total number of pixels of the template is N (= W pixels × H pixels), and the search position on the search range is represented by (kx, ky). When the search position (kx, ky) is the reference coordinate (0, 0), the luminance value of the template image at the coordinates (i, j) is T (i, j), and the luminance value on the search image is S ( kx + i, ky + j), the matching score M (kx, ky) by the ZNCC method can be obtained by the following equation (5). In FIG. 16, the search position (kx, ky) is set at the upper left of the template image. However, the way of obtaining the coordinates is not particularly limited, and may be set at the center of the template image.

スコアM(kx,ky)が1のときは、完全一致となり、−1のときはネガポジ反転となる。スコアM(kx,ky)が高い方が、テンプレート画像との類似度が高いことを示す。図16(B)に示すように探索範囲内でテンプレート画像を縦横に位置をずらしながら、テンプレート・マッチングが行われ、各探索位置におけるマッチング・スコアM(kx,ky)が算出される。   When the score M (kx, ky) is 1, perfect matching is obtained, and when the score is -1, negative-positive inversion is performed. A higher score M (kx, ky) indicates a higher similarity to the template image. As shown in FIG. 16B, template matching is performed while shifting the position of the template image vertically and horizontally within the search range, and a matching score M (kx, ky) at each search position is calculated.

なお、上述したZNCC法は、画像のゲインの変動を吸収することができ、また、画像の平均明るさの変動を吸収することができる点で好適なものであるが、スコアM(kx,ky)の算出方法は、ZNCC法に限定されるものではない。他の実施形態では、SSD(Sum of Square Difference)法、SAD(Sum of Absolute Difference)法、ZSSD(Zero-mean Sum of Square Difference)法、ZSAD(Zero mean Sum of Absolute Difference)法、NCC(Normalized Cross-Correlation)法などを採用してもよい。   The above-mentioned ZNCC method is suitable in that it can absorb fluctuations in the gain of an image and can also absorb fluctuations in the average brightness of an image, but the score M (kx, ky) ) Is not limited to the ZNCC method. In other embodiments, SSD (Sum of Square Difference) method, SAD (Sum of Absolute Difference) method, ZSSD (Zero-mean Sum of Square Difference) method, ZSAD (Zero mean Sum of Absolute Difference) method, NCC (Normalized) Cross-Correlation) may be employed.

再び図12を参照すると、ステップS309では、撮像システム10は、ステップS308で計算された各位置における類似度に基づくマッチング・スコアM(kx,ky)に対し、オフセット補正を行って、補正された最終的なスコアを計算する。ステップS310では、撮像システム10は、ステップS309で計算された各位置における補正後のスコアに基づいて、当該注目テンプレート画像に対するつなぎ位置を決定する。   Referring again to FIG. 12, in step S309, the imaging system 10 performs offset correction on the matching score M (kx, ky) based on the similarity at each position calculated in step S308, and the correction is performed. Calculate the final score. In step S310, the imaging system 10 determines a connection position for the template image of interest based on the corrected score at each position calculated in step S309.

図17(A)は、マッチング・スコアに対するオフセット関数を探索位置(kx/ky)に対してプロットしたグラフを示す。ステップS309の処理では、マッチング・スコアM(kx,ky)に対し、図17(A)に示すようなオフセット関数(kx、ky)により仮位置からの距離に応じたオフセット値を加算する。図17(A)に示すオフセット関数は、仮位置でオフセット値が最大になり、仮位置から距離が離れるにつれて単調減少する関数である。オフセット関数は、上記マッチング・スコアMの取り得る値の範囲に基づいて定めればよい。図17(B)および(C)は、補正前のスコアおよび補正後のスコアを探索位置(kx/ky)でプロットしたグラフを補正前のスコアに基づくマッチング位置および補正後のスコアに基づくマッチング位置とともに示す図である。図17(B)は、特徴量が大きいテンプレート画像の場合を例示し、図17(C)は、特徴量が小さいテンプレート画像の場合を例示する。   FIG. 17A shows a graph in which the offset function for the matching score is plotted against the search position (kx / ky). In the process of step S309, an offset value corresponding to the distance from the temporary position is added to the matching score M (kx, ky) by an offset function (kx, ky) as shown in FIG. The offset function shown in FIG. 17A is a function in which the offset value becomes maximum at the provisional position and monotonically decreases as the distance from the provisional position increases. The offset function may be determined based on the range of possible values of the matching score M. FIGS. 17B and 17C show matching positions based on scores before correction and matching positions based on scores after correction, in which a graph in which scores before correction and scores after correction are plotted at search positions (kx / ky) is shown. FIG. FIG. 17B illustrates a case of a template image having a large feature amount, and FIG. 17C illustrates a case of a template image having a small feature amount.

図17(B)に示すように、オフセット補正により、最終的なマッチング・スコアは、仮位置を中心としてかさ上げされる。しかしながら、テンプレート画像の特徴量が大きい場合は、位置の変化による類似度が大きく変動するので、類似度に基づくマッチング・スコアの影響が色濃く残される。このため、オフセット補正が行われるか否かにかかわらず、概ね類似度に基づくマッチング・スコアが最大となる位置がマッチング位置として決定される。すなわち、類似度のマッチング・スコアのピークが明確に残る程度に特徴量が大きければ、類似度が優勢的につなぎ位置を決定付けることになる。   As shown in FIG. 17B, the final matching score is raised around the temporary position by the offset correction. However, when the feature amount of the template image is large, the degree of similarity greatly changes due to a change in the position, so that the effect of the matching score based on the degree of similarity remains strong. For this reason, the position where the matching score based on the similarity is maximized is determined as the matching position regardless of whether or not the offset correction is performed. In other words, if the feature amount is large enough to clearly leave the peak of the matching score of the similarity, the similarity will predominantly determine the connection position.

一方、図17(C)に示すように、テンプレート画像の特徴量が小さい場合は、通常のマッチング・スコアでは明瞭なピークが認められず、類似度に基づくマッチング・スコアよりも、仮位置からの距離に応じたオフセットの影響が色濃く反映される。このため、概ねオフセット関数が最大となる仮位置の近傍がマッチング位置として決定される。すなわち、特徴量が小さい場合は、仮位置が優勢的につなぎ位置を決定付けることになる。   On the other hand, as shown in FIG. 17 (C), when the feature amount of the template image is small, a clear peak is not recognized in the normal matching score, and the matching score based on the similarity is higher than the matching score based on the similarity. The effect of the offset according to the distance is reflected in a deep color. For this reason, the vicinity of the tentative position where the offset function is substantially maximum is determined as the matching position. That is, when the feature amount is small, the temporary position predominantly determines the connection position.

マッチング位置が決定されると、注目テンプレート画像(番号i)に対し、位置検出用補正画像0のそのままの座標値上に重ね合わせた位置からのずらし量(Δθ,Δφ)としてつなぎ位置が求められる。 When the matching position is determined, the connection position is determined as a shift amount (Δθ i , Δφ i ) from the position of the target template image (number i) superimposed on the coordinate value of the position detection correction image 0 as it is. Desired.

上述したオフセット補正を行うことにより、類似度に基づくスコアに明確なピークがあり、類似度が大きい場合はその位置がつなぎ位置となる。特徴のない場合など明確なピークがあらわれない場合は、仮位置付近がつなぎ位置となり、隣接ブロックとの連続性が保たれ、仮位置から大きく外れた位置でつなぎ位置が決定されてしまう割合を低減することができる。   By performing the above-described offset correction, there is a clear peak in the score based on the similarity, and when the similarity is large, the position becomes a connecting position. If a clear peak does not appear, such as when there is no feature, the temporary position is the connection position, maintaining continuity with the adjacent block, and reducing the rate at which the connection position is determined at a position far from the temporary position can do.

再び図12を参照すると、ステップS311では、撮像システム10は、全てのテンプレート画像のブロックに対する処理が終了しているか判定する。ステップS311で、終了していないと判定された場合(NO)は、ステップS306に戻されて、全てのブロックに対する処理が完了するまで繰り返させる。一方、ステップS311で、全ての処理が終了したと判定された場合(YES)は、ステップS312へ処理を進める。   Referring to FIG. 12 again, in step S311, the imaging system 10 determines whether the processing for all blocks of the template image has been completed. If it is determined in step S311 that the processing has not been completed (NO), the processing returns to step S306, and the processing is repeated until processing for all blocks is completed. On the other hand, if it is determined in step S311 that all the processes have been completed (YES), the process proceeds to step S312.

上述したステップS306からステップS311までの処理により、生成された複数のテンプレート画像(番号i:i=1〜#)すべてに対応したつなぎ位置(Δθ,Δφ)が求められる。ステップS312では、撮像システム10は、得られた各テンプレート画像に対応するつなぎ位置のデータ・セットに基づいて、全天球フォーマットの各画素(θ,φ)毎のつなぎ位置(Δθ,Δφ)を計算し、検出結果データ222を生成する。ステップS313では、撮像システム10は、本つなぎ位置検出処理を終了させ、図5に示す処理に戻る。 Through the processing from step S306 to step S311 described above, the connection positions (Δθ i , Δφ i ) corresponding to all of the plurality of generated template images (number i: i = 1 to #) are obtained. In step S312, the imaging system 10 determines the connection position (Δθ, Δφ) for each pixel (θ, φ) in the spherical format based on the obtained data set of the connection position corresponding to each template image. Calculate and generate detection result data 222. In step S313, the imaging system 10 terminates the main connection position detection processing, and returns to the processing illustrated in FIG.

図18は、本実施形態において、つなぎ位置検出部204により生成される検出結果データのデータ構造を示す図である。図19は、本実施形態の位置検出部204による検出結果データを生成する処理を説明する図である。上記ステップS312での処理により、図18に示すような、変換後の各座標値(θ,φ)に対して、ずらし量(Δθ,Δφ)が対応付けられた情報を全座標値について保持する検出結果データ222が得られる。このとき、各座標値(θ,φ)に対応するずらし量(Δθ,Δφ)は、上記つなぎ位置検出処理により求められたテンプレート・ブロック(i)毎のずらし量(Δθ,Δφ)を、各テンプレート・ブロックの中心座標の値として設定し、補間して計算することができる。 FIG. 18 is a diagram illustrating a data structure of detection result data generated by the connection position detection unit 204 in the present embodiment. FIG. 19 is a diagram illustrating a process of generating detection result data by the position detection unit 204 according to the present embodiment. As a result of the processing in step S312, information in which a shift amount (Δθ, Δφ) is associated with each coordinate value (θ, φ) after conversion as shown in FIG. 18 is stored for all coordinate values. Detection result data 222 is obtained. At this time, the shift amount (Δθ, Δφ) corresponding to each coordinate value (θ, φ) is the shift amount (Δθ i , Δφ i ) for each template block (i) obtained by the connection position detection processing. , Can be set as the value of the center coordinate of each template block, and can be calculated by interpolation.

具体的には、まず、図19(A)に示すように、水平方向の座標値θがテンプレート・ブロックの中心座標の値と等しく、かつ、上端(φ=0)および下端(高さが1800画素の場合は、φ=1799である。)に位置する各座標におけるずらし量(Δθ,Δφ)を(0,0)として設定する。その他のずらし量未設定の座標については、図19(B)に示すように、近傍の設定済み4点(図中A〜Dで示す。)からなる格子を考え、その中で2次元線形補間演算によりずらし量を算出する。点Qを、4点の格子においてθ軸方向にdθ:1−dθ、φ軸方向にdφ:1−dφに内分する点だとすると、点Qにおけるずらし量(Δθ,Δφ)は、近傍4点におけるずらし量((ΔθA,Δφ),…,(ΔθD,Δφ))を用いて、下記式(6)により計算することができる。 Specifically, first, as shown in FIG. 19A, the horizontal coordinate value θ is equal to the value of the center coordinate of the template block, and the upper end (φ = 0) and the lower end (having a height of 1800 In the case of a pixel, φ = 1799.), The shift amount (Δθ, Δφ) at each coordinate located is set as (0, 0). As for the other coordinates for which the shift amount is not set, as shown in FIG. 19B, a grid consisting of four nearby set points (indicated by A to D in the drawing) is considered, and two-dimensional linear interpolation is performed therein. The shift amount is calculated by calculation. Assuming that the point Q is a point that is internally divided into dθ: 1-dθ in the θ-axis direction and dφ: 1-dφ in the φ-axis direction in a four-point grid, the shift amount (Δθ Q , Δφ Q ) at the point Q Using the shift amounts ((Δθ A, Δφ A ),..., (Δθ D, Δφ D )) at the four points, it can be calculated by the following equation (6).

なお、説明する実施形態では、全天球フォーマットにおける上端(φ=0)および下端(上記例ではφ=1799)に対しずらし量(0,0)を設定するようにした。しかしながら、各座標値(θ,φ)に対応するずらし量(Δθ,Δφ)の計算方法は、特に限定されるものではない。ここでは、部分画像0,1を矛盾無くつなぎ合わせられればよいので、他の実施形態では、より内側にずらし量(0,0)とする座標を設定して上記2次元線形補間演算を行うことができる。この場合、その座標よりφ方向が外側である座標においては、全てずらし量(0,0)を設定するようにすればよい。   In the embodiment to be described, the shift amount (0, 0) is set for the upper end (φ = 0) and the lower end (φ = 1799 in the above example) in the spherical format. However, the method of calculating the shift amount (Δθ, Δφ) corresponding to each coordinate value (θ, φ) is not particularly limited. Here, it is sufficient that the partial images 0 and 1 are connected without contradiction. In other embodiments, the two-dimensional linear interpolation operation is performed by setting coordinates having a shift amount (0, 0) inward. Can be. In this case, the shift amount (0, 0) may be set for all coordinates whose φ direction is outside the coordinates.

再び図5を参照すると、ステップS203では、撮像システム10は、テーブル修正部206により、上記検出結果データ222を用いて、位置検出用変換テーブル220を画像が球面座標上で位置合わせされるように修正する。ステップS202のつなぎ位置検出処理により、図18に示すように、全天球画像フォーマットの座標値毎に、ずらし量が求まるので、ステップS203では、具体的には、部分画像0の歪み補正に用いた検出用歪み補正テーブル0において、入力座標値(θ,φ)に対し、修正前には(θ+Δθ,φ+Δφ)に対応付けられていた(x,y)を対応付けるように修正する。なお、部分画像1の歪み補正に用いた検出用歪み補正テーブル1については対応付けを変える必要はない。   Referring again to FIG. 5, in step S <b> 203, the imaging system 10 causes the table correction unit 206 to position the conversion table 220 for position detection on the spherical coordinates using the detection result data 222. Fix it. As shown in FIG. 18, the shift amount is obtained for each coordinate value in the omnidirectional image format by the connection position detection processing in step S202. Therefore, in step S203, the shift amount is used specifically for distortion correction of the partial image 0. In the detection distortion correction table 0, the input coordinate value (θ, φ) is corrected so as to correspond to (x, y) that was previously associated with (θ + Δθ, φ + Δφ). Note that it is not necessary to change the correspondence of the detection distortion correction table 1 used for distortion correction of the partial image 1.

ステップS204では、撮像システム10は、テーブル生成部208により、修正された位置検出用変換テーブル220から、回転座標変換することによって、画像合成用変換テーブル224を生成する。   In step S204, the imaging system 10 generates the image synthesis conversion table 224 by performing the rotation coordinate conversion from the corrected position detection conversion table 220 by the table generation unit 208.

図20は、本実施形態による撮像システム10が実行する、画像合成用変換テーブルの生成処理を示すフローチャートである。図21は、画像合成処理の際における、2つの魚眼レンズで撮像された2つの部分画像の球面座標系へのマッピングを説明する図である。図20に示す処理は、図5に示したステップS204で呼び出されて、ステップS400から開始する。ステップS401〜ステップS406のループでは、テーブル生成部208は、画像合成用歪み補正テーブルの入力値となる画像合成用の球面座標系の座標値(θ,φ)毎に、ステップS402〜S405の処理を実行する。設定される座標値の範囲は、水平角度の全範囲(0〜360度)および垂直角度の全範囲(0〜180度)で定義される範囲となる。入力値になる全座標値について変換処理を行うため、ここで各座標値が順に設定される。 FIG. 20 is a flowchart illustrating a process of generating an image synthesis conversion table, which is executed by the imaging system 10 according to the present embodiment. FIG. 21 is a diagram illustrating mapping of two partial images captured by two fisheye lenses to a spherical coordinate system in the image synthesis processing. The process illustrated in FIG. 20 is called in step S204 illustrated in FIG. 5 and starts from step S400. In the loop of steps S401 to S406, the table generation unit 208 performs steps S402 to S405 for each coordinate value (θ g , φ g ) of the spherical coordinate system for image synthesis that is an input value of the distortion correction table for image synthesis. Execute the processing of The range of the set coordinate values is a range defined by the entire range of the horizontal angle (0 to 360 degrees) and the entire range of the vertical angle (0 to 180 degrees). Since the conversion process is performed for all coordinate values that are input values, each coordinate value is set here in order.

ステップS402では、テーブル生成部208は、回転座標変換により、上記座標値(θg,φ)に対応する、つなぎ位置検出用の球面座標系の座標値(θ,φ)を求める。回転座標変換により、図9に示すような、一方のレンズ光学系の光軸を軸とした水平角度θおよび垂直角度φの座標軸の定義から、図21に示すような、光軸に垂直な軸を基準とした水平角度θおよび垂直角度φの定義に変換される。上記座標(θg,φ)に対応する座標(θ,φ)は、回転座標変換に基づき、動径を1とし、画像合成用の球面座標系の座標(θg,φ)に対応する3次元直交座標(x,y,z)および位置検出用の球面座標系の座標(θd,φ)に対応する3次元直交座標(x,y,z)を用いて、下記式(7)で計算することができる。なお、下記式(7)中、係数βは、3次元直交座標におけるx軸周りの回転座標変換を規定する回転角であり、説明する実施形態では、90度である。 In step S402, the table generation unit 208 obtains the coordinate values (θ d , φ d ) of the spherical coordinate system for detecting the connection position corresponding to the coordinate values (θ g, φ g ) by the rotation coordinate conversion. By the rotation coordinate conversion, the definition of the coordinate axes of the horizontal angle θ d and the vertical angle φ d around the optical axis of one lens optical system as shown in FIG. Is converted into the definition of the horizontal angle θ g and the vertical angle φ g with respect to the basic axis. Coordinates (θ d , φ d ) corresponding to the above coordinates (θ g, φ g ) are set to a radius of 1 based on rotational coordinate conversion, and coordinates (θ g, φ g ) of a spherical coordinate system for image synthesis. three-dimensional orthogonal coordinate corresponding to (x g, y g, z g) and the spherical coordinate system coordinates of the position detection (θ d, φ d) 3-dimensional orthogonal coordinate corresponding to (x d, y d, z d ) Can be calculated by the following equation (7). In the following equation (7), the coefficient β is a rotation angle that defines a rotation coordinate transformation around the x-axis in the three-dimensional orthogonal coordinates, and is 90 degrees in the embodiment to be described.

位置検出用変換テーブル220では、光軸が球面の極に、画像間の重複部分が球面の赤道近傍に射影され、全天球画像フォーマットの上下方向と、撮影されたシーンの天頂方向が一致していない。これに対して、上記回転座標変換により、画像合成用変換テーブル224では、光軸が球面の赤道上に射影され、全天球画像フォーマットの上下方向と、撮影されたシーンの天頂方向とが一致するようになる。   In the position detection conversion table 220, the optical axis is projected to the pole of the spherical surface, and the overlapping portion between the images is projected near the equator of the spherical surface, so that the vertical direction of the spherical image format and the zenith direction of the shot scene match. Not. On the other hand, in the image synthesizing conversion table 224, the optical axis is projected onto the spherical equator by the above-described rotational coordinate conversion, and the vertical direction of the omnidirectional image format matches the zenith direction of the captured scene. I will be.

ステップS403〜ステップS405のループでは、画像0および画像1毎に、テーブル生成部208は、ステップS404の処理を実行する。ステップS404では、テーブル生成部208は、各画像(0,1)について、(θ,φ)に対応付けられる部分画像(0,1)の座標値(x,y)を、修正後のつなぎ位置検出用変換テーブルを参照して求める。なお、変換テーブル220,224は、θおよびφ共に、1画素きざみで対応する座標値(x,y)を保持しているが、変換により算出される座標値(θ,φ)は、典型的には、小数点以下の値で取得される。簡便には、対応付けられる部分画像(0,1)の座標値(x,y)は、算出された座標値(θ,φ)の最近傍のテーブル中に存在する座標値に対応付けられる座標値(x,y)を採用することができる。また、好適な実施形態では、テーブルに存在するうち、最近傍の座標値およびその周囲の座標値に対応付けられる複数の座標値(x,y)を参照して、算出された座標(θ,φ)からの距離に応じて重み付け補間を行って、対応付けられる部分画像(0,1)の座標値(x,y)を計算することもできる。 In the loop from step S403 to step S405, the table generation unit 208 executes the processing of step S404 for each of the image 0 and the image 1. In step S404, the table generating unit 208 corrects the coordinate value (x, y) of the partial image (0, 1) associated with (θ d , φ d ) for each image (0, 1) after the correction. It is determined by referring to the conversion table for connection position detection. Although the conversion tables 220 and 224 hold the coordinate values (x, y) corresponding to one pixel at a time for both θ d and φ d , the coordinate values (θ d , φ d ) calculated by the conversion are stored. Is typically obtained as a value after the decimal point. For simplicity, the coordinate value (x, y) of the associated partial image (0, 1) is associated with the coordinate value existing in the table closest to the calculated coordinate value (θ d , φ d ). (X, y) can be adopted. In a preferred embodiment, the coordinates (θ d ) calculated by referring to a plurality of coordinate values (x, y) associated with the nearest coordinate value and surrounding coordinate values among the table values are stored in the table. , Φ d ), the coordinate value (x, y) of the associated partial image (0, 1) can be calculated by performing weighted interpolation according to the distance from the partial image (0, 1).

ステップS403〜ステップS405のループで、すべての画像(0,1)について計算が行われ、ステップS402〜ステップS406のループで、入力値となるすべての座標値に対する計算が完了すると、ステップS407では、本処理を終了させる。これにより、画像合成用変換テーブル224の全データが生成される。   In the loop of steps S403 to S405, the calculation is performed for all the images (0, 1). In the loop of steps S402 to S406, when the calculation for all the coordinate values to be input values is completed, in step S407, This processing ends. Thereby, all the data of the conversion table for image synthesis 224 is generated.

再び図5を参照すると、ステップS205では、撮像システム10は、画像合成用歪み補正部210により、画像合成用変換テーブル224を用いて、元の部分画像0および部分画像1に対し歪み補正を行い、画像合成用補正画像0および画像合成用補正画像1を得る。これにより、画像合成用歪み補正部210による処理の結果、魚眼レンズで撮像された2つの部分画像0,1は、図21に示すように、全天球画像フォーマット上に展開される。魚眼レンズ0により撮影された部分画像0は、典型的には、全天球のうちの概ね左半球にマッピングされ、魚眼レンズ1により撮影された部分画像1は、全天球のうちの概ね右半球にマッピングされる。   Referring to FIG. 5 again, in step S205, the imaging system 10 performs distortion correction on the original partial image 0 and the partial image 1 by the image combining distortion correction unit 210 using the image combining conversion table 224. Then, the corrected image for image synthesis 0 and the corrected image for image synthesis 1 are obtained. As a result, as a result of the processing performed by the image-combining distortion correction unit 210, the two partial images 0 and 1 captured by the fisheye lens are developed in a spherical image format as shown in FIG. The partial image 0 captured by the fisheye lens 0 is typically mapped to the approximately left hemisphere of the whole celestial sphere, and the partial image 1 captured by the fisheye lens 1 is typically mapped to the right hemisphere of the celestial sphere. Is mapped.

図9および図21を比較すると明確であるが、全天球フォーマットに対し、異なった位置に部分画像0および部分画像1がマッピングされており、シーンの天頂方向が画像の上下方向となるφ方向に一致している。部分画像0,1の中心部が、より歪みの少ない赤道上にマッピングされ、補正画像0および補正画像1間の重複領域は、図9に示したものと異なり、垂直角度0度および180度付近、並びに、水平角度0度および180度の近傍領域にマッピングされる。   9 and FIG. 21, it is clear that the partial image 0 and the partial image 1 are mapped to different positions in the spherical format, and the zenith direction of the scene is the vertical direction of the image. Matches. The center of the partial images 0 and 1 is mapped on the equator with less distortion, and the overlapping area between the corrected image 0 and the corrected image 1 differs from that shown in FIG. , And in the vicinity of horizontal angles of 0 and 180 degrees.

ステップS206では、画像合成部212により、画像合成用補正画像0および画像合成用補正画像1を合成する。合成処理では、画像間で重複する重複領域については、ブレンド処理等が行われ、片方しか画素値が存在しない領域については、存在するそのままの画素値が採用されることになる。上記合成処理により、魚眼レンズにより撮像された2枚の部分画像から、1枚の全天球画像が生成される。   In step S206, the image combining unit 212 combines the image combining corrected image 0 and the image combining corrected image 1. In the synthesizing process, a blending process or the like is performed on an overlapping region that overlaps between images, and an existing pixel value is used for a region where only one of the pixel values exists. Through the synthesis processing, one celestial sphere image is generated from the two partial images captured by the fisheye lens.

以上説明したように、本実施形態では、マッチングを行う対象となるテンプレート画像が有する特徴の程度を指標する特徴量を測定し、この測定された特徴量を用いて、テンプレート画像のつなぎ位置を決定している。そして、特徴の大きな領域で優先してつなぎ合わせが行われ、そのつなぎ位置を参考にして特徴のより小さな領域のつなぎ合わせが行われる。これにより、画像が平坦であったり、同じ模様が繰り返された領域であったりして特徴が少ない領域に対しても、精度高くつなぎ位置を検出することができ、ひいては、得られる全天球画像の品質が向上される。また、同じ模様が繰り返された場合のように、類似度にだけでは複数のつなぎ位置の候補が存在するような場合でも、隣接した特徴がある領域のつなぎ位置を参考に一意につなぎ位置を決定することができる。   As described above, in the present embodiment, the feature amount indicating the degree of the feature of the template image to be matched is measured, and the joint position of the template image is determined using the measured feature amount. are doing. Then, the connection is preferentially performed in the region with the large feature, and the connection with the smaller feature is performed with reference to the connection position. This makes it possible to detect the connection position with high accuracy even in an area where the image is flat or an area in which the same pattern is repeated and has few features such as an area where the same pattern is repeated. The quality is improved. Even when the same pattern is repeated, such as when there are a plurality of connection position candidates only based on similarity, a unique connection position is determined by referring to a connection position of an area having adjacent features. can do.

さらに、特徴の少ない不適切なマッチング領域を除外して計算する処理を採用しないので、アルゴリズムの簡素化が図られる。また、全天球撮像システム10では、全方位が撮影範囲となるため、重複領域に空などの平坦で特徴が少なくつなぎ合わせに適切ではない領域が広く含まれるシーンが多々発生する。本実施形態による複数の画像のつなぎ合わせ処理は、このような性質を有する全天球画像のつなぎ合わせに対し、好適に適用することができる。   Further, since a process of calculating by excluding an inappropriate matching region having a small number of features is not employed, the algorithm can be simplified. Further, in the omnidirectional imaging system 10, since the omnidirectional image is the shooting range, many scenes are generated in which the overlapping region widely includes a flat region such as the sky, which has few features and is not suitable for joining. The joining processing of a plurality of images according to the present embodiment can be suitably applied to the joining of omnidirectional images having such properties.

[他の実施形態]
上述した実施形態では、画像処理装置および撮像システムの一例として、全天球の静止画を自身が備える撮像光学系により撮影し、内部の歪曲補正・画像合成ブロックで合成する撮像システム10を用いて説明した。しかしながら、画像処理装置および撮像システムの構成は、特に限定されるものではない。他の実施形態では、全天球を動画撮影する全天球動画撮像システムとして構成してもよく、複数の撮像光学系で撮影された複数の部分画像(静止画または動画)の入力を受けて全天球画像(静止画または動画)を生成するカメラ・プロセッサ、撮影を専ら担当する全天球撮像装置で撮影された複数の部分画像(静止画または動画)の入力を受けて全天球画像(静止画または動画)を合成するパーソナル・コンピュータ、ワークステーション、物理コンピュータ・システム上の仮想マシンなどの情報処理装置、スマートフォン、タブレットなどの携帯情報端末などを上記画像処理装置として構成することもできる。また、上述したようなカメラ・プロセッサ、情報処理装置、携帯情報端などの画像処理装置と、該画像処理装置から分離された撮像光学系とを含む撮像システムとして構成してもよい。
[Other embodiments]
In the above-described embodiment, as an example of the image processing apparatus and the imaging system, the imaging system 10 that captures a still image of the celestial sphere by an imaging optical system provided therein and combines the captured images with an internal distortion correction / image synthesis block is used. explained. However, the configurations of the image processing device and the imaging system are not particularly limited. In another embodiment, the present invention may be configured as a celestial sphere moving image capturing system that captures moving images of the celestial sphere, and receives a plurality of partial images (still images or moving images) captured by a plurality of imaging optical systems. A camera processor that generates a spherical image (still image or moving image), and receives a plurality of partial images (still image or moving image) captured by a spherical imaging device that is in charge of shooting, and a spherical image An information processing device such as a personal computer, a workstation, or a virtual machine on a physical computer system that synthesizes (still image or moving image), a portable information terminal such as a smartphone or a tablet, or the like can also be configured as the image processing device. . Further, the image processing apparatus may be configured as an imaging system including an image processing apparatus such as a camera processor, an information processing apparatus, and a portable information terminal as described above, and an imaging optical system separated from the image processing apparatus.

以下、図22および図23を参照しながら、全天球撮像装置と、この全天球撮像装置で撮影された複数の部分画像の入力を受けて、合成された全天球画像を生成する外部のコンピュータ装置とを含む、他の実施形態における全天球撮像システムについて説明する。図22は、他の実施形態における全天球撮像システム400の概略を示す。   Hereinafter, referring to FIG. 22 and FIG. 23, an omnidirectional imaging device and an external device that receives a plurality of partial images captured by the omnidirectional imaging device and generates a combined omnidirectional image will be described. A celestial sphere imaging system according to another embodiment including the above computer device will be described. FIG. 22 schematically shows a spherical imaging system 400 according to another embodiment.

図22に示す実施形態による全天球撮像システム400は、専ら撮像を担当する全天球撮像装置410と、この全天球撮像装置410と接続され、専ら画像処理を担当するコンピュータ装置430とを含み構成される。なお、図22には、主要な構成のみが示されており、詳細な構成が省略させていることに留意されたい。また、図1〜図21を参照して説明した実施形態と同様のはたらきをする構成要素については、同一符番を付して参照する。また、図22および図23に示す実施形態による全天球撮像システム400は、全天球画像を合成する画像処理が専らコンピュータ装置430で行われることを除いて、図1〜図21を参照して説明した実施形態と同様の構成を備えるので、以下、相違点を中心に説明する。   The omnidirectional imaging system 400 according to the embodiment shown in FIG. 22 includes an omnidirectional imaging device 410 that is exclusively responsible for imaging, and a computer device 430 connected to the omnidirectional imaging device 410 and exclusively responsible for image processing. It is comprised including. Note that FIG. 22 shows only a main configuration, and a detailed configuration is omitted. In addition, components having the same functions as those in the embodiment described with reference to FIGS. 1 to 21 are denoted by the same reference numerals. Also, the omnidirectional imaging system 400 according to the embodiment shown in FIGS. 22 and 23 will be described with reference to FIGS. 1 to 21 except that the image processing for synthesizing the omnidirectional image is performed exclusively by the computer device 430. Since the configuration similar to that of the embodiment described above is provided, the following description will focus on the differences.

図22に示す実施形態において、全天球撮像装置410は、デジタル・スチルカメラ・プロセッサ100と、鏡胴ユニット102と、プロセッサ100に接続される3軸加速度センサ120とを含む。鏡胴ユニット102は、図2に示したものと同様の構成を有するものであり、プロセッサ100も、図2に示したものと同様の構成を有するものである。   In the embodiment shown in FIG. 22, the omnidirectional imaging device 410 includes a digital still camera processor 100, a lens barrel unit 102, and a three-axis acceleration sensor 120 connected to the processor 100. The lens barrel unit 102 has the same configuration as that shown in FIG. 2, and the processor 100 also has the same configuration as that shown in FIG.

プロセッサ100は、ISP108と、USBブロック146と、シリアルブロック158とを含み、USBコネクタ148を介して接続されるコンピュータ装置430とのUSB通信を制御する。シリアルブロック158には、無線NIC160が接続されており、ネットワークを介して接続されるコンピュータ装置430との無線通信を制御している。   The processor 100 includes an ISP 108, a USB block 146, and a serial block 158, and controls USB communication with a computer device 430 connected via a USB connector 148. The wireless NIC 160 is connected to the serial block 158, and controls wireless communication with a computer device 430 connected via a network.

図22に示すコンピュータ装置430は、デスクトップ型のパーソナル・コンピュータ、ワークステーションなどの汎用コンピュータなどとして構成することができる。コンピュータ装置430は、プロセッサ、メモリ、ROM、ストレージなどのハードウェア・コンポーネントを備える。図22に示す実施形態において、コンピュータ装置430は、USBインタフェース432と、無線NIC434とを含み、USBバスまたはネットワークを介して、全天球撮像装置410と接続されている。   The computer device 430 illustrated in FIG. 22 can be configured as a desktop personal computer, a general-purpose computer such as a workstation, or the like. The computing device 430 includes hardware components such as a processor, memory, ROM, storage, and the like. In the embodiment shown in FIG. 22, the computer device 430 includes a USB interface 432 and a wireless NIC 434, and is connected to the omnidirectional imaging device 410 via a USB bus or a network.

コンピュータ装置430は、さらに、画像合成にかかる処理ブロックとして、位置検出用歪み補正部202と、つなぎ位置検出部204と、テーブル修正部206と、テーブル生成部208と、画像合成用歪み補正部210と、画像合成部212とを含み構成される。本実施形態では、鏡胴ユニット102の複数の撮像光学系により撮像された2つの部分画像と、全天球撮像装置410の位置検出用変換テーブルとが、USBバスまたはネットワークを介して外部のコンピュータ装置430に転送される。   The computer 430 further includes, as processing blocks for image synthesis, a position detection distortion correction unit 202, a connection position detection unit 204, a table correction unit 206, a table generation unit 208, and an image synthesis distortion correction unit 210. And an image synthesizing unit 212. In the present embodiment, the two partial images captured by the plurality of imaging optical systems of the lens barrel unit 102 and the conversion table for position detection of the omnidirectional imaging device 410 are connected to an external computer via a USB bus or a network. Transferred to device 430.

コンピュータ装置430において、位置検出用歪み補正部202は、全天球撮像装置410から転送された部分画像0,1に対し、併せて転送された位置検出用変換テーブルを用いて歪み補正を施し、位置検出用補正画像0,1を生成する。つなぎ位置検出部204は、変換された補正画像0,1間のつなぎ位置を検出し、検出結果データを生成する。テーブル修正部206は、検出結果データに基づいて、転送された位置検出用変換テーブルに対して修正を施す。テーブル生成部208は、修正された変換データから、回転座標変換を施し、画像合成用変換テーブルを生成する。   In the computer device 430, the position detection distortion correction unit 202 performs distortion correction on the partial images 0 and 1 transferred from the omnidirectional imaging device 410 using the position detection conversion table transferred together. The correction images 0 and 1 for position detection are generated. The connection position detection unit 204 detects a connection position between the converted corrected images 0 and 1 and generates detection result data. The table correction unit 206 corrects the transferred position detection conversion table based on the detection result data. The table generation unit 208 performs rotation coordinate conversion from the corrected conversion data, and generates an image synthesis conversion table.

画像合成用歪み補正部210は、画像合成処理の前段の処理として、元の部分画像0および部分画像1に対し、画像合成用変換テーブルを用いて歪み補正をかけ、画像合成用補正画像0,1を生成する。画像合成部212は、得られた画像合成用補正画像0,1を合成し、全天球画像フォーマットの合成画像を生成する。   The image-combination distortion correction unit 210 performs distortion correction on the original partial image 0 and the partial image 1 using the image-synthesis conversion table as a process preceding the image synthesis process, and 1 is generated. The image synthesizing unit 212 synthesizes the obtained image synthesizing corrected images 0 and 1 to generate a synthetic image in a spherical image format.

図22に示す機能ブロックは、さらに、表示画像生成部214を含むことができる。表示画像生成部214は、全天球画像を平面表示デバイスに投影するための画像処理を実行する。本実施形態によるコンピュータ装置430は、ROMやHDDなどからプログラムを読み出し、RAMが提供する作業空間に展開することにより、CPUの制御の下、上述した各機能部および以下後述する各処理を実現する。   The functional block illustrated in FIG. 22 can further include a display image generation unit 214. The display image generation unit 214 performs image processing for projecting the spherical image on the flat display device. The computer device 430 according to the present embodiment reads out a program from a ROM, an HDD, or the like, and develops the program in a work space provided by the RAM, thereby implementing the above-described functional units and the processes described below under the control of the CPU. .

図23は、他の実施形態における全天球撮像システム400における全天球画像合成処理の全体的な流れを示すフローチャート図である。図23には、全天球撮像装置410で撮像画像が入力された後、当該画像がコンピュータ装置430で保存されるまでの流れが説明されている。   FIG. 23 is a flowchart illustrating an overall flow of a celestial sphere image combining process in the celestial sphere imaging system 400 according to another embodiment. FIG. 23 illustrates a flow from when a captured image is input by the omnidirectional imaging device 410 to when the image is stored in the computer device 430.

図23に示す処理は、例えば、全天球撮像装置410でシャッター・ボタンの押下により2つの撮像光学系で撮影が指示されたことに応答して、ステップS500から開始される。まず、全天球撮像装置410内での処理が実行される。   The process illustrated in FIG. 23 is started from step S500, for example, in response to an instruction to shoot with the two imaging optical systems by pressing the shutter button on the omnidirectional imaging device 410. First, processing in the omnidirectional imaging device 410 is performed.

ステップS501では、全天球撮像装置410は、2つの固体撮像素子22A,22Bによって部分画像0および部分画像1を撮影する。ステップS502では、全天球撮像装置410は、USBバスあるいはネットワークを介して、部分画像0および部分画像0をコンピュータ装置430へ転送する。併せて、上記位置検出用変換テーブルが、USBバスあるいはネットワークを介してコンピュータ装置430に転送される。このとき、傾き補正もコンピュータ装置430側で行われる場合は、3軸加速度センサ120で取得された傾き情報がコンピュータ装置430へ転送される。   In step S501, the celestial sphere imaging device 410 captures a partial image 0 and a partial image 1 using the two solid-state imaging devices 22A and 22B. In step S502, the omnidirectional imaging device 410 transfers the partial image 0 and the partial image 0 to the computer device 430 via a USB bus or a network. At the same time, the conversion table for position detection is transferred to the computer device 430 via a USB bus or a network. At this time, when the tilt correction is also performed on the computer device 430 side, the tilt information acquired by the three-axis acceleration sensor 120 is transferred to the computer device 430.

なお、上述した全天球撮像装置410の位置検出用変換テーブルは、全天球撮像装置410とコンピュータ装置430との間で互いに認識し合った際に転送しておいておけばよい。つまり、位置検出用変換テーブルは、一度、コンピュータ装置430に転送されていれば充分であり、毎回、変換テーブルを転送することを要さない。位置検出用変換テーブルは、例えば、図示しないSDRAMなどに記憶されており、ここから読み出され、転送される。ここまでが、全天球撮像装置410内における処理であり、次のステップS503からは、転送先のコンピュータ装置430内において実行される処理である。   The above-described conversion table for position detection of the omnidirectional imaging device 410 may be transferred when the omnidirectional imaging device 410 and the computer device 430 recognize each other. That is, it is sufficient that the conversion table for position detection has been transferred to the computer device 430 once, and it is not necessary to transfer the conversion table every time. The conversion table for position detection is stored in, for example, an SDRAM (not shown) or the like, and is read therefrom and transferred. The processing up to this point is the processing in the omnidirectional imaging device 410, and the processing from the next step S503 is executed in the computer 430 of the transfer destination.

ステップS503では、コンピュータ装置430は、位置検出用歪み補正部202により、転送された部分画像0および部分画像1に対し、転送された位置検出用変換テーブルを用いて歪み補正を行い、位置検出用補正画像0,1を得る。このとき、傾き補正が転送先コンピュータ装置430側で行われる場合は、転送された傾き情報に基づき、位置検出用変換テーブルに対し鉛直方向に応じた補正が事前に行われてもよい。ステップS504では、コンピュータ装置430は、つなぎ位置検出部204により、位置検出用補正画像0,1の重複領域において、画像間のつなぎ位置検出を行い、検出結果データを得る。ステップS505では、コンピュータ装置430は、テーブル修正部206により、検出結果データを用いて、転送された位置検出用変換テーブルを、画像が球面座標上で位置合わせされるように修正する。ステップS506では、コンピュータ装置430は、テーブル生成部208により、修正された位置検出用変換テーブルから、回転座標変換することによって、画像合成用変換テーブルを生成する。   In step S503, the computer device 430 performs distortion correction on the transferred partial image 0 and partial image 1 using the transferred position detection conversion table by the position detection distortion correction unit 202, and The corrected images 0 and 1 are obtained. At this time, when the inclination correction is performed on the transfer destination computer device 430 side, the correction corresponding to the vertical direction may be performed in advance on the position detection conversion table based on the transferred inclination information. In step S504, the computer device 430 performs the connection position detection between the images in the overlap region of the position detection corrected images 0 and 1 by the connection position detection unit 204 to obtain detection result data. In step S505, the computer 430 corrects the transferred position detection conversion table using the detection result data by the table correction unit 206 so that the image is aligned on spherical coordinates. In step S506, the computer device 430 generates an image synthesis conversion table by performing rotation coordinate conversion from the corrected position detection conversion table by the table generation unit 208.

ステップS507では、コンピュータ装置430は、画像合成用歪み補正部210により、画像合成用変換テーブルを用いて、元の部分画像0,1に対し歪み補正を行い、画像合成用補正画像0,1を得る。ステップS508では、コンピュータ装置430は、画像合成部212により、画像合成用補正画像0,1を合成する。上記合成処理により、魚眼レンズにより撮像された2枚の部分画像から、1枚の全天球画像が生成される。そして、ステップS509では、コンピュータ装置430は、ステップS508で生成された全天球画像を外部ストレージに保存し、ステップS510で終了する。   In step S507, the computer device 430 performs distortion correction on the original partial images 0 and 1 by using the image synthesis conversion table by the image synthesis distortion correction unit 210, and converts the image synthesis corrected images 0 and 1 to each other. obtain. In step S508, the computer device 430 combines the corrected images for image combination 0 and 1 by the image combining unit 212. Through the synthesis processing, one celestial sphere image is generated from the two partial images captured by the fisheye lens. Then, in step S509, the computer device 430 saves the spherical image generated in step S508 in the external storage, and ends in step S510.

なお、図23に示した他の実施形態におけるフローチャートにかかる動作も、コンピュータ上のプログラムに実行させることができる。すなわち、全天球撮像装置410の動作を制御するCPU、コンピュータ装置430の動作を制御するCPUが、それぞれ、ROM、RAMなどの記憶媒体に格納されたプログラムを読み出し、メモリ上に展開することにより、上述した全天球画像合成処理の各担当部分の処理を実現する。なお、図22および図23は、分離して構成された全天球画像撮像システムを例示するものであり、図22および図23に示した具体的な実施形態に限定されるものではない。全天球画像撮像システムを実現するための各機能部は、1以上の撮像装置、1以上のコンピュータ・システム上に種々の態様で分散実装することができる。   The operation according to the flowchart in the other embodiment shown in FIG. 23 can also be executed by a program on a computer. That is, the CPU that controls the operation of the celestial sphere imaging device 410 and the CPU that controls the operation of the computer device 430 read programs stored in storage media such as ROM and RAM, respectively, and load the programs on the memory. Thus, the processing of each part in charge of the omnidirectional image synthesis processing described above is realized. FIGS. 22 and 23 illustrate the omnidirectional image capturing system configured separately, and are not limited to the specific embodiments illustrated in FIGS. 22 and 23. Each functional unit for realizing the omnidirectional imaging system can be distributedly mounted in one or more imaging devices and one or more computer systems in various modes.

以上説明した実施形態によれば、複数の入力画像間でつなぎ位置を検出する場合に、入力画像の特徴が少ない部分領域に対しても適切なつなぎ位置を検出することが可能な画像処理装置、画像処理方法、プログラムおよび撮像システムを提供することができる。   According to the embodiment described above, when detecting a connection position between a plurality of input images, an image processing apparatus capable of detecting an appropriate connection position even for a partial region having a small feature of the input image, An image processing method, a program, and an imaging system can be provided.

なお、上述した実施形態では、複数の部分画像は、それぞれ、異なるレンズ光学系を用いて略同時に撮像されたものとしたが、他の実施形態では、同じレンズ光学系を用い、時を異にして、所定の撮影点から、異なる撮影方向(方位)を向いて撮影撮像された複数の部分画像の重ね合わせに適用してもよい。さらに、上述した実施形態では、180度より大きな画角を有するレンズ光学系で撮像された2つの部分画像を重ね合わせて合成するものとしたが、他の実施形態では、1または複数のレンズ光学系により撮像された3以上の部分画像の重ね合わせ合成に適用してもよい。また、上述した実施形態では、魚眼レンズを用いた撮像システムを一例に説明してきたが、超広角レンズを用いた全天球撮像システムに適用してもよい。さらに、上述した好適な実施形態では、全天球画像の重ね合わせについて説明したが、特に限定されるものではなく、複数の画像のつなぎ位置を検出するいかなる画像処理に適用可能であることは言うまでもない。   Note that, in the above-described embodiment, the plurality of partial images are each taken at substantially the same time using different lens optical systems. However, in other embodiments, the same lens optical system is used, and at different times. In addition, the present invention may be applied to the superposition of a plurality of partial images photographed and taken in different photographing directions (azimuths) from a predetermined photographing point. Furthermore, in the above-described embodiment, two partial images captured by a lens optical system having an angle of view greater than 180 degrees are superimposed and synthesized, but in other embodiments, one or more lens optical systems are used. The present invention may be applied to superposition synthesis of three or more partial images captured by the system. In the above-described embodiment, an imaging system using a fish-eye lens has been described as an example. However, the invention may be applied to a spherical imaging system using an ultra-wide-angle lens. Furthermore, in the preferred embodiment described above, superposition of omnidirectional images has been described. However, the present invention is not particularly limited to this, and it is needless to say that the present invention can be applied to any image processing for detecting a connection position of a plurality of images. No.

また、上記機能部は、アセンブラ、C、C++、C#、Java(登録商標)などのレガシープログラミング言語やオブジェクト指向プログラミング言語などで記述されたコンピュータ実行可能なプログラムにより実現でき、ROM、EEPROM、EPROM、フラッシュメモリ、フレキシブルディスク、CD−ROM、CD−RW、DVD−ROM、DVD−RAM、DVD−RW、ブルーレイディスク、SDカード、MOなど装置可読な記録媒体に格納して、あるいは電気通信回線を通じて頒布することができる。また、上記機能部の一部または全部は、例えばフィールド・プログラマブル・ゲート・アレイ(FPGA)などのプログラマブル・デバイス(PD)上に実装することができ、あるいはASIC(特定用途向集積)として実装することができ、上記機能部をPD上に実現するためにPDにダウンロードする回路構成データ(ビットストリームデータ)、回路構成データを生成するためのHDL(Hardware Description Language)、VHDL(Very High Speed Integrated Circuits Hardware Description Language)、Verilog−HDLなどにより記述されたデータとして記録媒体により配布することができる。   The functional unit can be realized by a computer-executable program written in a legacy programming language such as assembler, C, C ++, C #, Java (registered trademark), or an object-oriented programming language. ROM, EEPROM, EPROM , Flash memory, flexible disk, CD-ROM, CD-RW, DVD-ROM, DVD-RAM, DVD-RW, Blu-ray disk, SD card, MO, etc., stored in a readable recording medium, or through an electric communication line Can be distributed. Further, a part or all of the functional units can be mounted on a programmable device (PD) such as a field programmable gate array (FPGA), or is mounted as an ASIC (integrated for a specific application). Circuit configuration data (bit stream data) to be downloaded to the PD in order to realize the functional unit on the PD, HDL (Hardware Description Language) for generating the circuit configuration data, and VHDL (Very High Speed Integrated Circuits). Hardware description language), Verilog-HDL, and the like can be distributed on a recording medium as data.

これまで本発明の実施形態について説明してきたが、本発明の実施形態は上述した実施形態に限定されるものではなく、他の実施形態、追加、変更、削除など、当業者が想到することができる範囲内で変更することができ、いずれの態様においても本発明の作用・効果を奏する限り、本発明の範囲に含まれるものである。   Although the embodiments of the present invention have been described above, the embodiments of the present invention are not limited to the above-described embodiments, and other embodiments, additions, modifications, deletions, and the like may be made by those skilled in the art. Modifications can be made within the range that can be made, and any aspect is included in the scope of the present invention as long as the functions and effects of the present invention are exhibited.

(付記)
(付記1)
複数の入力画像間のつなぎ位置を検出するための画像処理装置であって、
第1の入力画像から、それぞれ第2の入力画像内で探索する対象となる複数の対象画像を生成する対象画像生成手段と、
前記複数の対象画像各々に対し、特徴量を算出する特徴量算出手段と、
前記複数の対象画像の注目する注目対象画像に対し、該注目対象画像よりも特徴量が大きな周辺の他の対象画像のつなぎ位置に基づいて前記注目対象画像の前記第2の入力画像へのつなぎ位置を検出するつなぎ位置検出手段と
を含む、画像処理装置。
(付記2)
前記注目対象画像に対し、前記注目対象画像と1以上の周辺の対象画像各々との間の特徴量の相対的な関係に基づいて、仮位置を算出する仮位置算出手段と、
前記注目対象画像に対し、前記仮位置算出手段により算出された仮位置に基づいて、前記注目対象画像と、前記第2の入力画像の部分とのマッチングを計算するマッチング計算手段と
を含む、付記1に記載の画像処理装置。
(付記3)
前記複数の対象画像に対する処理を前記特徴量に基づいて順位付けて、前記特徴量の相対的な関係を規定する処理順位付け手段をさらに含み、前記仮位置算出手段は、前記注目対象画像よりも特徴量の大きな周辺の対象画像の決定済みのつなぎ位置と、前記注目対象画像よりも特徴量の小さな周辺の対象画像の初期つなぎ位置とを用いて、前記注目対象画像に対する前記仮位置を算出することを特徴とする、付記2に記載の画像処理装置。
(付記4)
前記仮位置算出手段は、前記注目対象画像に対する1以上の周辺の対象画像各々の特徴量の相対的な関係に応じた重み付けおよび前記注目対象画像からの1以上の周辺の対象画像各々の距離に応じた重み付けの両方または一方の重み付けを行って、前記注目対象画像に対する前記仮位置を算出することを特徴とする、付記2または3に記載の画像処理装置。
(付記5)
前記マッチング計算手段により算出された類似度に基づく評価値を、仮位置を中心に優先されるように補正する評価値補正手段をさらに含む、付記2〜4のいずれか1つに記載の画像処理装置。
(付記6)
前記注目対象画像と1以上の周辺の対象画像各々との間の特徴量の相対的な関係に基づいた前記第2の入力画像内の前記マッチングでの探索範囲を設定する探索範囲設定手段をさらに含む、付記2〜5のいずれか1つに記載の画像処理装置。
(付記7)
複数の入力画像を合成する画像処理装置であって、
第1の入力画像における複数の対象画像の特徴量を取得する特徴量取得手段と、
前記複数の対象画像のうち注目する注目対象画像において、該注目対象画像よりも特徴量が大きな他の対象画像の第2の入力画像に対するつなぎ位置を使って検出されたつなぎ位置で前記第1の入力画像と、前記第2の入力画像とを合成する合成手段と
を備えたことを特徴とする、画像処理装置。
(付記8)
複数の入力画像間のつなぎ位置を検出するための画像処理方法であって、コンピュータが、
第1の入力画像から、それぞれ第2の入力画像内で探索する対象となる複数の対象画像を生成するステップと、
前記複数の対象画像各々に対し、特徴量を算出するステップと、
前記複数の対象画像の注目する注目対象画像について、該注目対象画像よりも特徴量が大きな周辺の他の対象画像のつなぎ位置を取得するステップと、
前記注目対象画像に対し、前記他の対象画像のつなぎ位置に基づいて前記注目対象画像の前記第2の入力画像へのつなぎ位置を検出するステップと
を実行する、画像処理方法。
(付記9)
複数の入力画像間のつなぎ位置を検出するための画像処理装置を実現するためのプログラムであって、コンピュータを、
第1の入力画像から、それぞれ第2の入力画像内で探索する対象となる複数の対象画像を生成する対象画像生成手段、
前記複数の対象画像各々に対し、特徴量を算出する特徴量算出手段、および
前記複数の対象画像の注目する注目対象画像に対し、該注目対象画像よりも特徴量が大きな周辺の他の対象画像のつなぎ位置に基づいて前記第2の入力画像へのつなぎ位置を検出するつなぎ位置検出手段
として機能させるためのプログラム。
(付記10)
複数の撮像画像間のつなぎ位置を検出するための撮像システムであって、
撮像手段と、
前記撮像手段により、それぞれ複数の方位について撮像された複数の撮像画像から複数の入力画像を取得する手段と、
第1の入力画像から、それぞれ第2の入力画像内で探索する対象となる複数の対象画像を生成する対象画像生成手段と、
前記複数の対象画像各々に対し、特徴量を算出する特徴量算出手段と、
前記複数の対象画像の注目する注目対象画像に対し、該注目対象画像よりも特徴量が大きな周辺の他の対象画像のつなぎ位置に基づいて前記注目対象画像の前記第2の入力画像へのつなぎ位置を検出するつなぎ位置検出手段と
を含む、撮像システム。
(Note)
(Appendix 1)
An image processing device for detecting a connection position between a plurality of input images,
Target image generating means for generating, from the first input image, a plurality of target images to be searched in the second input image,
For each of the plurality of target images, a feature amount calculating unit that calculates a feature amount,
For the target image of interest of the plurality of target images, connecting the target image to the second input image based on a connection position of another target image having a larger feature amount than the target image. An image processing apparatus, comprising: a connecting position detecting unit that detects a position.
(Appendix 2)
Tentative position calculating means for calculating a tentative position with respect to the target image based on a relative relationship between feature amounts between the target image and each of one or more peripheral target images;
A matching calculating unit that calculates matching between the target image and a portion of the second input image based on the temporary position calculated by the temporary position calculating unit with respect to the target image. 2. The image processing device according to 1.
(Appendix 3)
A process ranking unit that ranks the processes for the plurality of target images based on the feature amount and defines a relative relationship between the feature amounts, wherein the provisional position calculation unit is more than the attention target image. Using the determined joint position of the peripheral target image having a large feature amount and the initial joint position of the peripheral target image having a smaller feature amount than the target image, the temporary position with respect to the target image is calculated. 3. The image processing apparatus according to claim 2, wherein
(Appendix 4)
The tentative position calculating means may perform weighting according to a relative relationship between the feature amounts of each of the one or more peripheral target images with respect to the target image and a distance between each of the one or more peripheral target images from the target image. 4. The image processing apparatus according to claim 2, wherein the provisional position with respect to the target image is calculated by performing both or one of the weights according to the weight.
(Appendix 5)
The image processing according to any one of Supplementary notes 2 to 4, further comprising an evaluation value correction unit that corrects the evaluation value based on the similarity calculated by the matching calculation unit so that the evaluation value is prioritized around the temporary position. apparatus.
(Appendix 6)
A search range setting unit configured to set a search range in the matching in the second input image based on a relative relationship between feature amounts between the target image and one or more peripheral target images. The image processing apparatus according to any one of supplementary notes 2 to 5, including:
(Appendix 7)
An image processing apparatus that combines a plurality of input images,
A feature value obtaining unit configured to obtain a feature value of a plurality of target images in the first input image;
In the target image of interest among the plurality of target images, the first position is detected at a connection position detected using a connection position of another target image having a larger feature amount than the target image with respect to the second input image. An image processing apparatus comprising: a synthesizing unit that synthesizes an input image and the second input image.
(Appendix 8)
An image processing method for detecting a connection position between a plurality of input images, the computer comprising:
Generating, from the first input image, a plurality of target images to be searched in the second input image, respectively;
Calculating a feature amount for each of the plurality of target images;
Acquiring, for a target image of interest of the plurality of target images, a connection position of another target image around which a feature amount is larger than the target image;
Detecting a connection position of the target image to the second input image based on a connection position of the another target image with respect to the target image.
(Appendix 9)
A program for realizing an image processing device for detecting a connection position between a plurality of input images, the computer comprising:
Target image generating means for generating a plurality of target images to be searched in the second input image from the first input image,
A feature value calculating unit that calculates a feature value for each of the plurality of target images; and a target image of interest of the plurality of target images, the other target image having a larger feature value than the target image. A program for functioning as a connecting position detecting means for detecting a connecting position to the second input image based on the connecting position.
(Appendix 10)
An imaging system for detecting a connection position between a plurality of captured images,
Imaging means;
Means for acquiring a plurality of input images from a plurality of captured images, each of which is imaged in a plurality of directions, by the imaging means;
Target image generation means for generating a plurality of target images to be searched in the second input image from the first input image,
For each of the plurality of target images, a feature amount calculating unit that calculates a feature amount,
For the target image of interest of the plurality of target images, a connection of the target image to the second input image based on a connection position of another peripheral target image having a larger feature amount than the target image. An image capturing system, comprising: a connecting position detecting unit that detects a position.

10,300…全天球撮像システム、12…撮像体、14…筐体、18…シャッター・ボタン、20…結像光学系、22…固体撮像素子、100…プロセッサ、102…鏡胴ユニット,108…ISP、110,122…DMAC、112…アービタ(ARBMEMC)、114…MEMC、116,138…SDRAM、118…歪曲補正・画像合成ブロック、120…3軸加速度センサ、124…画像処理ブロック、126…画像データ転送部、128…SDRAMC、130…CPU、132…リサイズブロック、134…JPEGブロック、136…H.264ブロック、140…メモリカード制御ブロック、142…メモリカードスロット、144…フラッシュROM、146…USBブロック、148…USBコネクタ、150…ペリフェラル・ブロック、152…音声ユニット、154…スピーカ、156…マイク、158…シリアルブロック、160…無線NIC、162…LCDドライバ、164…LCDモニタ、166…電源スイッチ、168…ブリッジ、200…機能ブロック、202…位置検出用歪み補正部、204…つなぎ位置検出部、206…テーブル修正部、208…テーブル生成部、210…画像合成用歪み補正部、212…画像合成部、214…表示画像生成部、220…位置検出用変換テーブル、220…検出結果データ、224…画像合成用変換テーブル、232…テンプレート生成部、234…テンプレート特徴量算出部、236…テンプレート順位付け部、238…仮位置算出部、240…探索範囲設定部、242…マッチング計算部、244…スコア補正部、246…つなぎ位置決定部、248…検出結果生成部、250…エッジ抽出フィルタ部、252…ゲイン乗算部、254…LPF部、256…加算部、300…テンプレート用画像、302…テンプレート画像、310…探索用画像、312…探索範囲、314…対応部分、330…探索領域、332…初期位置、334…仮位置、336…隣接のつなぎ位置、360…探索範囲、410…全天球撮像装置、430…コンピュータ装置、432…USBI/F、434…無線NIC 10, 300 spherical imaging system, 12 imaging body, 14 housing, 18 shutter button, 20 imaging optical system, 22 solid-state imaging device, 100 processor, 102 lens barrel unit, 108 ... ISP, 110, 122 ... DMAC, 112 ... Arbiter (ARBMEMC), 114 ... MEMC, 116, 138 ... SDRAM, 118 ... distortion correction and image synthesis block, 120 ... three-axis acceleration sensor, 124 ... image processing block, 126 ... Image data transfer unit, 128 SDRAM, 130 CPU, 132 resize block, 134 JPEG block, 136 H. 264 blocks, 140 memory card control block, 142 memory card slot, 144 flash ROM, 146 USB block, 148 USB connector, 150 peripheral block, 152 audio unit, 154 speaker, 156 microphone 158: Serial block, 160: Wireless NIC, 162: LCD driver, 164: LCD monitor, 166 ... Power switch, 168 ... Bridge, 200 ... Function block, 202 ... Distortion correction unit for position detection, 204 ... Connection position detection unit, 206: Table correction unit, 208: Table generation unit, 210: Image synthesis distortion correction unit, 212: Image synthesis unit, 214: Display image generation unit, 220: Position detection conversion table, 220: Detection result data, 224: Conversion table for image synthesis, 23 ... Template generation unit, 234 ... Template feature amount calculation unit, 236 ... Template ranking unit, 238 ... Temporary position calculation unit, 240 ... Search range setting unit, 242 ... Matching calculation unit, 244 ... Score correction unit, 246 ... Connection position Determination unit, 248 detection result generation unit, 250 edge extraction filter unit, 252 gain multiplication unit, 254 LPF unit, 256 addition unit, 300 image for template, 302 image for template, 310 image for search, Reference numeral 312: Search range, 314: Corresponding part, 330: Search area, 332: Initial position, 334: Temporary position, 336: Adjoining connection position, 360: Search range, 410: Spherical sphere imaging device, 430: Computer device, 432: USB I / F, 434: Wireless NIC

特開2001−148779号公報JP 2001-148779 A

Claims (6)

複数の入力画像を合成する画像処理装置であって、
第1の入力画像における複数の対象画像の特徴量を取得する特徴量取得手段と、
傾き情報を取得する傾き情報取得手段と、
前記複数の対象画像のうち注目する注目対象画像よりも特徴量が大きな他の対象画像についての前記第1の入力画像と第2の入力画像とのつなぎ位置を使って、前記注目対象画像と前記第2の入力画像の部分との間で探索を行うことにより検出されたつなぎ位置と、前記傾き情報取得手段により取得された傾き情報とに基づいて前記第1の入力画像と、前記第2の入力画像とを合成する合成手段と
を備えたことを特徴とする、画像処理装置。
An image processing apparatus that combines a plurality of input images,
A feature value obtaining unit configured to obtain a feature value of a plurality of target images in the first input image;
Inclination information acquisition means for acquiring inclination information;
Using the connection position between the first input image and the second input image for another target image having a larger feature amount than the target image of interest among the plurality of target images, the target image and the target image The first input image and the second input image based on a joint position detected by performing a search between a portion of the second input image and the inclination information acquired by the inclination information acquiring means ; An image processing apparatus, comprising: synthesizing means for synthesizing an input image.
前記注目対象画像について、前記注目対象画像と1以上の周辺の対象画像各々との間の特徴量の相対的な関係に基づいて、仮位置を算出する仮位置算出手段と、
前記注目対象画像について、前記仮位置算出手段により算出された仮位置に基づいて、前記第2の入力画像の対応部分とのマッチングの評価値を計算するマッチング計算手段と
を含み、前記第1の入力画像と前記第2の入力画像とを合成する際に基づくつなぎ位置は、前記評価値に基づいて決定された前記注目対象画像についての前記第1の入力画像と前記第2の入力画像とのつなぎ位置である、請求項1に記載の画像処理装置。
Temporary position calculating means for calculating a temporary position based on a relative relationship between feature amounts between the target image and each of one or more peripheral target images;
Matching calculation means for calculating an evaluation value of matching with the corresponding part of the second input image based on the temporary position calculated by the temporary position calculation means for the target image; A connection position based on combining the input image and the second input image is determined based on the first input image and the second input image of the target image determined based on the evaluation value. The image processing device according to claim 1, wherein the image processing device is a connection position.
前記複数の対象画像についての処理を前記特徴量に基づいて順位付けて、前記特徴量の相対的な関係を規定する処理順位付け手段をさらに含み、前記仮位置算出手段は、前記注目対象画像よりも特徴量の大きな周辺の対象画像についての決定済みのつなぎ位置と、前記注目対象画像よりも特徴量の小さな周辺の対象画像についての初期つなぎ位置とを用いて、前記注目対象画像についての前記仮位置を算出することを特徴とする、請求項2に記載の画像処理装置。   A process ranking unit that ranks the processes for the plurality of target images based on the feature amounts and defines a relative relationship between the feature amounts, wherein the temporary position calculation unit determines the relative positions of the plurality of target images based on the target image. Also, using the determined connection position of the peripheral target image having a large feature amount and the initial connection position of the peripheral target image having a smaller feature amount than the target image, the temporary connection position of the target image is calculated. The image processing apparatus according to claim 2, wherein the position is calculated. 前記仮位置算出手段は、前記注目対象画像に対する1以上の周辺の対象画像各々の特徴量の相対的な関係に応じた重み付けおよび前記注目対象画像からの1以上の周辺の対象画像各々の距離に応じた重み付けの両方または一方の重み付けを行って、前記注目対象画像についての前記仮位置を算出することを特徴とする、請求項2または3に記載の画像処理装置。   The tentative position calculating means may perform weighting according to a relative relationship between the feature amounts of each of the one or more peripheral target images with respect to the target image and a distance between each of the one or more peripheral target images from the target image. The image processing apparatus according to claim 2, wherein the provisional position of the target image is calculated by performing both or one of the weights according to the weight. 前記マッチング計算手段により算出された類似度に基づく前記評価値を、仮位置を中心に優先されるように補正する評価値補正手段をさらに含む、請求項2〜4のいずれか1項に記載の画像処理装置。   The evaluation value correction unit according to any one of claims 2 to 4, further comprising an evaluation value correction unit that corrects the evaluation value based on the similarity calculated by the matching calculation unit so that the evaluation value is prioritized around the temporary position. Image processing device. 前記注目対象画像と1以上の周辺の対象画像各々との間の特徴量の相対的な関係に基づいた前記マッチングでの探索範囲を設定する探索範囲設定手段をさらに含む、請求項2〜5のいずれか1項に記載の画像処理装置。   The search range setting unit according to claim 2, further comprising a search range setting unit configured to set a search range in the matching based on a relative relationship between feature amounts between the target image and each of one or more peripheral target images. The image processing device according to claim 1.
JP2018218280A 2018-11-21 2018-11-21 Image processing device Active JP6665917B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018218280A JP6665917B2 (en) 2018-11-21 2018-11-21 Image processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018218280A JP6665917B2 (en) 2018-11-21 2018-11-21 Image processing device

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2017194761A Division JP6439845B2 (en) 2017-10-05 2017-10-05 Image processing device

Publications (2)

Publication Number Publication Date
JP2019053758A JP2019053758A (en) 2019-04-04
JP6665917B2 true JP6665917B2 (en) 2020-03-13

Family

ID=66013482

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018218280A Active JP6665917B2 (en) 2018-11-21 2018-11-21 Image processing device

Country Status (1)

Country Link
JP (1) JP6665917B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7165820B2 (en) * 2019-05-15 2022-11-04 株式会社Nttドコモ Image processing device
EP4016464A1 (en) 2020-11-26 2022-06-22 Ricoh Company, Ltd. Apparatus, system, method, and carrier means

Also Published As

Publication number Publication date
JP2019053758A (en) 2019-04-04

Similar Documents

Publication Publication Date Title
KR101657039B1 (en) Image processing apparatus, image processing method, and imaging system
JP6468307B2 (en) Imaging apparatus, image processing apparatus and method
JP5846172B2 (en) Image processing apparatus, image processing method, program, and imaging system
JP2017208619A (en) Image processing apparatus, image processing method, program and imaging system
JP6222205B2 (en) Image processing device
JP5796611B2 (en) Image processing apparatus, image processing method, program, and imaging system
JP6665917B2 (en) Image processing device
JP6291748B2 (en) Imaging apparatus, imaging method, and program
US20220224831A1 (en) Removal of image capture device from omnidirectional image created by stitching partial images
JP6079838B2 (en) Image processing apparatus, program, image processing method, and imaging system
CN114073069A (en) Imaging system, image processing apparatus, imaging device, and recording medium
JP6439845B2 (en) Image processing device
CN109214983B (en) Image acquisition device and image splicing method thereof
JP2024056212A (en) IMAGE PROCESSING APPARATUS, IMAGE PROCESSING SYSTEM, IMAGING APPARATUS, IMAGE PROCESSING METHOD, AND PROGRAM
JP2018078461A (en) Image processing apparatus, image processing method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20181122

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20190927

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20191021

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A132

Effective date: 20191029

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20191227

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200203

R151 Written notification of patent or utility model registration

Ref document number: 6665917

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151