JP5251410B2 - Camera work calculation program, imaging apparatus, and camera work calculation method - Google Patents

Camera work calculation program, imaging apparatus, and camera work calculation method Download PDF

Info

Publication number
JP5251410B2
JP5251410B2 JP2008258544A JP2008258544A JP5251410B2 JP 5251410 B2 JP5251410 B2 JP 5251410B2 JP 2008258544 A JP2008258544 A JP 2008258544A JP 2008258544 A JP2008258544 A JP 2008258544A JP 5251410 B2 JP5251410 B2 JP 5251410B2
Authority
JP
Japan
Prior art keywords
camera work
images
trajectory
calculation program
work calculation
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
JP2008258544A
Other languages
Japanese (ja)
Other versions
JP2010093343A (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.)
Nikon Corp
Original Assignee
Nikon Corp
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 Nikon Corp filed Critical Nikon Corp
Priority to JP2008258544A priority Critical patent/JP5251410B2/en
Publication of JP2010093343A publication Critical patent/JP2010093343A/en
Application granted granted Critical
Publication of JP5251410B2 publication Critical patent/JP5251410B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Television Signal Processing For Recording (AREA)
  • Studio Devices (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)

Description

本発明は、カメラワーク算出プログラム、撮像装置及びカメラワーク算出方法に関する。 The present invention relates to a camera work calculation program, an imaging apparatus, and a camera work calculation method.

従来、動画の撮影における手ブレ補正処理やカメラワーク最適化処理は、動画撮影中に処理を行うものと撮影後に処理を行うものとに大きく分けられる。   Conventionally, camera shake correction processing and camera work optimization processing in moving image shooting are roughly classified into processing performed during moving image shooting and processing performed after shooting.

例えば、特許文献1は、動画撮影後に処理を行うものであり、撮影した動画に基づいて、フィールド間又はフレーム間の動きから手ブレやカメラの動きを検出して、手ブレ補正を行うことにより、カメラ自身の軌跡を求めてユーザが意図したカメラワークの軌跡を推定し、そのカメラワークの軌跡となるように、フィールド間又はフレーム間の動きを補正する技術を開示している。
特開2008−005109号公報
For example, Patent Document 1 performs processing after shooting a moving image, and detects camera shake or camera movement from movement between fields or frames based on the shot moving image, and performs camera shake correction. In addition, a technique is disclosed in which the trajectory of the camera itself is obtained to estimate the trajectory of the camera work intended by the user, and the motion between fields or frames is corrected so as to be the trajectory of the camera work.
JP 2008-005109 A

しかしながら、特許文献1のような従来技術では、動画に写っている被写体像が静止するように、フレームである各画像を如何になめらかに繋ぐかということを目的としているため、あるフレームの画像が他の画像の位置から大きくズレてしまっている場合には、処理されて得られた動画を再生した時、そのフレームだけ表示されないか、又はその一部しか表示されず、見苦しいという問題があった。   However, the conventional technique such as Patent Document 1 aims at how to smoothly connect each image, which is a frame, so that the subject image in the moving image is stationary. When it is greatly shifted from the position of other images, there is a problem that when playing a video obtained by processing, only that frame is displayed or only part of it is displayed and it is unsightly. .

上記従来技術が有する問題に鑑み、本発明の目的は、ユーザが所望するカメラワークによって見やすくなめらかな動画を生成することができる技術を提供することにある。   In view of the problems of the above-described conventional technology, an object of the present invention is to provide a technology capable of generating a smooth moving image that is easy to see by camera work desired by a user.

上記課題を解決するために、本発明のカメラワーク算出プログラムは、被写体像を連撮像して生成された動画データを構成する複数の画像について特徴量抽出し、該特徴に基づいて、複数の画像のうち隣り合画像間の位置ズレ量を検出する検出ステップと、検出ステップによって検出し画像間の位置ズレ量に基づいて、動画データを撮像した時の第1のカメラワークの軌跡を求める第1のカメラワーク算出ステップと、第1のカメラワーク算出ステップによって求めた第1のカメラワークの軌跡上の位置から所定の閾値の範囲内で第2のカメラワークの軌跡算出する第2のカメラワーク算出ステップと、第2のカメラワーク算出ステップによって求めた第2のカメラワークの軌跡上における、複数の画像の各々の位置情報に基づいて、複数の画像の各々の相対的位置を補正する補正ステップとをコンピュータに実行させる。 In order to solve the above problems, the camera work calculation program of the present invention, the feature quantity extracted for a plurality of images constituting the moving image data generated by continuous imaging an object image, based on the feature amount, a detecting step of detecting a positional deviation amount between the focus cormorants image adjacent among the plurality of images, based on the positional deviation amount between the detected by the detection step image, the first camera work when capturing the moving image data calculating a first camera work calculation step of obtaining a trajectory, the trajectory of the second camera work within a range of positions on the trajectory of the predetermined threshold of the first camera work calculated by the first camera work calculation step a second camera work calculation step, on the trajectory of the second camera work determined by the second camera work calculation step, based on the position information of each of the plurality of images Te, to execute a correction step of correcting the relative position of each of the plurality of images on the computer.

また、本発明において、補正ステップによって相対的位置が補正された複数の画像の各々に対して、周囲の画素を所定の閾値の大きさの範囲内で切り取って整形するフレーム整形ステップをさらに備える。   Further, the present invention further includes a frame shaping step of cutting and shaping surrounding pixels within a predetermined threshold size range for each of the plurality of images whose relative positions have been corrected by the correction step.

また、本発明において、検出ステップにおいて検出され画像間の位置ズレ量は、画像面内における一の方向成分、一の方向成分に交差する方向成分、及び回転成分を有する。 Further, in the present invention, positional deviation amount between the images that will be detected in the detection step comprises, one direction component in the image plane, a direction component intersecting the one direction component, and a rotational component.

また、本発明において、検出ステップにおいて検出され画像間の位置ズレ量が所定値より大きい場合には、動画データの被写体像の対象が変化したと判定するシーン判定ステップをさらに備える。 Further, in the present invention, when the positional deviation amount between the detected Ru image in the detection step is larger than the predetermined value further comprises determining scene determination step interest has changed in the subject image of the moving image data.

また、本発明において、第2のカメラワーク算出ステップは、所定の閾値の範囲内で、第1のカメラワークの軌跡と第2のカメラワークの軌跡との差分の総和が最小になるように、第2のカメラワークの軌跡を算出する。 Further, in the present invention, the second camera work calculation step is performed such that the sum of the differences between the first camera work locus and the second camera work locus is minimized within a predetermined threshold range. The trajectory of the second camera work is calculated.

また、本発明において、第2のカメラワーク算出ステップは、差分の総和を、一の方向成分、一の方向成分に交差する方向成分、及び回転成分毎に行い、それぞれの成分毎に差分の総和を、それぞれの成分毎の所定の閾値の範囲内で最小になるように、第2のカメラワークの軌跡を算出する。
また、本発明において、第2のカメラワーク算出ステップは、隣り合う画像間で、互いに一定の相関を持つ所定の閾値の範囲内で第2のカメラワークの軌跡を算出する。
また、本発明において、一定の相関は、2つの画像の重なる領域の大きさが一定以上有する。
In the present invention, the second camera work calculation step performs the sum of the differences for each direction component, the direction component intersecting the one direction component, and the rotation component, and the sum of the differences for each component. The trajectory of the second camera work is calculated so as to be minimized within a predetermined threshold range for each component.
In the present invention, the second camera work calculation step calculates the locus of the second camera work within a predetermined threshold range having a certain correlation with each other between adjacent images.
Further, in the present invention, the constant correlation has a certain size of the area where two images overlap.

本発明の撮像装置は、被写体像を連続して撮像して動画データを生成する撮像部と、本発明のカメラワーク算出プログラムを動画データに対して実行する制御部とを備える。 The imaging apparatus of the present invention includes an imaging unit that continuously captures subject images and generates moving image data, and a control unit that executes the camera work calculation program of the present invention on the moving image data.

本発明のカメラワーク算出方法は、被写体像を連撮像して生成された動画データを構成する複数の画像について特徴量抽出し、該特徴に基づいて、複数の画像のうち隣り合画像間の位置ズレ量を検出する検出工程と、検出工程によって検出し画像間の位置ズレ量に基づいて、動画データを撮像した時の第1のカメラワークの軌跡を求める第1のカメラワーク算出工程と、第1のカメラワーク算出工程によって求めた第1のカメラワークの軌跡上の位置から所定の閾値の範囲内で第2のカメラワークの軌跡算出する第2のカメラワーク算出工程と、第2のカメラワーク算出工程によって求めた第2のカメラワークの軌跡上における、複数の画像の各々の位置情報に基づいて、複数の画像の各々の相対的位置を補正する補正工程とを備える。 Camerawork calculation method of the present invention, the plurality of images constituting the moving image data generated by continuous imaging an object image and extracts a feature quantity, based on the feature amount, intends case adjacent among the plurality of images a detection step of detecting a positional deviation amount between the images, the first camera work based on the positional deviation amount between the image detected by the detecting step, obtaining the trajectory of the first camera work when capturing the moving image data a calculating step, and the second camera work calculation step of calculating the trajectory of the second camera work from a position on the trajectory of the first camera work calculated by the first camera work calculation step within a predetermined threshold value , on the trajectory of the second camera work determined by the second camera work calculating step, based on the position information of each of the plurality of images, and a correction step of correcting the relative position of each of the plurality of images Obtain.

本発明によれば、ユーザが所望するカメラワークによって見やすくなめらかな動画を生成することができる。   According to the present invention, it is possible to generate a smooth moving image that is easy to see depending on the camera work desired by the user.

図1は、本発明の一の実施形態に係るカメラワーク最適化プログラムがインストールされたコンピュータ10の概念図である。   FIG. 1 is a conceptual diagram of a computer 10 in which a camera work optimization program according to an embodiment of the present invention is installed.

図1に示すコンピュータ10は、CPU1、記憶部2、入出力インタフェース(入出力I/F)3及びバス4から構成され、CPU1、記憶部2及び入出力I/F3は、バス4を介して情報伝達可能に接続される。また、コンピュータ10には、入出力I/F3を介して、画像処理の途中経過や処理結果を表示する出力装置5、ユーザからの入力を受け付ける入力装置6がそれぞれ接続される。出力装置5には、一般的な液晶モニタやプリンタ等を用いることができ、入力装置6には、キーボードやマウス等をそれぞれ適宜選択して使用できる。   A computer 10 shown in FIG. 1 includes a CPU 1, a storage unit 2, an input / output interface (input / output I / F) 3 and a bus 4, and the CPU 1, storage unit 2 and input / output I / F 3 are connected via the bus 4. Connected so that information can be transmitted. The computer 10 is connected to an output device 5 for displaying the progress of image processing and processing results, and an input device 6 for receiving input from the user via an input / output I / F 3. As the output device 5, a general liquid crystal monitor, a printer, or the like can be used. As the input device 6, a keyboard, a mouse, or the like can be appropriately selected and used.

CPU1は、入力装置6で受け付けたユーザからの指示に基づいて、記憶部2に記憶されているカメラワーク最適化プログラムを読み込み、記憶部2に記憶されている動画データに対する処理を行う。CPU1は、その動画の処理の結果を、出力装置5に表示したり、記憶部2に記録する。CPU1には、一般的な中央演算装置を用いることができる。   The CPU 1 reads a camera work optimization program stored in the storage unit 2 based on an instruction from the user received by the input device 6, and performs processing on the moving image data stored in the storage unit 2. The CPU 1 displays the result of the moving image processing on the output device 5 or records it in the storage unit 2. A general central processing unit can be used for the CPU 1.

記憶部2は、カメラワーク最適化プログラムや被写体像が撮像された動画データだけでなく、ユーザが望むカメラワークで見やすくなめらかなに処理された動画データも保持する。また、記憶部2は、そうした処理において必要となるパラメータの閾値等のデータも記憶する。記憶部2に記憶される動画データ、プログラム及びその他データは、バス4を介して、CPU1から適宜参照することができる。記憶部2には、一般的なハードディスク装置、光磁気ディスク装置等の記憶装置を選択して用いることができる。なお、図1の記憶部2は、コンピュータ10に組み込まれているが、外付けの記憶装置でもよい。この場合、記憶部2は、入出力I/F3を介してコンピュータ10に接続される。   The storage unit 2 holds not only the camera work optimization program and moving image data in which the subject image is captured, but also moving image data that is smoothly processed so as to be easily viewed with the camera work desired by the user. The storage unit 2 also stores data such as parameter threshold values necessary for such processing. The moving image data, program, and other data stored in the storage unit 2 can be referred to as appropriate from the CPU 1 via the bus 4. A storage device such as a general hard disk device or a magneto-optical disk device can be selected and used for the storage unit 2. 1 is incorporated in the computer 10, it may be an external storage device. In this case, the storage unit 2 is connected to the computer 10 via the input / output I / F 3.

次に、本実施形態に係るカメラワーク最適化の処理の手順について、図2のフローチャートを参照しながら説明する。   Next, the procedure of the camera work optimization process according to the present embodiment will be described with reference to the flowchart of FIG.

ユーザが、入力装置6を用いて、カメラワーク最適化プログラムのコマンドを入力、又はそのプログラムのアイコンをダブルクリックすることにより、プログラムの起動命令をCPU1に対して出す。CPU1は、その命令を入出力I/F3を通じて受け、記憶部2に記憶されているカメラワーク最適化プログラムを起動する。そのプログラムの起動とともに、CPU1は、カメラワーク最適化処理のためのパラメータの閾値を読み込み、メモリ(不図示)に一時的に記憶する。そして、ユーザは、後述するステップS15における最適なカメラワークの軌跡を求める不等式拘束条件付き最小化問題を解く際に必要となる位置ズレ量の閾値を設定する。その結果、図2のステップS10からの処理が行われる。   When the user inputs a command of the camera work optimization program using the input device 6 or double-clicks the icon of the program, a program start command is issued to the CPU 1. The CPU 1 receives the command through the input / output I / F 3 and activates the camera work optimization program stored in the storage unit 2. Along with the activation of the program, the CPU 1 reads the parameter threshold for the camera work optimization process and temporarily stores it in a memory (not shown). Then, the user sets a threshold value of a positional deviation amount that is necessary when solving the minimization problem with an inequality constraint condition for obtaining an optimal camerawork trajectory in step S15 described later. As a result, the processing from step S10 in FIG. 2 is performed.

なお、本実施形態では、記憶部2にあらかじめ処理の対象となる、電子カメラ等で被写体像を撮像した動画データが記憶されているものとする。また、本実施形態では、動画データの第0フレームの画像を基準にしてカメラワーク最適化処理を行う。   In the present embodiment, it is assumed that moving image data obtained by capturing a subject image with an electronic camera or the like, which is a processing target, is stored in the storage unit 2 in advance. In the present embodiment, the camera work optimization process is performed based on the 0th frame image of the moving image data.

ステップS10:CPU1は、ユーザがカメラワーク最適化処理を施したい、例えば、図3に示すシーンを撮影した動画の指定を、入力装置6を介して、ユーザから受け付け、その動画データを記憶部2より読み込み、メモリ(不図示)に一時的に記憶する。   Step S10: The CPU 1 accepts designation of a moving image in which the user wants to perform camerawork optimization processing, for example, the scene shown in FIG. Is read and temporarily stored in a memory (not shown).

ステップS11:CPU1は、ステップS10で読み込んだ動画データを構成する複数のフレームの画像を用いて、隣り合うフレームの画像間の位置ズレ量を求める。そのために、CPU1は、最初のフレーム(第0フレーム)の画像と次の第1フレームの画像とから開始し、順次隣り合うフレームの画像間の位置ズレ量を求める。そこで、CPU1は、画像の特徴量であるエッジ量に基づいて画像の特徴点を抽出する。具体的には、CPU1は、KLT(Kanade-Lucas-Tomasi)法と多重解像度変換とを用いて複数の特徴点を抽出する。なお、一般にKLT法は、ある2つの画像間において対応する部分の動きベクトルを求めるものとして用いられるが、本実施形態におけるKLT法は、画像中の直交する水平走査方向と垂直走査方向とにおいて大きなエッジ勾配を有する点、つまり被写体像の境界の角にある点を抽出する機能を備えたものを用いる(例えば、J. Shin and C. Tomasi, 'Good Features to Track', IEEE Conference on Computer Vision and Pattern Recognition (CVPR94) Seattle, June 1994を参照)。さらに、多重解像度変換とを併せて用いることにより、特徴点の抽出の精度を上げるようにする。   Step S11: The CPU 1 obtains a positional shift amount between the images of adjacent frames using the images of a plurality of frames constituting the moving image data read in Step S10. For this purpose, the CPU 1 starts from an image of the first frame (0th frame) and an image of the next first frame, and sequentially obtains a positional shift amount between images of adjacent frames. Therefore, the CPU 1 extracts feature points of the image based on the edge amount that is the feature amount of the image. Specifically, the CPU 1 extracts a plurality of feature points using a KLT (Kanade-Lucas-Tomasi) method and multi-resolution conversion. In general, the KLT method is used to obtain a motion vector of a corresponding part between two images, but the KLT method in the present embodiment is large in the horizontal scanning direction and the vertical scanning direction orthogonal to each other in the image. Use a point with the function of extracting a point with an edge gradient, that is, a point at the corner of the subject image (for example, J. Shin and C. Tomasi, 'Good Features to Track', IEEE Conference on Computer Vision and (See Pattern Recognition (CVPR94) Seattle, June 1994). Furthermore, the accuracy of feature point extraction is increased by using multi-resolution conversion together.

そのようにして特徴点を抽出した一例を図3に示す。図3は、第0フレームの画像20a及び第1フレームの画像20bのそれぞれにおいて、山の稜線や人物と背景との境界等に特徴点(●印)が抽出されている。なお、抽出される点数は、最低でも3点必要であり、点数が多ければ多いほど、後で求める各フレームの画像間の位置ズレ量を精度良く求めることができる。本実施形態では、抽出された特徴点のうち、所定値以上のエッジ量を有し、大きい値のものから順に特徴点を抽出した。具体的には、上位100位までの特徴点を抽出した。なお、この特徴点の数は、画像の撮影状況等に応じて任意に決めることができる。   An example of extracting feature points in this way is shown in FIG. In FIG. 3, in each of the image 20a of the 0th frame and the image 20b of the first frame, feature points (● marks) are extracted at the edge of the mountain, the boundary between the person and the background, and the like. Note that the number of points to be extracted is at least three, and the larger the number of points, the more accurately the amount of positional deviation between images of each frame to be obtained later. In this embodiment, among the extracted feature points, the feature points are extracted in order from the largest value having an edge amount equal to or greater than a predetermined value. Specifically, feature points up to the top 100 were extracted. It should be noted that the number of feature points can be arbitrarily determined according to the shooting situation of the image.

ステップS12:CPU1は、ステップS11で抽出した第0フレームの画像20a及び第1フレームの画像20bにおけるそれぞれの特徴点に対して、オプティカルフローの手法を適用して、各特徴点における動きベクトルを算出する。具体的には、CPU1は、上述したKLT法を用い、隣り合うフレームの2つ画像における特徴点の全てが互いに存在する場合には、全ての特徴点についての動きベクトルを求める。一方、隣り合うフレームの2つ画像における特徴点の一部が画像領域からフレームイン又はフレームアウトしているような場合(例えば、第0フレーム画像の右側の特徴点がフレームアウトしたり、第1フレームの画像20bにおける左側の樹木上の特徴点がフレームインしている場合)には、CPU1は、両方の画像において存在する特徴点のみの動きベクトルを求める。図4の第1フレームの画像20bに示す矢印が、上記の手順で求めた各特徴点における動きベクトルを示す。   Step S12: The CPU 1 calculates a motion vector at each feature point by applying an optical flow method to each feature point in the image 20a of the 0th frame and the image 20b of the first frame extracted in step S11. To do. Specifically, the CPU 1 uses the above-described KLT method and, when all feature points in two images of adjacent frames are present with each other, obtains motion vectors for all feature points. On the other hand, when some of the feature points in two images of adjacent frames are framed in or out of the image area (for example, the feature point on the right side of the 0th frame image is out of frame, When the feature point on the left tree in the frame image 20b is in the frame), the CPU 1 obtains a motion vector of only the feature point existing in both images. The arrow shown in the image 20b of the first frame in FIG. 4 indicates the motion vector at each feature point obtained by the above procedure.

次に、CPU1は、求めた第0フレームの画像20aと第1フレームの画像20bとで動きベクトルを求めることのできた特徴点を用いて、水平走査方向であるX成分(ピクセル)、垂直走査方向であるY成分(ピクセル)及び回転成分θ(度)から成る位置ズレ量を算出する。本実施形態では、位置ズレ量を算出する方法の1つである、その3成分からなるアフィン変換の変換行列を用いて求める方法を用いる。つまり、次式(1)で示される変換行列Aを有する次式(2)で表される方程式を用いて、各フレームの画像間の位置ズレ量を算出する。   Next, the CPU 1 uses an X component (pixel) in the horizontal scanning direction and the vertical scanning direction by using the feature points for which the motion vector can be obtained from the obtained image 20a of the 0th frame and the image 20b of the first frame. A positional shift amount consisting of a Y component (pixel) and a rotation component θ (degrees) is calculated. In the present embodiment, a method of calculating by using a transformation matrix of the affine transformation composed of the three components, which is one of the methods for calculating the positional deviation amount, is used. That is, the amount of positional deviation between images in each frame is calculated using the equation represented by the following equation (2) having the transformation matrix A represented by the following equation (1).

数式1Formula 1

Figure 0005251410
Figure 0005251410

数式2Formula 2

Figure 0005251410
Figure 0005251410

即ち、CPU1は、上記で求めた各動きベクトルに対応する第0フレームの画像20aにおける各特徴点の座標(x、y、1)と、対応する第1フレームの画像20bにおける特徴点の座標(x’、y’、1)とを式(2)にそれぞれ代入して、最小2乗法によって式(1)のパラメータである位置ズレ量(x0、y0、θ)の値を算出する。そして、CPU1は、第0フレームの画像20aと第1フレームの画像20bとの位置ズレ量(x0、y0、θ)を記憶部2に記録する。 That is, the CPU 1 coordinates (x, y, 1) of each feature point in the image 20a of the 0th frame corresponding to each motion vector obtained above and the coordinates (x, y, 1) of the feature points in the corresponding image 20b of the first frame. Substituting x ′, y ′, 1) into equation (2), respectively, the position deviation amount (x 0 , y 0 , θ), which is a parameter of equation (1), is calculated by the least square method. Then, the CPU 1 records the amount of positional deviation (x 0 , y 0 , θ) between the 0th frame image 20 a and the first frame image 20 b in the storage unit 2.

ステップS13:CPU1は、ステップS12で求めた各隣り合うフレームの画像間の位置ズレ量(x0、y0、θ)を、次式(3)のように成分毎に積算する。 Step S13: The CPU 1 integrates the positional deviation amounts (x 0 , y 0 , θ) between the images of the adjacent frames obtained in step S12 for each component as in the following equation (3).

数式3Formula 3

Figure 0005251410
Figure 0005251410

ここで、Xm(i)、Ym(i)、θm(i)は、第0フレームの画像から第iフレームの画像までの位置ズレ量(x0、y0、θ)を成分毎に積算した値を表す(i=0、1、2、…)。この積算値(Xm(i)、Ym(i)、θm(i))が、実際の動画撮影時のカメラワークの軌跡を与えるとともに、実際のカメラワークの軌跡における第iフレームの画像の位置を示す。なお、積算値の初期値(Xm(0)、Ym(0)、θm(0))は、それぞれ0にするのが好ましい。 Here, Xm (i), Ym (i), and θm (i) are obtained by integrating the amount of positional deviation (x 0 , y 0 , θ) from the 0th frame image to the i-th frame image for each component. Represents a value (i = 0, 1, 2,...). The integrated values (Xm (i), Ym (i), θm (i)) give the camerawork trajectory at the time of actual video shooting, and the position of the image of the i-th frame in the actual camerawork trajectory. Show. Note that the initial values of the integrated values (Xm (0), Ym (0), θm (0)) are preferably set to 0, respectively.

ステップS14:CPU1は、動画データの全てのフレームの画像について、ステップS11からステップS13までの処理を行ったか否かを判定する。CPU1が、全ての処理を行ったと判定した場合には、ステップS15(YES側)へ移行する。一方、CPU1が、処理が途中であると判定した場合には、ステップS11(NO側)へ移行し、次に隣り合う第1フレームの画像20bと第2フレームの画像に対して、ステップS11からステップS13までの処理を行う。CPU1は、動画データの最後のフレームである第Nフレーム(N=1、2、3、…)の画像までの処理を行い、ステップS15へ移行する。   Step S14: The CPU 1 determines whether or not the processing from step S11 to step S13 has been performed for all the frames of the moving image data. If the CPU 1 determines that all processing has been performed, the process proceeds to step S15 (YES side). On the other hand, if the CPU 1 determines that the process is in progress, the process proceeds to step S11 (NO side). Next, from step S11, the next adjacent first frame image 20b and second frame image are processed. Processing up to step S13 is performed. The CPU 1 performs processing up to the image of the Nth frame (N = 1, 2, 3,...) That is the last frame of the moving image data, and proceeds to step S15.

ここで、図4は、動画データの全てのフレームのうち、第5フレームまでの画像におけるステップS11からステップS13の処理によって求めた、(a)実際のカメラワークのXmとYmとの成分の軌跡、(b)回転成分θmの軌跡の一例を示す。図4(a)の例において、Xm成分の値が大きく変化していることから、ある程度の手振れはあるものの、この実際のカメラワークの軌跡はX方向にパンニングしている場合のものであることが分かる。   Here, FIG. 4 shows (a) the trajectory of the components of Xm and Ym of the actual camera work obtained by the processing from step S11 to step S13 in the image up to the fifth frame among all the frames of the moving image data. (B) An example of the locus of the rotation component θm is shown. In the example of FIG. 4A, since the value of the Xm component has changed greatly, the actual camerawork trajectory is a case of panning in the X direction although there is a certain amount of camera shake. I understand.

ステップS15:CPU1は、ステップS14で求めた実際のカメラワークの軌跡に基づいて、ユーザが所望する最適なカメラワークの軌跡を求める。   Step S15: The CPU 1 obtains the optimum camerawork locus desired by the user based on the actual camerawork locus obtained in Step S14.

ここで、その求め方について簡単に説明する。従来のカメラワークの最適化方法としては、特許文献1等に用いられているDP(Douglas-Pecker)法やB-Spline法等によるものがある。しかしながら、これらの方法による処理では、任意の曲線若しくは直線又は近似曲線等を最適なカメラワークの軌跡と見なしている。そのために、例えば、隣り合う他のフレームの画像と大きく位置がズレたフレームの画像がある場合、最適なカメラワークの軌跡として求めた上記任意の曲線若しくは直線又は近似曲線等からも大きく外れてしまう。その結果、処理して得られた動画を再生した場合、その大きく位置ズレしたフレームの画像は、その全部が見えない又はほんの一部しか見えないということになってしまう。つまり、従来の処理法によって得られた動画は、必ずしも最適なカメラワークの軌跡で且つ見やすくなめらかなものとは言えない。これは、従来の処理法では、何ら制限を与えることなく、数学的に最適な解として求まった上記曲線若しくは直線又は近似曲線を、最適なカメラワークの軌跡としていることに原因がある。   Here, how to obtain it will be briefly described. Conventional camera work optimization methods include the DP (Douglas-Pecker) method and the B-Spline method used in Patent Document 1 and the like. However, in the processing by these methods, an arbitrary curve, a straight line, an approximate curve, or the like is regarded as an optimal camerawork trajectory. For this reason, for example, when there is an image of a frame whose position is greatly deviated from the image of another adjacent frame, the image is greatly deviated from the arbitrary curve, straight line, approximate curve, or the like obtained as the optimal camerawork trajectory. . As a result, when a moving image obtained by processing is reproduced, the image of the frame that has been greatly misaligned is not completely visible or only partially visible. In other words, a moving image obtained by a conventional processing method is not necessarily an optimal camerawork trajectory and is easy to see and smooth. This is because the conventional processing method uses the above-described curve, straight line, or approximate curve obtained as a mathematically optimal solution as an optimal camerawork trajectory without any limitation.

これに対して、本実施形態では、実際のカメラワークの軌跡から最適なカメラワークの軌跡を求めるために、各フレームの画像間において互いに一定の相関を持って所定の制限の範囲内で検索して求める。そして、動画の各フレームの画像の位置を、その最適なカメラワークの軌跡上に来るように補正することによって、見やすくなめらかな動画を生成する。ここで、上記「一定の相関」とは、2つの画像の重なる領域の大きさがある一定値以上を有するということを意味する。また、「見やすくなめらかな動画」とは、各フレームの画像が全く見えなくなったり、一部しか見えないということが起きない動画ということを意味する。   On the other hand, in this embodiment, in order to obtain the optimum camerawork trajectory from the actual camerawork trajectory, search is performed within a predetermined limit with a certain correlation between the images of each frame. Ask. Then, by correcting the position of the image of each frame of the moving image so as to be on the locus of the optimal camera work, a smooth moving image that is easy to see is generated. Here, the “constant correlation” means that the size of the region where two images overlap has a certain value or more. In addition, “smooth moving image that is easy to see” means a moving image in which an image of each frame cannot be seen at all or only a part of the image cannot be seen.

具体的には、本実施形態では、次式(4)で表される式を用いて最適なカメラワークの軌跡を求める。ここで、αiは最適なカメラワークの軌跡における第iフレームの画像の位置(X(i)、Y(i)、θ(i))の3成分のいずれかの成分を表し、βiは実際のカメラワークの軌跡における第iフレームの画像の位置(Xm(i)、Ym(i)、θm(i))の3成分のいずれかの成分を表す。 Specifically, in the present embodiment, an optimal camerawork trajectory is obtained using an expression represented by the following expression (4). Here, α i represents any one of the three components of the position (X (i), Y (i), θ (i)) of the image of the i-th frame in the optimal camerawork trajectory, and β i is This represents one of the three components of the position (Xm (i), Ym (i), θm (i)) of the image of the i-th frame in the actual camerawork trajectory.

数式4Formula 4

Figure 0005251410
Figure 0005251410

CPU1は、各成分において式(4)のパラメータEを最小にする、最適なカメラワークの軌跡であるαi(i=0〜N)の値を求める。そのためには、各成分においてパラメータEを各αiで偏微分して、その偏微分の値が全て0になる時のαiの値が、求める最適なカメラワークの軌跡となる。しかしながら、このままでは、従来のやり方と同じである。そこで、本実施形態では、上述したように式(4)を偏微分して解くにあたり、実際のカメラワークの軌跡における各フレームの画像の位置(Xm(i)、Ym(i)、θm(i))の各成分に、制限である閾値を設けてその閾値の範囲内で解くことによって、最適なカメラワークの軌跡における各フレームの画像の位置(X(i)、Y(i)、θ(i))の各成分のαiの値を求める。これは、不等式拘束条件付き最小化問題として解くことを意味する。この不等式拘束条件付き最小化問題を解くにあたり、本実施形態では、準ニュートン法を用いて行う。なお、準ニュートン法だけでなく、他の解法として共役勾配法、ネルダーミード法又は乗数法等を、即知の不等式拘束条件付き最小化問題の解法とそれらを組み合わせて行ってもよい。 The CPU 1 obtains the value of α i (i = 0 to N) that is the optimal camerawork trajectory that minimizes the parameter E of Equation (4) in each component. For this purpose, the parameter E is partially differentiated by each α i in each component, and the value of α i when the partial differential values are all 0 becomes the optimum camerawork trajectory to be obtained. However, this is the same as the conventional method. Therefore, in the present embodiment, when the equation (4) is partially differentiated and solved as described above, the position of the image of each frame (Xm (i), Ym (i), θm (i )) Is provided with a threshold value that is a limit and solved within the range of the threshold value, whereby the position of the image of each frame (X (i), Y (i), θ ( The value of α i of each component in i)) is obtained. This means solving as a minimization problem with inequality constraints. In this embodiment, the quasi-Newton method is used to solve the minimization problem with an inequality constraint condition. In addition to the quasi-Newton method, a conjugate gradient method, a Nelder mead method, or a multiplier method may be used as another solution method in combination with a solution method for the instant minimization problem with inequality constraints.

図5は、図4の実際のカメラワークの軌跡上における、各フレームの画像の位置(Xm(i)、Ym(i)、θm(i))(●印)を中心にした閾値の範囲を、□印の領域30と領域31とで示す。本実施形態では、ユーザは、各フレームの画像の位置(Xm(i)、Ym(i)、θm(i))での閾値(ΔXm、ΔYm、Δθm)の大きさを、(±10ピクセル、±10ピクセル、±5度)と設定するものとする。なお、図5(b)の回転成分θmの軌跡において、横軸はフレーム数を表すことから本来は閾値というものはないが、回転成分θmの閾値Δθmの範囲を便宜上領域31として見やすくするために一定の幅を持たせて描いている。   FIG. 5 shows a range of threshold values centered on the position (Xm (i), Ym (i), θm (i)) (● mark) of the image of each frame on the actual camerawork trajectory of FIG. , A region 30 and a region 31 indicated by □. In the present embodiment, the user sets the size of the threshold (ΔXm, ΔYm, Δθm) at the position (Xm (i), Ym (i), θm (i)) of each frame image to (± 10 pixels, ± 10 pixels, ± 5 degrees). In the locus of the rotation component θm in FIG. 5B, the horizontal axis represents the number of frames, so there is no threshold value originally, but the range of the rotation component θm threshold Δθm is easy to see as the region 31 for convenience. It is drawn with a certain width.

上述したように、CPU1は、成分毎にパラメータEを各αiで偏微分して、その偏微分の値を最小にする(X(i)、Y(i)、θ(i))の各成分であるαiの値を、領域30及び領域31の範囲内で検索する。その結果、図5に示すように、○印で示された点を繋いだものが求まった最適なカメラワークの軌跡であり、○印が各フレームの画像の位置(X(i)、Y(i)、θ(i))である。なお、回転成分θ(i)の軌跡を示す○印は、上記理由により、必ず各フレームの線上にある。CPU1は、最適なカメラワークの軌跡における各フレームの画像の(X(i)、Y(i)、θ(i))を、記憶部2に記録する。 As described above, the CPU 1 performs partial differentiation on the parameter E for each component by each α i and minimizes the value of the partial differentiation (X (i), Y (i), θ (i)). The value of the component α i is searched within the range of the region 30 and the region 31. As a result, as shown in FIG. 5, an optimal camerawork trajectory obtained by connecting the points indicated by ○ marks is obtained, and the ○ marks indicate the positions of the images (X (i), Y ( i), θ (i)). Note that the mark ◯ indicating the locus of the rotation component θ (i) is always on the line of each frame for the above reason. The CPU 1 records (X (i), Y (i), θ (i)) of each frame image in the optimal camerawork trajectory in the storage unit 2.

ステップS16:CPU1は、ステップS15で求めた最適なカメラワークの軌跡上における各フレームの画像の位置である(X(i)、Y(i)、θ(i))(i=0〜N)を用いて、第0フレームの画像を基準にして、順次各フレームの画像の相対的位置の補正を行う。図6は、第iフレームの画像50とその画像50を(X(i)、Y(i)、θ(i))に基づいて補正した画像51を示す。CPU1は、ΔXmとΔYmとの閾値の幅で画像51の周囲を切り取って画像60を生成し、メモリ(不図示)に記録するとともに、出力装置5に画像60を表示する。なお、本実施形態では、ピクセル単位及び度単位で補正を行ったが、サブピクセル単位の精度で補正を行ってもよい。   Step S16: The CPU 1 is the position of the image of each frame on the optimal camerawork trajectory obtained in Step S15 (X (i), Y (i), θ (i)) (i = 0 to N). Are used to sequentially correct the relative position of the image of each frame with reference to the image of the 0th frame. FIG. 6 shows an image 50 of the i-th frame and an image 51 obtained by correcting the image 50 based on (X (i), Y (i), θ (i)). The CPU 1 cuts the periphery of the image 51 with a threshold width of ΔXm and ΔYm, generates an image 60, records it in a memory (not shown), and displays the image 60 on the output device 5. In the present embodiment, correction is performed in units of pixels and degrees, but correction may be performed with accuracy in units of subpixels.

ステップS17:CPU1は、全てのフレームの画像について、ステップS16の処理を行ったか否かを判定する。CPU1が、全ての処理を行ったと判定した場合には、ステップS18(YES側)へ移行する。一方、CPU1が、処理が途中であると判定した場合には、ステップS16(NO側)へ移行し、次の第(i+1)フレームの画像に対してステップS16の処理を行う。CPU1は、動画データの最後のフレームである第Nフレームの画像の処理が終了するまで行い、ステップS18へ移行する。   Step S17: The CPU 1 determines whether or not the process of step S16 has been performed for all the frame images. If the CPU 1 determines that all processing has been performed, the process proceeds to step S18 (YES side). On the other hand, if the CPU 1 determines that the process is in progress, the process proceeds to step S16 (NO side), and the process of step S16 is performed on the image of the next (i + 1) th frame. The CPU 1 performs processing until the processing of the image of the Nth frame, which is the last frame of the moving image data, is completed, and the process proceeds to step S18.

ステップS18:CPU1は、ステップS16の処理によって得られた最適なカメラワークの軌跡の動画データを記憶部2に記録し終了する。   Step S18: The CPU 1 records the moving image data of the optimal camerawork trajectory obtained by the process of step S16 in the storage unit 2 and ends.

このように本実施形態は、撮影された動画データに基づいて、実際のカメラワークの軌跡を求め、式(4)の不等式拘束条件付き最小化問題を解くことによって、ユーザの希望する最適なカメラワークの軌跡で撮られたなめらかな動画を生成することができる。   As described above, the present embodiment obtains the actual camerawork trajectory based on the captured moving image data, and solves the minimization problem with the inequality constraint condition of Equation (4), thereby obtaining the optimum camera desired by the user. It can generate a smooth video taken along the work track.

また、最適なカメラワークの軌跡上に各フレームの画像が来るように位置を補正するとともに、ΔXmとΔYmとの閾値の幅で画像51の周囲を切り取って、画像60を生成することから、ユーザにとって、見やすくなめらかな動画を取得することができる。
≪実施形態の補足事項≫
本実施形態では、各フレームの画像間における特徴点の抽出及び動きベクトルの検出を、多重解像度変換と併せて、KLT法を用いて行ったが、本発明はこれに限定されない。例えば、特徴点を抽出するためのエッジ抽出を一般的な公知のエッジ抽出方法で行い、動きベクトルの検出を勾配法(LK法)やブロックマッチング法、Hesse法やSIFT法等で行うというように、別々の手法を用いて行ってもよい。
In addition, the position is corrected so that the image of each frame comes on the optimal camerawork trajectory, and the periphery of the image 51 is cut out with the threshold width of ΔXm and ΔYm, and the image 60 is generated. Therefore, it is possible to obtain a smooth video that is easy to view.
≪Supplementary items for the embodiment≫
In the present embodiment, feature point extraction and motion vector detection between images in each frame are performed using the KLT method in combination with multi-resolution conversion, but the present invention is not limited to this. For example, edge extraction for extracting feature points is performed by a general known edge extraction method, and motion vector detection is performed by gradient method (LK method), block matching method, Hesse method, SIFT method, etc. It may be performed using different methods.

なお、本実施形態では、被写体像を動画として撮影した動画データに対してカメラワーク最適化プログラムを適用したが、本発明はこれに限定されず、連写して撮影した静止画に対しても適用可能である。ただし、連写による静止画の場合は、一枚ずつ出力装置5に表示させればよく、動画のように重ね合わせる必要はない。   In the present embodiment, the camera work optimization program is applied to moving image data obtained by shooting a subject image as a moving image. However, the present invention is not limited to this, and the present invention is also applied to still images shot continuously. Is possible. However, in the case of still images by continuous shooting, it is only necessary to display them one by one on the output device 5, and it is not necessary to superimpose like a moving image.

なお、本実施形態では、動画データの第0フレームの画像を基準画像にして、最適なカメラワークの軌跡を求めたが、本発明はこれに限定されない。例えば、動画データのある隣り合うフレームの画像間の位置ズレ量が、所定値(例えば、Δθm=±30度)より大きい場合には、撮像装置がパンニング等をして撮影対象の被写体像が変わったと判断し、被写体像が変わる前後において、互いに異なる動画データとしてそれぞれについてカメラワーク最適化の処理を行ってもよい。この場合、例えば、大きく位置ズレが起きる前の動画データについては、基準画像を第0フレームの画像とし、位置ズレした後の動画データに対しては、位置ズレを起こした直後のフレームの画像を基準画像とすればよい。   In the present embodiment, the optimal camerawork trajectory is obtained using the 0th frame image of the moving image data as a reference image, but the present invention is not limited to this. For example, when the amount of positional deviation between adjacent frames of video data is larger than a predetermined value (for example, Δθm = ± 30 degrees), the imaging device performs panning or the like to change the subject image to be captured. Therefore, before and after the subject image changes, the camera work optimization process may be performed for each different moving image data. In this case, for example, for moving image data before a large positional shift, the reference image is the 0th frame image, and for moving image data after the positional shift, an image of the frame immediately after the positional shift is generated. A reference image may be used.

また、動画データの隣り合うフレームの画像間の位置ズレ量と所定値との比較だけでなく、ステップS12で求める動きベクトルの大きさが所定値より大きい場合には、撮像装置がパンニング等をして撮影対象の被写体像が変わったものと判断するようにしてもよい。或いは、撮像装置に角度センサ等を設けることにより、その角度センサの出力値が所定値よりも大きい場合には、撮像装置がパンニング等をして撮影対象の被写体像が変わったものと判断するようにしてもよい。   In addition to comparing the amount of positional deviation between adjacent frames of moving image data with a predetermined value, the imaging device performs panning or the like when the magnitude of the motion vector obtained in step S12 is larger than the predetermined value. Thus, it may be determined that the subject image to be photographed has changed. Alternatively, by providing an angle sensor or the like in the imaging device, if the output value of the angle sensor is larger than a predetermined value, the imaging device determines that the subject image to be imaged has changed due to panning or the like. It may be.

なお、本実施形態では、式(4)による不等式拘束条件付き最小化問題を、(X(i)、Y(i)、θ(i))の成分毎に計算して求めたが、本発明はこれに限定されず、全ての(X(i)、Y(i)、θ(i))を1つにまとめた、式(4)で不等式拘束条件付き最小化問題を解いてもよい。   In the present embodiment, the inequality constraint conditional minimization problem according to the equation (4) is calculated for each component of (X (i), Y (i), θ (i)). However, the present invention is not limited to this, and the minimization problem with inequality constraints may be solved by Equation (4) in which all (X (i), Y (i), θ (i)) are combined into one.

なお、本実施形態では、(Xm(i)、Ym(i)、θm(i))のそれぞれの閾値(ΔXm、ΔYm、Δθm)の大きさを、(±10ピクセル、±10ピクセル、±5度)と設定したが、本発明はこれに限定されず、任意の値を設定することができる。   In this embodiment, the magnitudes of the respective threshold values (ΔXm, ΔYm, Δθm) of (Xm (i), Ym (i), θm (i)) are set to (± 10 pixels, ± 10 pixels, ± 5). However, the present invention is not limited to this, and an arbitrary value can be set.

なお、本実施形態では、位置の補正をした各フレームの画像の周囲を、閾値ΔXm及びΔYmで切り取ったが、本発明はこれに限定されず、実際のカメラワークの軌跡と最適なカメラワークの軌跡との差分の値が、閾値ΔXm又はΔYmより小さい場合には閾値ΔXm又はΔYmより小さい値で切り取ってもよい。   In this embodiment, the periphery of the image of each frame whose position has been corrected is cut out with the threshold values ΔXm and ΔYm. However, the present invention is not limited to this, and the actual camerawork trajectory and the optimum camerawork When the value of the difference from the locus is smaller than the threshold value ΔXm or ΔYm, the value may be cut off with a value smaller than the threshold value ΔXm or ΔYm.

なお、本実施形態では、位置ズレ量を、隣り合うフレームの画像間の動き情報に基づいて求めたが、本発明ではそれに限定されず、フィールド間の動き情報に基づいて求めてもよい。   In the present embodiment, the positional shift amount is obtained based on motion information between images of adjacent frames. However, the present invention is not limited to this, and may be obtained based on motion information between fields.

なお、本発明に係るカメラワーク最適化プログラムの各ステップを実行する制御部を有する撮像装置に対しても適用可能である。   Note that the present invention is also applicable to an imaging apparatus having a control unit that executes each step of the camera work optimization program according to the present invention.

なお、本発明に係るカメラワーク最適化プログラムを記憶する記録媒体に対しても適用可能である。   Note that the present invention is also applicable to a recording medium that stores a camera work optimization program according to the present invention.

なお、本発明は、その精神又はその主要な特徴から逸脱することなく他の様々な形で実施することができる。そのため、上述した実施形態はあらゆる点で単なる例示にすぎず、限定的に解釈されてはならない。さらに、特許請求の範囲の均等範囲に属する変形や変更は、全て本発明の範囲内である。   It should be noted that the present invention can be implemented in various other forms without departing from the spirit or main features thereof. For this reason, the above-described embodiment is merely an example in all respects and should not be construed in a limited manner. Further, all modifications and changes belonging to the equivalent scope of the claims are within the scope of the present invention.

本発明の一の実施形態に係るカメラワーク最適化プログラムインストールしたコンピュータ10の概念図1 is a conceptual diagram of a computer 10 installed with a camera work optimization program according to an embodiment of the present invention 本実施形態に係るカメラワーク最適化処理における手順を示すフローチャートThe flowchart which shows the procedure in the camera work optimization process which concerns on this embodiment 隣り合うフレームの画像の一例の図Illustration of an example of an image of adjacent frames 実際のカメラワークの軌跡の図Actual camerawork trajectory 実際のカメラワークの軌跡に基づいて求めた最適なカメラワークの軌跡の図Diagram of the optimal camerawork trajectory obtained based on the actual camerawork trajectory 各フレームの画像の位置の補正について説明する図The figure explaining correction of the position of the image of each frame

符号の説明Explanation of symbols

1 CPU、2 記憶部、3 入出力I/F、4 バス、5 出力装置、6 入力装置、10 コンピュータ、20a 第0フレームの画像、20b 第1フレームの画像
1 CPU, 2 storage unit, 3 input / output I / F, 4 bus, 5 output device, 6 input device, 10 computer, 20a 0th frame image, 20b 1st frame image

Claims (10)

被写体像を連撮像して生成された動画データを構成する複数の画像について特徴量抽出し、該特徴に基づいて、前記複数の画像のうち隣り合画像間の位置ズレ量を検出する検出ステップと、
前記検出ステップによって検出した前記画像間の前記位置ズレ量に基づいて、前記動画データを撮像した時の第1のカメラワークの軌跡を求める第1のカメラワーク算出ステップと、
前記第1のカメラワーク算出ステップによって求めた前記第1のカメラワークの軌跡上の位置から所定の閾値の範囲内で第2のカメラワークの軌跡算出する第2のカメラワーク算出ステップと、
前記第2のカメラワーク算出ステップによって求めた前記第2のカメラワークの軌跡上における、前記複数の画像の各々の位置情報に基づいて、前記複数の画像の各々の相対的位置を補正する補正ステップと
をコンピュータに実行させることを特徴とするカメラワーク算出プログラム。
For a plurality of images constituting a continuous captured moving image data generated by an object image extracting feature amount, based on the feature amount, it detects the positional deviation amount between the focus cormorants image adjacent among the plurality of images Detecting step to
Based on the positional shift amount between the image detected by said detection step, a first camera work calculation step of obtaining a trajectory of the first camera work when imaging the moving picture data,
A second camera work calculation step for calculating a second camera work locus within a predetermined threshold range from a position on the locus of the first camera work obtained by the first camera work calculation step;
Correction step of correcting the relative position of each of the plurality of images based on the position information of each of the plurality of images on the trajectory of the second camera work obtained by the second camera work calculation step. A camera work calculation program for causing a computer to execute and.
請求項1に記載のカメラワーク算出プログラムにおいて、
前記補正ステップによって前記相対的位置が補正された前記複数の画像の各々に対して、周囲の画素を前記所定の閾値の大きさの範囲内で切り取って整形するフレーム整形ステップをさらに備えることを特徴とするカメラワーク算出プログラム。
In the camera work calculation program according to claim 1,
The method further comprises a frame shaping step of cutting and shaping surrounding pixels within the predetermined threshold size for each of the plurality of images whose relative positions have been corrected by the correction step. A camera work calculation program.
請求項1又は請求項2に記載のカメラワーク算出プログラムにおいて、
前記検出ステップにおいて検出される前画像間の位置ズレ量は、前記画像面内における一の方向成分、前記一の方向成分に交差する方向成分、及び回転成分を有することを特徴とするカメラワーク算出プログラム。
In the camera work calculation program according to claim 1 or 2,
Positional deviation amount between the pre-Symbol image detected in the detection step, the camera work and having one direction component in the image plane, the direction component intersecting the one direction component, and a rotational component Calculation program.
請求項1ないし請求項3のいずれか1項に記載のカメラワーク算出プログラムにおいて、
前記検出ステップにおいて検出される前画像間の位置ズレ量が所定値より大きい場合には、前記動画データの前記被写体像の対象が変化したと判定するシーン判定ステップをさらに備えることを特徴とするカメラワーク算出プログラム。
In the camera work calculation program according to any one of claims 1 to 3,
Wherein when positional deviation amount between before Symbol image detected in the detection step is larger than the predetermined value, and further comprising determining scene determination step interest has changed in the subject image of the moving image data Camerawork calculation program.
請求項1ないし請求項4のいずれか1項に記載のカメラワーク算出プログラムにおいて、
前記第2のカメラワーク算出ステップは、前記所定の閾値の範囲内で、前記第1のカメラワークの軌跡と前記第2のカメラワークの軌跡との差分の総和が最小になるように、前記第2のカメラワークの軌跡を算出することを特徴とするカメラワーク算出プログラム。
In the camera work calculation program according to any one of claims 1 to 4,
In the second camera work calculation step, the sum of the differences between the trajectory of the first camera work and the trajectory of the second camera work is minimized within the predetermined threshold range . 2. A camera work calculation program for calculating a trajectory of two camera works.
請求項3ないし請求項5のいずれか1項に記載のカメラワーク算出プログラムにおいて、
前記第2のカメラワーク算出ステップは、前記差分の総和を、前記一の方向成分、前記一の方向成分に交差する方向成分、及び前記回転成分毎に行い、それぞれの成分毎に前記差分の総和を、前記それぞれの成分毎の前記所定の閾値の範囲内で最小になるように、前記第2のカメラワークの軌跡を算出することを特徴とするカメラワーク算出プログラム。
In the camera work calculation program according to any one of claims 3 to 5,
The second camera work calculation step performs the sum of the differences for each of the one direction component, the direction component intersecting the one direction component, and the rotation component, and the sum of the differences for each component. , said to minimize within each of said predetermined threshold for each component, camera work calculation program and calculates a trajectory of the second camera work.
請求項1ないし請求項6のいずれか1項に記載のカメラワーク算出プログラムにおいて
前記第2のカメラワーク算出ステップは、隣り合う前記画像間で、互いに一定の相関を持つ所定の閾値の範囲内で前記第2のカメラワークの軌跡を算出することを特徴とするカメラワーク算出プログラム
In the camera work calculation program according to any one of claims 1 to 6 ,
The second camera work calculating step, between the adjacent images, camera work calculation program and calculates a trajectory of the second camera work within a predetermined threshold value having a certain correlation with each other .
請求項7に記載のカメラワーク算出プログラムにおいて
前記一定の相関は、2つの画像の重なる領域の大きさが一定以上有することを特徴とするカメラワーク算出プログラム
In the camera work calculation program according to claim 7 ,
The constant correlation, camerawork calculation program size of an area overlapping the two images are characterized Rukoto that Yusuke certain level.
被写体像を連続して撮像して動画データを生成する撮像部と、An imaging unit that continuously captures subject images and generates moving image data;
請求項1ないし請求項8のいずれか1項に記載のカメラワーク算出プログラムを前記動画データに対して実行する制御部とA control unit that executes the camera work calculation program according to any one of claims 1 to 8 on the moving image data;
を備えることを特徴とする撮像装置。An imaging apparatus comprising:
被写体像を連続撮像して生成された動画データを構成する複数の画像について特徴量を抽出し、該特徴量に基づいて、前記複数の画像のうち隣り合う画像間の位置ズレ量を検出する検出工程と、Detection that extracts feature amounts of a plurality of images constituting moving image data generated by continuously capturing subject images, and detects a positional shift amount between adjacent images among the plurality of images based on the feature amounts. Process,
前記検出工程によって検出した前記画像間の前記位置ズレ量に基づいて、前記動画データを撮像した時の第1のカメラワークの軌跡を求める第1のカメラワーク算出工程と、A first camera work calculation step for obtaining a trajectory of the first camera work when the moving image data is imaged based on the positional deviation amount between the images detected by the detection step;
前記第1のカメラワーク算出工程によって求めた前記第1のカメラワークの軌跡上の位置から所定の閾値の範囲内で第2のカメラワークの軌跡を算出する第2のカメラワーク算出工程と、  A second camera work calculation step for calculating a second camera work locus within a predetermined threshold range from a position on the first camera work locus obtained by the first camera work calculation step;
前記第2のカメラワーク算出工程によって求めた前記第2のカメラワークの軌跡上における、前記複数の画像の各々の位置情報に基づいて、前記複数の画像の各々の相対的位置を補正する補正工程とA correction step of correcting the relative position of each of the plurality of images based on the position information of each of the plurality of images on the trajectory of the second camera work obtained by the second camera work calculation step. When
を備えることを特徴とするカメラワーク算出方法。A camera work calculation method comprising:
JP2008258544A 2008-10-03 2008-10-03 Camera work calculation program, imaging apparatus, and camera work calculation method Active JP5251410B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008258544A JP5251410B2 (en) 2008-10-03 2008-10-03 Camera work calculation program, imaging apparatus, and camera work calculation method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008258544A JP5251410B2 (en) 2008-10-03 2008-10-03 Camera work calculation program, imaging apparatus, and camera work calculation method

Publications (2)

Publication Number Publication Date
JP2010093343A JP2010093343A (en) 2010-04-22
JP5251410B2 true JP5251410B2 (en) 2013-07-31

Family

ID=42255696

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008258544A Active JP5251410B2 (en) 2008-10-03 2008-10-03 Camera work calculation program, imaging apparatus, and camera work calculation method

Country Status (1)

Country Link
JP (1) JP5251410B2 (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8531535B2 (en) 2010-10-28 2013-09-10 Google Inc. Methods and systems for processing a video for stabilization and retargeting
JP5869833B2 (en) * 2011-10-06 2016-02-24 ザインエレクトロニクス株式会社 Camera shake correction processing apparatus and camera shake correction processing method
US9071756B2 (en) * 2012-12-11 2015-06-30 Facebook, Inc. Systems and methods for digital video stabilization via constraint-based rotation smoothing
KR102281184B1 (en) * 2014-11-20 2021-07-23 삼성전자주식회사 Method and apparatus for calibrating image
JP6797566B2 (en) * 2016-06-02 2020-12-09 キヤノン株式会社 Image pickup device, control method of image pickup device, and image processing device
JP6742823B2 (en) * 2016-06-02 2020-08-19 キヤノン株式会社 Image processing apparatus, image processing method, and program
JP6761786B2 (en) * 2017-08-10 2020-09-30 本田技研工業株式会社 Ceiling map creation method, ceiling map creation device and ceiling map creation program
CN114095659B (en) * 2021-11-29 2024-01-23 厦门美图之家科技有限公司 Video anti-shake method, device, equipment and storage medium

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4661514B2 (en) * 2005-10-07 2011-03-30 ソニー株式会社 Image processing apparatus, image processing method, program, and recording medium
JP2007208767A (en) * 2006-02-03 2007-08-16 Seiko Epson Corp Blur correction apparatus, display apparatus, photographing apparatus, electronic apparatus, blur correction method, program, and recording medium
JP4700557B2 (en) * 2006-05-10 2011-06-15 オリンパスイメージング株式会社 Imaging device
JP2007334625A (en) * 2006-06-15 2007-12-27 Sony Corp Image processing method, program of image processing method, recording medium for recording program of image processing method, and image processing apparatus

Also Published As

Publication number Publication date
JP2010093343A (en) 2010-04-22

Similar Documents

Publication Publication Date Title
JP5251410B2 (en) Camera work calculation program, imaging apparatus, and camera work calculation method
US10334168B2 (en) Threshold determination in a RANSAC algorithm
US10410089B2 (en) Training assistance using synthetic images
US8126206B2 (en) Image processing apparatus, image processing method, and program
KR101333871B1 (en) Method and arrangement for multi-camera calibration
JP5580164B2 (en) Optical information processing apparatus, optical information processing method, optical information processing system, and optical information processing program
EP1986154A1 (en) Model-based camera pose estimation
US9171379B2 (en) Hybrid precision tracking
JP2005100407A (en) System and method for creating panorama image from two or more source images
US20100014709A1 (en) Super-resolving moving vehicles in an unregistered set of video frames
CN104463859B (en) A kind of real-time video joining method based on tracking specified point
Whitehead et al. Temporal synchronization of video sequences in theory and in practice
JP6656035B2 (en) Image processing apparatus, imaging apparatus, and control method for image processing apparatus
TWI459325B (en) Digital image processing device and processing method thereof
JP2000298300A (en) Hand shake image correcting method, recording medium, and image pickup device
Taketomi et al. Camera pose estimation under dynamic intrinsic parameter change for augmented reality
CN115334233B (en) Method and system for generating sliding zoom effect
JP2008217526A (en) Image processor, image processing program, and image processing method
JP5449980B2 (en) Motion compensation apparatus and method
JP7118729B2 (en) Information processing device, information processing method and program
JP2007104516A (en) Image processor, image processing method, program, and recording medium
JP2002163647A (en) Device and method for calculating lens distortion coefficient and computer readable recording medium recording lens distortion coefficient calculation program
JP5530391B2 (en) Camera pose estimation apparatus, camera pose estimation method, and camera pose estimation program
US7522189B2 (en) Automatic stabilization control apparatus, automatic stabilization control method, and computer readable recording medium having automatic stabilization control program recorded thereon
JP2006113832A (en) Stereoscopic image processor and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20110929

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120322

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20120928

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20121009

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20121210

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130401

R150 Certificate of patent or registration of utility model

Ref document number: 5251410

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20160426

Year of fee payment: 3

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250