JP2015154334A - Imaging apparatus, control method thereof and control program - Google Patents

Imaging apparatus, control method thereof and control program Download PDF

Info

Publication number
JP2015154334A
JP2015154334A JP2014027599A JP2014027599A JP2015154334A JP 2015154334 A JP2015154334 A JP 2015154334A JP 2014027599 A JP2014027599 A JP 2014027599A JP 2014027599 A JP2014027599 A JP 2014027599A JP 2015154334 A JP2015154334 A JP 2015154334A
Authority
JP
Japan
Prior art keywords
image
resizing
motion vector
original image
optical system
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2014027599A
Other languages
Japanese (ja)
Other versions
JP6282133B2 (en
Inventor
文貴 中山
Fumitaka Nakayama
文貴 中山
見 寺澤
Ken Terasawa
見 寺澤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP2014027599A priority Critical patent/JP6282133B2/en
Publication of JP2015154334A publication Critical patent/JP2015154334A/en
Application granted granted Critical
Publication of JP6282133B2 publication Critical patent/JP6282133B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

PROBLEM TO BE SOLVED: To effectively correct blur in an image by accurately detecting a motion vector.SOLUTION: Image reduction circuits 107, 108 respectively adopt one of images as an original image, use images photographed before the original image as reference images and respectively perform resize processing of the original image and the reference images to obtain a first image and a second image. Under control of a microcomputer 112, a reduction rate determination circuit 106 controls a resize rate in the image reduction circuits in accordance with a focal distance of an optical system. A motion vector detection circuit 109 detects a motion vector between the first image and the second image, and a geometrical deformation parameter estimation circuit 110 and a geometrical deformation circuit 111 correct blur in the original image in accordance with the motion vector.

Description

本発明は、撮像装置、その制御方法、および制御プログラムに関し、特に、撮像装置のブレに起因する画質の劣化を補正する手法に関する。   The present invention relates to an imaging apparatus, a control method thereof, and a control program, and more particularly, to a technique for correcting image quality degradation caused by blurring of the imaging apparatus.

近年、デジタルビデオカメラ又はデジタルカメラなどの撮像装置においては、撮像センサ(撮像素子)および信号処理技術の向上によって高画質の画像を得ることができるようになっている。一方、撮像装置の姿勢変化(例えば、ブレ)に起因して、撮像の結果得られた画像において画質が劣化することがある。このような画質の劣化を防止するため、撮像の結果得られた画像において撮像装置の姿勢変化(つまり、ブレ)を補正する必要がある。   In recent years, in an imaging apparatus such as a digital video camera or a digital camera, it has become possible to obtain a high-quality image by improving an imaging sensor (imaging element) and signal processing technology. On the other hand, the image quality may deteriorate in an image obtained as a result of imaging due to a change in posture of the imaging device (for example, blurring). In order to prevent such deterioration of image quality, it is necessary to correct the posture change (that is, shake) of the imaging apparatus in the image obtained as a result of imaging.

撮像装置の小型化に伴って、姿勢変化の補正を行う必要性が極めて高くなっており、動画および静止画を問わず、安定した画像の取得、そして、複数枚の画像を合成処理する際には、姿勢変化の補正を行うことが不可欠となっている。   With the downsizing of imaging devices, the need to correct posture changes has become extremely high. When acquiring stable images and combining multiple images, regardless of whether they are movies or still images It is indispensable to correct the posture change.

ところで、撮像装置の姿勢変化を得る際には、一般に、角速度センサ(例えば、ジャイロセンサ)又は加速度センサなどのセンシングデバイスが用いられている。さらに、センシングデバイスを用いる代わりに、入力画像と過去の参照画像とに応じて被写体の動きを検出して姿勢変化を得る所謂動きベクトル検出手法が用いられることがある。   By the way, when obtaining a posture change of the image pickup apparatus, a sensing device such as an angular velocity sensor (for example, a gyro sensor) or an acceleration sensor is generally used. Furthermore, instead of using a sensing device, a so-called motion vector detection method that detects a motion of a subject according to an input image and a past reference image to obtain a posture change may be used.

動画撮影又は静止画の連写などの時間制約の高い撮影状況において、撮像装置で動きベクトル検出処理をリアルタイムに行う場合には、処理時間、信号処理回路の規模、メモリ、およびメモリバス帯域などの点で制約がある。そして、このような制約下においては、リソース負荷の高い処理によって高精度で多数の動きベクトルを安定して逐次取得することは困難である。   When performing motion vector detection processing in real time in a shooting situation with high time constraints such as video shooting or continuous shooting of still images, processing time, signal processing circuit scale, memory, memory bus bandwidth, etc. There are some restrictions. Under such restrictions, it is difficult to stably and sequentially acquire a large number of motion vectors with high accuracy by processing with a high resource load.

このような問題に対処するため、例えば、動きベクトル検出のための前処理である画像縮小処理の縮小率を制御して処理負荷を軽減するようにした撮像装置が知られている(特許文献1参照)。   In order to deal with such a problem, for example, an imaging apparatus is known that reduces the processing load by controlling the reduction rate of image reduction processing, which is preprocessing for motion vector detection (Patent Document 1). reference).

特開2010−252259号公報JP 2010-252259 A

上述の特許文献1においては、MPEG又はAVCHDなどのフレーム間圧縮符号化の際に、予測ベクトルの大きさなどによって動きベクトル誤差に起因する符号化の際の画質劣化の影響度を推定して、動きベクトル探索の際の縮小率を制御している。   In the above-mentioned Patent Document 1, when performing inter-frame compression encoding such as MPEG or AVCHD, the degree of influence of image quality degradation at the time of encoding due to a motion vector error is estimated based on the size of a prediction vector, etc. Controls the reduction ratio in motion vector search.

しかしながら、画像において複数の領域から複数の動きベクトルを検出して、画像のブレを補正する際には、動きベクトル探索に用いる画像の縮小率を制御する必要がある。例えば、撮像装置の姿勢変化成分および撮影状況に応じて、動きベクトルの誤差レベルと検出ベクトル数とを満たすように縮小率を制御する必要がある。   However, when correcting a motion blur by detecting a plurality of motion vectors from a plurality of areas in an image, it is necessary to control a reduction rate of the image used for motion vector search. For example, it is necessary to control the reduction ratio so as to satisfy the error level of the motion vector and the number of detected vectors in accordance with the posture change component of the imaging device and the shooting situation.

そして、縮小率が姿勢変化成分および撮影状況に応じて適切に制御されないと、動きベクトルを精度よく検出することが困難となって、結果的に画像におけるブレを良好に補正することができない。   If the reduction rate is not appropriately controlled according to the posture change component and the shooting situation, it is difficult to accurately detect the motion vector, and as a result, it is not possible to correct the blur in the image satisfactorily.

従って、本発明の目的は、画像における動きベクトルを精度よく検出して画像におけるブレを良好に補正することのできる撮像装置、その制御方法、および制御プログラムを提供することにある。   Accordingly, an object of the present invention is to provide an imaging apparatus, a control method thereof, and a control program capable of accurately detecting a motion vector in an image and correcting a blur in the image satisfactorily.

上記の目的を達成するため、本発明による撮像装置は、焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置であって、前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズ手段と、前記光学系の焦点距離に応じて、前記リサイズ手段におけるリサイズ率を制御する制御手段と、前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出手段と、前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正手段と、を有することを特徴とする。   In order to achieve the above object, an image pickup apparatus according to the present invention is an image pickup apparatus that includes an optical system having a variable focal length and that captures a plurality of temporally continuous images via the optical system. Resizing means that uses one of the original image as an original image, an image taken before the original image as a reference image, and resizes the original image and the reference image to form a first image and a second image, respectively. Control means for controlling the resizing rate in the resizing means in accordance with the focal length of the optical system, and motion vector detecting means for detecting a motion vector between the first image and the second image. And blur correction means for correcting blur of the original image in accordance with the motion vector.

本発明による制御方法は、焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置の制御方法であって、前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズステップと、前記光学系の焦点距離に応じて、前記リサイズステップで行われるリサイズ処理におけるリサイズ率を制御する制御ステップと、前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出ステップと、前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正ステップと、を有することを特徴とする。   A control method according to the present invention is a control method for an imaging apparatus that includes an optical system having a variable focal length, and that captures a plurality of temporally continuous images via the optical system. A resizing step to resize the original image and the reference image into a first image and a second image, respectively, using the image taken before the original image as a reference image, and the optical system; A control step for controlling a resizing rate in the resizing process performed in the resizing step according to a focal length of the image, and a motion vector detecting step for detecting a motion vector between the first image and the second image, And a blur correction step of correcting blur of the original image in accordance with the motion vector.

本発明による制御プログラムは、焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置で用いられる制御プログラムであって、前記撮像装置が備えるコンピュータに、前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズステップと、前記光学系の焦点距離に応じて、前記リサイズステップで行われるリサイズ処理におけるリサイズ率を制御する制御ステップと、前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出ステップと、前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正ステップと、を実行させることを特徴とする。   A control program according to the present invention is a control program used in an imaging apparatus that includes an optical system having a variable focal length and captures a plurality of temporally continuous images via the optical system. The computer uses one of the images as an original image, an image taken before the original image as a reference image, and resizes the original image and the reference image, respectively. An image resizing step, a control step of controlling a resizing rate in the resizing process performed in the resizing step in accordance with a focal length of the optical system, and between the first image and the second image. A motion vector detection step for detecting a motion vector and a blur correction step for correcting blur of the original image according to the motion vector are executed. And characterized in that.

本発明によれば、光学系の焦点距離に応じて動きベクトル検出用の画像である原画像および参照画像のリサイズ率を制御するようにしたので、動きベクトルを精度よく検出することができる。その結果、ぶれが良好に補正された画像を生成することができる。   According to the present invention, since the resizing rate of the original image and the reference image, which are images for motion vector detection, is controlled according to the focal length of the optical system, the motion vector can be detected with high accuracy. As a result, it is possible to generate an image in which blurring is corrected favorably.

本発明の第1の実施形態による撮像装置の一例についてその構成を示すブロック図である。1 is a block diagram illustrating a configuration of an example of an imaging apparatus according to a first embodiment of the present invention. 図1に示すカメラにおける撮影動作を説明するためのフローチャートである。3 is a flowchart for explaining a photographing operation in the camera shown in FIG. 1. 図2に示す縮小率決定回路で設定される縮小率と検出される動きベクトルの数との関係を模式的に示す図である。It is a figure which shows typically the relationship between the reduction rate set by the reduction rate determination circuit shown in FIG. 2, and the number of detected motion vectors. 図2に示す縮小率決定回路で設定される縮小率と検出される動きベクトルの精度との関係を模式的に示す図である。It is a figure which shows typically the relationship between the reduction rate set by the reduction rate determination circuit shown in FIG. 2, and the precision of the detected motion vector. 図3および図4に示す関係に基づいて縮小率と残ベクトル数およびベクトル精度との関係を纏めて示す図である。It is a figure which shows collectively the relationship between a reduction rate, the number of remaining vectors, and vector accuracy based on the relationship shown in FIG. 3 and FIG. レンズの焦点距離と縮小率との関係を説明するための図であり、(a)はレンズの焦点距離と縮小率との関係の一例を示す図、(b)、レンズの焦点距離と縮小率との関係の他の例を示す図である。It is a figure for demonstrating the relationship between the focal distance of a lens, and a reduction rate, (a) is a figure which shows an example of the relationship between the focal distance of a lens, and a reduction rate, (b), the focal length of a lens, and a reduction rate It is a figure which shows the other example of a relationship. 撮像の結果得られた画像と動きベクトルとの関係の一例を説明するための図であり、(a)は焦点距離が短い場合(ワイド端)の撮像画像と動きベクトルとの関係を示す図、(b)は焦点距離が長い場合(テレ端)の撮像画像と動きベクトルとの関係を示す図である。It is a figure for demonstrating an example of the relationship between the image acquired as a result of imaging, and a motion vector, (a) is a figure which shows the relationship between the captured image and motion vector when a focal distance is short (wide end), (B) is a figure which shows the relationship between the captured image and motion vector when a focal distance is long (tele end). レンズの絞り値(F値)又はあおり係数を変化させた際の焦点距離と縮小率との関係の一例を説明するための図であり、(a)はレンズの絞り値(F値)を変化させた際の焦点距離と縮小率との関係を示す図、(b)はあおり係数を変化させた際の焦点距離と縮小率との関係を示す図である。It is a figure for demonstrating an example of the relationship between the focal distance at the time of changing the aperture value (F value) or tilting coefficient of a lens, and a reduction ratio, (a) is changing the aperture value (F value) of a lens. FIG. 5B is a diagram showing the relationship between the focal length and the reduction ratio when changing the tilt coefficient. FIG. 図1に示す動きベクトル検出回路で行われるテンプレートマッチングによる動きベクトルの検出を説明するための図であり、(a)は原画像を示す図、(b)は参照画像を示す図である。FIG. 2 is a diagram for explaining detection of a motion vector by template matching performed by the motion vector detection circuit shown in FIG. 1, (a) is a diagram showing an original image, and (b) is a diagram showing a reference image. 本発明の第2の実施形態によるカメラの一例についてその構成を示すブロック図である。It is a block diagram which shows the structure about an example of the camera by the 2nd Embodiment of this invention. 図10に示すカメラで行われる撮影動作の一例を説明するためのフローチャートである。11 is a flowchart for explaining an example of a photographing operation performed by the camera shown in FIG. 本発明の第3の実施形態によるカメラの一例についてその構成を示すブロック図である。It is a block diagram which shows the structure about an example of the camera by the 3rd Embodiment of this invention. 図12に示すカメラにおいて角度ぶれ量を変化させた際の焦点距離と縮小率との関係を示す図である。It is a figure which shows the relationship between the focal distance at the time of changing the amount of angular blurring in the camera shown in FIG. 12, and a reduction rate. 本発明の第4の実施形態によるカメラの一例についてその構成を示すブロック図である。It is a block diagram which shows the structure about an example of the camera by the 4th Embodiment of this invention.

以下、本発明の実施の形態による撮像装置の一例について図面を参照して説明する。   Hereinafter, an example of an imaging apparatus according to an embodiment of the present invention will be described with reference to the drawings.

[第1の実施形態]
図1は、本発明の第1の実施形態による撮像装置の一例についてその構成を示すブロック図である。
[First Embodiment]
FIG. 1 is a block diagram showing the configuration of an example of an imaging apparatus according to the first embodiment of the present invention.

図示の撮像装置は、例えば、デジタルカメラ(以下単にカメラと呼ぶ)であり、カメラは撮像光学系(以下単に光学系と呼ぶ)101を備えている。この光学系101は焦点距離が可変の光学系であり、カメラは光学系101を介して時間的に連続する複数の画像を撮影する。   The illustrated imaging apparatus is, for example, a digital camera (hereinafter simply referred to as a camera), and the camera includes an imaging optical system (hereinafter simply referred to as an optical system) 101. The optical system 101 is an optical system having a variable focal length, and the camera captures a plurality of temporally continuous images via the optical system 101.

光学系101を通過した被写体像(光学像)は撮像素子102に結像される。この撮像素子102は、CCDセンサ又はCMOSセンサなどであり、光学像に応じた電気信号(アナログ信号)をカメラ信号処理回路103に出力する。   A subject image (optical image) that has passed through the optical system 101 is formed on the image sensor 102. The image sensor 102 is a CCD sensor or a CMOS sensor, and outputs an electrical signal (analog signal) corresponding to the optical image to the camera signal processing circuit 103.

カメラ信号処理回路103には、例えば、A/D変換回路、オートゲイン制御回路(AGC)、およびオートホワイトバランス回路(AWB)が含まれており、カメラ信号処理回路103はアナログ信号(つまり、カメラ信号)をA/D変換によってデジタル信号とした後、当該デジタル信号に対して所定の画像処理を施して映像信号(画像データともいう)を生成する。なお、光学系101、撮像素子102、およびカメラ信号処理回路103によって画像データの取得を行う撮像系が構成される。   The camera signal processing circuit 103 includes, for example, an A / D conversion circuit, an auto gain control circuit (AGC), and an auto white balance circuit (AWB). The camera signal processing circuit 103 is an analog signal (that is, a camera Signal) is converted into a digital signal by A / D conversion, and then a predetermined image process is performed on the digital signal to generate a video signal (also referred to as image data). The optical system 101, the image sensor 102, and the camera signal processing circuit 103 constitute an image capturing system that acquires image data.

カメラ信号処理回路103の出力である映像信号はメモリ104に送られ、メモリ104は映像信号の1フレーム又は複数のフレーム(つまり、フレーム画像)を一時的に保持又は保存する。縮小率決定回路106は、後述するようにして、フレーム画像を縮小する際の縮小率を決定する。画像縮小回路107および108は、縮小率決定回路106によって決定された縮小率に基づいて、メモリ104から入力されるフレーム画像に対して縮小処理を施して、それぞれ第1の縮小画像および第2の縮小画像を出力する。   The video signal output from the camera signal processing circuit 103 is sent to the memory 104, and the memory 104 temporarily holds or stores one frame or a plurality of frames (that is, frame images) of the video signal. The reduction rate determination circuit 106 determines a reduction rate when reducing the frame image as described later. The image reduction circuits 107 and 108 perform a reduction process on the frame image input from the memory 104 based on the reduction rate determined by the reduction rate determination circuit 106, respectively, so that the first reduced image and the second reduced image are respectively received. Output a reduced image.

動きベクトル検出回路109では、画像縮小回路107および108から入力される2枚のフレーム画像(つまり、第1の縮小画像および第2の縮小画像)間の動きベクトルを検出する。幾何変形パラメータ推定回路110は、動きベクトル検出回路109によって検出された動きベクトルを基づいて、フレーム画像間におけるブレの動き補正量を幾何変形パラメータとして出力する。   The motion vector detection circuit 109 detects a motion vector between the two frame images (that is, the first reduced image and the second reduced image) input from the image reduction circuits 107 and 108. Based on the motion vector detected by the motion vector detection circuit 109, the geometric deformation parameter estimation circuit 110 outputs a motion correction amount of blur between frame images as a geometric deformation parameter.

マイコン112は、幾何変形パラメータに応じて幾何変形回路111を制御して、幾何変形回路111によってメモリ104から入力されるフレーム画像に対してブレを補正するための幾何変形処理を行う。なお、マイコン112はカメラ全体の制御を司る。   The microcomputer 112 controls the geometric deformation circuit 111 according to the geometric deformation parameter, and performs a geometric deformation process for correcting blurring on the frame image input from the memory 104 by the geometric deformation circuit 111. The microcomputer 112 controls the entire camera.

図2は、図1に示すカメラにおける撮影動作を説明するためのフローチャートである。なお、図示のフローチャートに係る処理はマイコン112の制御下で行われる。   FIG. 2 is a flowchart for explaining a photographing operation in the camera shown in FIG. Note that the processing according to the illustrated flowchart is performed under the control of the microcomputer 112.

撮影動作が開始されると、マイコン112の制御下で光学系101によって撮像素子102に被写体像が結像する。そして、撮像素子102の出力であるアナログ信号がカメラ信号処理回路103に与えられて、カメラ信号処理回路103はアナログ信号をA/D変換して得られたデジタル信号に対して所定の画像処理を施して映像信号を生成する(ステップS201:画像入力)。   When the photographing operation is started, a subject image is formed on the image sensor 102 by the optical system 101 under the control of the microcomputer 112. Then, an analog signal that is an output of the image sensor 102 is supplied to the camera signal processing circuit 103, and the camera signal processing circuit 103 performs predetermined image processing on the digital signal obtained by A / D converting the analog signal. To generate a video signal (step S201: image input).

カメラ信号処理回路103は、A/D変換回路によってアナログ信号を、例えば、12ビットのデジタル信号に変換する。カメラ信号処理回路103は、AGCおよびAWBによって信号レベルを補正するとともに白レベル補正を行って映像信号を生成する。そして、この映像信号はメモリ104に保持される。   The camera signal processing circuit 103 converts an analog signal into, for example, a 12-bit digital signal by an A / D conversion circuit. The camera signal processing circuit 103 corrects the signal level using AGC and AWB and also performs white level correction to generate a video signal. This video signal is held in the memory 104.

図示のカメラにおいては、所定のフレームレートで順次フレーム画像が生成されて、当該フレーム画像がメモリ104に保持される。そして、メモリ104に保持された等倍サイズのフレーム画像は画像縮小回路107および108に入力される。なお、メモリ104に保持されるフレーム画像は順次更新される。   In the illustrated camera, frame images are sequentially generated at a predetermined frame rate, and the frame images are held in the memory 104. Then, the same size frame image held in the memory 104 is input to the image reduction circuits 107 and 108. Note that the frame images held in the memory 104 are sequentially updated.

続いて、マイコン112の制御下で、縮小率決定回路106は、決定した画像の縮小率を画像縮小回路107および108に設定する(ステップS202)。なお、縮小率決定回路106による縮小率の決定方法については、後述の図3〜図6を用いて説明するが、ここでは、縮小率と検出される動きベクトルの精度および数との関係について説明する。   Subsequently, under the control of the microcomputer 112, the reduction ratio determination circuit 106 sets the determined image reduction ratio in the image reduction circuits 107 and 108 (step S202). The reduction rate determination method performed by the reduction rate determination circuit 106 will be described with reference to FIGS. 3 to 6 described later. Here, the relationship between the reduction rate and the accuracy and number of detected motion vectors will be described. To do.

図3は、図2に示す縮小率決定回路106で設定される縮小率と検出される動きベクトルの数との関係を模式的に示す図である。   FIG. 3 is a diagram schematically showing the relationship between the reduction rate set by the reduction rate determination circuit 106 shown in FIG. 2 and the number of detected motion vectors.

図3において、横軸は縮小率を示し、縮小率が大きくなる程、縮小後の画像のサイズが大きくなる。そして、縮小率=1では画像の縮小は行われない。縦軸は検出された動きベクトルにおいて信頼度が高いと判定された動きベクトルの数(これを残ベクトル数とする)を示す。ここで、動きベクトルの信頼度として、例えば、どのようなテクスチャを有する領域から検出された動きベクトルであるかに応じて決定されるものがある。   In FIG. 3, the horizontal axis indicates the reduction ratio, and the larger the reduction ratio, the larger the size of the image after reduction. When the reduction ratio = 1, the image is not reduced. The vertical axis represents the number of motion vectors determined to have high reliability in the detected motion vectors (this is the number of remaining vectors). Here, as the reliability of the motion vector, for example, there is one determined depending on what kind of texture the motion vector is detected from.

例えば、低コントラストの領域又は繰り返しパターンを含む領域は、テンプレートマッチングによる動きベクトル検出が難しい領域であるので、動きベクトルが正しく検出される可能性が低い。このようなテクスチャの判定を行うため、ここでは、テンプレート内の画素の輝度値について平均値および分散値を求めて、当該領域が低コントラスト領域又は繰り返しパターン領域であるか否かを判定する。   For example, a low-contrast region or a region including a repetitive pattern is a region where it is difficult to detect a motion vector by template matching, and therefore there is a low possibility that a motion vector is correctly detected. In order to perform such texture determination, here, an average value and a variance value are obtained for the luminance values of the pixels in the template, and it is determined whether or not the area is a low contrast area or a repeated pattern area.

低コントラスト領域又は繰り返しパターン領域であると判定すると、当該領域において検出された動きベクトルは信頼度が低いものとして除外する。このような判定を全ての動きベクトルに対して行って、最終的に残った信頼度の高い動きベクトルの数が残ベクトル数とされる。   If it is determined that the region is a low-contrast region or a repetitive pattern region, motion vectors detected in the region are excluded as having low reliability. Such a determination is performed on all the motion vectors, and the number of highly reliable motion vectors remaining finally becomes the number of remaining vectors.

図3を参照すると、縮小率が1に近い、つまり、動きベクトルの検出に用いる画像サイズが大きい場合には、テンプレートとの相関が高い箇所が複数個発生する傾向が強くなって、誤った動きベクトルが検出されやすくなる。そして、これら誤った動きベクトルは誤差の要因となるためもちいることができない。さらに、テンプレート内のテクスチャが乏しくなって、低コントラスト領域と判定されて除外される動きベクトルも増加するので、残ベクトル数は減少する。   Referring to FIG. 3, when the reduction ratio is close to 1, that is, when the image size used for motion vector detection is large, a tendency to generate a plurality of portions having high correlation with the template is increased, resulting in erroneous motion. Vectors are easier to detect. These erroneous motion vectors cannot be used because they cause errors. Furthermore, the number of remaining vectors decreases because the texture in the template becomes poor and the number of motion vectors that are determined to be low-contrast regions and are excluded increases.

一方、縮小率が0に近い、つまり、動きベクトルの検出に用いる画像サイズが小さい場合には、テンプレート内に画像の広い領域におけるテクスチャが入り込むことになる。このため、低コントラスト又は繰り返しの判定で除外されにくくなって、残ベクトル数が増加する。   On the other hand, when the reduction ratio is close to 0, that is, when the image size used for motion vector detection is small, the texture in a wide area of the image enters the template. For this reason, it becomes difficult to be excluded by low contrast or repeated determination, and the number of remaining vectors increases.

図4は、図2に示す縮小率決定回路106で設定される縮小率と検出される動きベクトルの精度との関係を模式的に示す図である。   FIG. 4 is a diagram schematically showing the relationship between the reduction rate set by the reduction rate determination circuit 106 shown in FIG. 2 and the accuracy of the detected motion vector.

図4において、横軸は縮小率を示し、縦軸は動きベクトルの検出精度を示す。ここで、縮小率が1に近い、つまり、動きベクトル検出に用いる画像サイズが大きい場合には、画像が明瞭であるため、個々の動きベクトルの精度は向上する。一方、縮小率が0に近い場合には、縮小処理によるローパスフィルタ効果によって画像が不鮮明になって、個々の動きベクトルの検出精度は低下する。   In FIG. 4, the horizontal axis represents the reduction ratio, and the vertical axis represents the motion vector detection accuracy. Here, when the reduction ratio is close to 1, that is, when the image size used for motion vector detection is large, the accuracy of each motion vector is improved since the image is clear. On the other hand, when the reduction ratio is close to 0, the image becomes unclear due to the low-pass filter effect by the reduction process, and the detection accuracy of each motion vector is lowered.

なお、画像サイズはどこまでも小さくしてよいというものではなく、検出精度が低下しても検知限以下の精度を保つことができるように、図4に縮小率限界501で示すように縮小率に制限を設ける必要がある。ここでは、検知限とは正しい動きベクトルと同一とみなすことができる精度の限界をいい、例えば、動きベクトルを用いて画像の幾何変形を行った際に、正しい動きベクトルを用いて幾何変形を行った画像との違いが目視では分からない程度の検出精度のことをいう。   It should be noted that the image size is not limited to any extent, and is limited to the reduction rate as shown by the reduction rate limit 501 in FIG. 4 so that the accuracy below the detection limit can be maintained even if the detection accuracy is lowered. It is necessary to provide. Here, the detection limit is a limit of accuracy that can be regarded as the same as a correct motion vector. For example, when a geometric deformation of an image is performed using a motion vector, the geometric deformation is performed using the correct motion vector. The detection accuracy is such that the difference from the observed image cannot be visually confirmed.

また、幾何変形パラメータを算出する際には、所謂並進成分の動きのみでなく、回転成分および所謂あおり成分の動きを推定する必要がある。このため、画像全体から多くの動きベクトルを検出する必要があり、縮小率が0に近い状態が標準状態であるものとする。   Further, when calculating the geometric deformation parameter, it is necessary to estimate not only the movement of the so-called translational component but also the movement of the rotation component and the so-called tilting component. For this reason, it is necessary to detect many motion vectors from the entire image, and a state in which the reduction rate is close to 0 is a standard state.

図5は、図3および図4に示す関係に基づいて縮小率と残ベクトル数およびベクトル精度との関係を纏めて示す図である。   FIG. 5 is a diagram collectively showing the relationship between the reduction ratio, the number of remaining vectors, and the vector accuracy based on the relationships shown in FIGS. 3 and 4.

図5から、標準的な精度で多数の動きベクトルを検出する場合と少数でも高精度で動きベクトルを検出する場合とを使い分ける際には、動きベクトルの検出に用いる画像のサイズを変更すればよいことが分かる。   From FIG. 5, when properly using a case where a large number of motion vectors are detected with standard accuracy and a case where a motion vector is detected with high accuracy even with a small number, the size of an image used for detecting a motion vector may be changed. I understand that.

ここまで、画像の縮小率を変更することによって検出される動きベクトルの精度と残数とがどのように変化するかについて説明したが、続いて、光学系101に備えられたレンズの焦点距離に応じてどのように縮小率を変化させればよいかについて説明する。   Up to this point, it has been described how the accuracy and remaining number of motion vectors detected by changing the reduction ratio of the image change. Subsequently, the focal length of the lens provided in the optical system 101 is changed. A description will be given of how the reduction ratio should be changed accordingly.

図6は、レンズの焦点距離と縮小率との関係を説明するための図である。そして、図6(a)は、レンズの焦点距離と縮小率との関係の一例を示す図であり、図6(b)は、レンズの焦点距離と縮小率との関係の他の例を示す図である。   FIG. 6 is a diagram for explaining the relationship between the focal length of the lens and the reduction ratio. 6A shows an example of the relationship between the focal length of the lens and the reduction rate, and FIG. 6B shows another example of the relationship between the focal length of the lens and the reduction rate. FIG.

図6において、横軸は焦点距離を示し、縦軸は縮小率を示す。縮小率が大きくなる程、画像サイズは大きくなる。図6においては焦点距離が長くなるにつれて、縮小率を大きくして、画像サイズを大きくする。図6(a)に示す例では、焦点距離と縮小率との関係を1次関数に応じて変化させており、図6(b)に示す例では、焦点距離と縮小率との関係を2次関数に応じて変化させている。   In FIG. 6, the horizontal axis indicates the focal length, and the vertical axis indicates the reduction ratio. As the reduction ratio increases, the image size increases. In FIG. 6, as the focal length becomes longer, the reduction ratio is increased to increase the image size. In the example shown in FIG. 6A, the relationship between the focal length and the reduction rate is changed according to a linear function. In the example shown in FIG. 6B, the relationship between the focal length and the reduction rate is 2. It is changed according to the next function.

図6に示す関係を考慮すると、縮小率が1に近い、つまり、動きベクトルの検出に用いる画像サイズが大きい場合には、明瞭な画像で動きベクトルの検出が行われるので、検出される動きベクトルの精度は向上する。また、テンプレートとの相関が高い箇所が複数個発生する傾向が強くなって、誤った動きベクトルが検出されやすくなる。そして、誤った動きベクトルは誤差の要因となるので用いることができない。さらに、テンプレート内のテクスチャが乏しくなって、低コントラスト領域と判定されて除外される動きベクトルが増加するので、残ベクトル数は減少する。   In consideration of the relationship shown in FIG. 6, when the reduction ratio is close to 1, that is, when the image size used for motion vector detection is large, the motion vector is detected with a clear image. The accuracy of is improved. In addition, there is a strong tendency to generate a plurality of locations having high correlation with the template, and erroneous motion vectors are easily detected. Incorrect motion vectors cannot be used because they cause errors. Furthermore, the number of remaining vectors decreases because the texture in the template becomes poor and the number of motion vectors that are determined to be low-contrast regions and are excluded increases.

一方、縮小率が0に近い、つまり、動きベクトルの検出に用いる画像サイズが小さい場合には、不明瞭な画像において動きベクトルの検出が行われるので、検出される動きベクトルの精度は低下する。また、テンプレート内において画像の広い領域のテクスチャが入り込むことになるので、低コントラスト又は繰り返しの判定によって除外されにくくなって、残ベクトル数は増加する。   On the other hand, when the reduction ratio is close to 0, that is, when the image size used for detecting the motion vector is small, the motion vector is detected in an unclear image, so the accuracy of the detected motion vector is lowered. In addition, since a texture of a wide area of the image enters in the template, it becomes difficult to be excluded by low contrast or repeated determination, and the number of remaining vectors increases.

図7は、撮像の結果得られた画像と動きベクトルとの関係の一例を説明するための図である。そして、図7(a)は焦点距離が短い場合(ワイド端)の撮像画像と動きベクトルとの関係を示す図であり、図7(b)は焦点距離が長い場合(テレ端)の撮像画像と動きベクトルとの関係を示す図である。   FIG. 7 is a diagram for explaining an example of a relationship between an image obtained as a result of imaging and a motion vector. FIG. 7A is a diagram showing the relationship between the captured image and the motion vector when the focal length is short (wide end), and FIG. 7B is the captured image when the focal length is long (tele end). It is a figure which shows the relationship between a motion vector.

図7(a)および図7(b)においては、撮影の際のカメラの動きは同一であるものとする。また、ここでは、カメラは、下から上にあおる動きをしているものとする。図7(a)に示すように、ワイド端で撮影した場合には、画面の上部では動きベクトルが大きくなり、画面の下側に行くにつれて動きベクトルが小さくなる動きとして現れる。一方、図7(b)に示すように、テレ端で撮影した場合には、同一のカメラの動きであっても、検出される動きベクトルは並進成分の動きとして現れる。   In FIGS. 7A and 7B, it is assumed that the movement of the camera at the time of shooting is the same. Here, it is assumed that the camera moves from the bottom to the top. As shown in FIG. 7A, when the image is taken at the wide end, the motion vector increases at the top of the screen, and the motion vector appears as a motion that decreases toward the lower side of the screen. On the other hand, as shown in FIG. 7B, when the image is taken at the tele end, the detected motion vector appears as a translational component motion even for the same camera motion.

よって、図7(a)に示すように焦点距離が短い場合には、動きは並進のみではなく、あおりも顕著に表れるので、動きを推定する際には、画像の一部の領域において動きベクトルを検出することなく、画像全体から多数の動きベクトルを検出する必要がある。   Therefore, when the focal length is short as shown in FIG. 7A, not only the translation but also the tilt appears remarkably. Therefore, when estimating the motion, the motion vector in a partial region of the image. It is necessary to detect a large number of motion vectors from the entire image without detecting.

このため、ワイド端において撮影した場合には、画像の縮小率を大きくして動きベクトルの検出に用いる画像のサイズを、例えば、1/8サイズの大きさとして、画像全域から多数の動きベクトルを検出する。なお、図示の例では、あおりの動きの場合について説明したが、回転又は拡大縮小の動きについても同様であり、画像全体から多数の動きベクトルを検出する必要がある。   For this reason, when the image is taken at the wide end, the size of the image used for detecting the motion vector is increased by increasing the image reduction ratio, for example, a size of 1/8 size, and a large number of motion vectors are obtained from the entire image. To detect. In the illustrated example, the case of tilt movement has been described, but the same applies to rotation or enlargement / reduction movement, and it is necessary to detect a large number of motion vectors from the entire image.

一方、図7(b)に示すように焦点距離が長い場合には、動きは並進の動きが支配的となって、カメラの動きに回転およびあおりの動きがあったとしても、撮像の結果得られた画像に生じる動きは並進として近似することができる。この場合には、画像全体から多数の動きベクトルを検出する必要はないので、検出すべき動きベクトルの数は少なくてもよい。   On the other hand, as shown in FIG. 7B, when the focal length is long, the translational movement is dominant in the movement, and even if the movement of the camera includes rotation and tilt movement, the result of imaging is obtained. The motion that occurs in the captured image can be approximated as translation. In this case, since it is not necessary to detect a large number of motion vectors from the entire image, the number of motion vectors to be detected may be small.

しかしながら、テレ端で生じる画素の移動量はワイド端に比べて大きくなるので、ブレを高精度に補正する必要がある。従って、テレ端で撮影した場合には、画像の縮小率を小さくして動きベクトルの検出に用いる画像サイズを、例えば、等倍又は1/2サイズの大きさとして、少ないベクトル数で、かつ高精度に動きベクトルの検出を行えばよい。   However, since the amount of pixel movement that occurs at the tele end is larger than that at the wide end, blurring must be corrected with high accuracy. Therefore, when the image is taken at the tele end, the image size used for motion vector detection with a reduced image reduction rate is reduced to a high number of vectors with a small number of vectors, for example, the same size or 1/2 size. What is necessary is just to detect a motion vector accurately.

なお、焦点距離に対する縮小率の変化について図7に示す例に限られず、例えば、レンズの絞り値(F値)又はあおり係数に応じて焦点距離と縮小率との関係を変更するようにしてもよい。   Note that the change in the reduction ratio with respect to the focal length is not limited to the example shown in FIG. 7. For example, the relationship between the focal length and the reduction ratio may be changed according to the aperture value (F value) or tilt coefficient of the lens. Good.

図8は、レンズの絞り値(F値)又はあおり係数を変化させた際の焦点距離と縮小率との関係の一例を説明するための図である。そして、図8(a)はレンズの絞り値(F値)を変化させた際の焦点距離と縮小率との関係を示す図であり、図8(b)はあおり係数を変化させた際の焦点距離と縮小率との関係を示す図である。   FIG. 8 is a diagram for explaining an example of the relationship between the focal length and the reduction ratio when the aperture value (F value) or tilt coefficient of the lens is changed. FIG. 8A is a diagram showing the relationship between the focal length and the reduction ratio when the lens aperture value (F value) is changed, and FIG. 8B is the graph when the tilt coefficient is changed. It is a figure which shows the relationship between a focal distance and a reduction rate.

まず、図8(a)を参照して、ここでは、レンズの絞り値(F値)に応じて焦点距離と縮小率との関係である制御線図を変更する。F値が大きい場合には、被写界深度が深くなるので、画像全体を防振すれば防振効果に寄与できる。この場合には、並進成分のみでなく、回転成分およびあおり成分を重視して、これらの動きを検出できるように縮小率を大きくして、つまり、画像サイズを小さくして画像全体から多数の動きベクトルを検出する。   First, referring to FIG. 8A, here, the control diagram which is the relationship between the focal length and the reduction ratio is changed according to the aperture value (F value) of the lens. When the F value is large, the depth of field becomes deep. Therefore, if the entire image is shaken, it can contribute to the vibration-proofing effect. In this case, not only the translation component but also the rotation component and the tilt component are emphasized, and the reduction rate is increased so that these motions can be detected, that is, the image size is reduced and a large number of motions from the entire image. Detect vectors.

一方、F値が小さい場合には、被写界深度が浅くなるので、画像全体よりもピントが合っている被写体に対して防振すれば防振効果に寄与できる。この場合には、撮像シーンにおいて局所的な領域を考えると並進の動きとしてみなすことができる。さらに、被写界深度を浅くした際、撮影者はピントが合っている領域を注目領域としているのでブレの補正精度を向上させることが必要となる。よって、縮小率を小さくして、つまり、画像サイズを大きくして、動きベクトル数が少ない場合においても高精度に動きベクトルを検出するようにする。   On the other hand, when the F value is small, the depth of field becomes shallow, so if the subject that is in focus than the entire image is shaken, it can contribute to the anti-shake effect. In this case, considering a local region in the imaging scene, it can be regarded as a translational motion. Furthermore, when the depth of field is reduced, the photographer uses the focused area as the area of interest, so it is necessary to improve the blur correction accuracy. Therefore, the reduction rate is reduced, that is, the image size is increased, and the motion vector is detected with high accuracy even when the number of motion vectors is small.

続いて、図8(b)を参照すると、ここでは、あおり係数に応じて焦点距離と縮小率との関係を示す制御線図を変更する。画像の変形を後述するホモグラフィ行列で表現した際には、あおり成分の動きは、後述するあおり係数の大きさと相関がある。並進の変形量のみであれば、あおり係数は0に近い値となり、あおり成分が多くなると、あおり係数は0より大きくなる。   Next, referring to FIG. 8B, here, the control diagram showing the relationship between the focal length and the reduction ratio is changed according to the tilt coefficient. When the deformation of the image is expressed by a homography matrix described later, the movement of the tilt component has a correlation with the magnitude of the tilt coefficient described later. If only the amount of translational deformation is used, the tilt coefficient becomes a value close to 0, and if the tilt component increases, the tilt coefficient becomes larger than 0.

よって、あおり係数が大きい場合には、その動きが検出できるように縮小率を大きくして、つまり、画像サイズを小さくして動きベクトルを検出する。一方、あおり係数が小さい場合には、並進の動きが検出できればよいので、縮小率を小さくして、つまり、画像サイズを大きくして動きベクトルを検出する。   Therefore, when the tilt coefficient is large, the reduction rate is increased so that the motion can be detected, that is, the motion vector is detected by reducing the image size. On the other hand, when the tilt coefficient is small, it is only necessary to detect the translational motion, so the motion vector is detected by reducing the reduction rate, that is, increasing the image size.

上述のようにして、マイコン112の制御下で、つまり、マイコン112から与えられる光学系101の焦点距離に応じて、縮小率決定回路106は画像の縮小率を決定して、決定した縮小率を画像縮小回路107および108に与える。   As described above, under the control of the microcomputer 112, that is, according to the focal length of the optical system 101 given from the microcomputer 112, the reduction ratio determination circuit 106 determines the reduction ratio of the image, and determines the determined reduction ratio. This is given to the image reduction circuits 107 and 108.

続いて、画像縮小回路107および108の各々はメモリ104に保持されたフレーム画像を縮小処理する(ステップS203)。ここでは、ステップS201においてメモリ104に等倍サイズで保持された複数のフレーム画像から動きベクトル検出に用いられるフレーム画像が原画像および参照画像としてそれぞれ画像縮小回路107および108に入力される。画像縮小回路107および108は、縮小率設定回路106において設定縮小率に基づいて、それぞれ原画像および参照画像を縮小処理して第1の画像および第2の画像を出力する。   Subsequently, each of the image reduction circuits 107 and 108 reduces the frame image held in the memory 104 (step S203). Here, frame images used for motion vector detection from a plurality of frame images held at the same size in the memory 104 in step S201 are input to the image reduction circuits 107 and 108 as original images and reference images, respectively. The image reduction circuits 107 and 108 reduce the original image and the reference image, respectively, based on the set reduction rate in the reduction rate setting circuit 106, and output a first image and a second image.

なお、画像を縮小処理する際の手法は、特に限定されず、例えば、1/8縮小処理の場合には、8×8の矩形領域の画素の平均値を算出する画素平均法又は中央の画素に対して重み付けを行う縮小フィルタを用いる方法が用いられる。   The method for reducing the image is not particularly limited. For example, in the case of 1/8 reduction processing, a pixel average method for calculating an average value of pixels in an 8 × 8 rectangular area or a central pixel is used. A method using a reduction filter that performs weighting is used.

続いて、動きベクトル検出回路109は2枚のフレーム画像(つまり、第1の画像および第2の画像)間において動きベクトルを検出する(ステップS204)。例えば、動きベクトル検出回路109はテンプレートマッチングを用いて動きベクトルの検出を行う。   Subsequently, the motion vector detection circuit 109 detects a motion vector between two frame images (that is, the first image and the second image) (step S204). For example, the motion vector detection circuit 109 detects a motion vector using template matching.

図9は、図1に示す動きベクトル検出回路109で行われるテンプレートマッチングによる動きベクトルの検出を説明するための図である。そして、図9(a)は原画像を示す図であり、図9(b)は参照画像を示す図である。   FIG. 9 is a diagram for explaining the detection of a motion vector by template matching performed by the motion vector detection circuit 109 shown in FIG. FIG. 9A shows an original image, and FIG. 9B shows a reference image.

図示の原画像901および参照画像902は、メモリ104に保持された等倍サイズのフレーム画像を縮小処理した画像である。テンプレートマッチングを行う際には、原画像901において任意の位置にテンプレートブロック903を配置する。そして、テンプレートブロック903と参照画像902との相関値を算出する。   The illustrated original image 901 and reference image 902 are images obtained by reducing the same-size frame image held in the memory 104. When performing template matching, a template block 903 is arranged at an arbitrary position in the original image 901. Then, a correlation value between the template block 903 and the reference image 902 is calculated.

この際には、参照画像902の全ての領域について相関値を算出すると、その演算量は膨大となってしまう。このため、参照画像902に矩形領域をサーチ範囲904として設定して、このサーチ範囲904について相関値を算出する。なお、サーチ範囲904の位置および大きさについては特に制限はないものの、サーチ範囲904内にテンプレートブロック903の移動先に相当する領域が含まれていないと、動きベクトルを正しく検出することができない。   In this case, if the correlation value is calculated for all the regions of the reference image 902, the amount of calculation becomes enormous. Therefore, a rectangular area is set as the search range 904 in the reference image 902, and a correlation value is calculated for the search range 904. Although the position and size of the search range 904 are not particularly limited, the motion vector cannot be correctly detected unless the search range 904 includes an area corresponding to the destination of the template block 903.

図示の例においては、相関値を算出する際、例えば、差分絶対値和(Sum of Absolute Difference、以下SADという)を用いて、式(1)で示す相関値S_SADを得る。   In the illustrated example, when the correlation value is calculated, for example, a correlation value S_SAD represented by Expression (1) is obtained by using a sum of absolute difference (hereinafter referred to as SAD).


式(1)において、f(i,j)はテンプレートブロック903の座標(i,j)における輝度値を示し、g(i,j)はサーチ範囲904において相関値算出の対象となるブロック905の輝度値を示す。そして、ブロック903および905の輝度値f(i,j)およびg(i,j)について差の絶対値を算出して、その総和を求めると相関値S_SADを得ることができる。

In equation (1), f (i, j) indicates the luminance value at the coordinates (i, j) of the template block 903, and g (i, j) is the correlation value calculation target of the block 905 in the search range 904. Indicates the luminance value. Then, the absolute value of the difference is calculated for the luminance values f (i, j) and g (i, j) of the blocks 903 and 905, and the sum is obtained to obtain the correlation value S_SAD.

相関値S_SADが小さい程、ブロック903および905間の輝度値の差分が小さい。つまり、テンプレートブロック903と相関値算出ブロック905のテクスチャが類似していることになる。   The smaller the correlation value S_SAD, the smaller the difference in luminance value between the blocks 903 and 905. That is, the textures of the template block 903 and the correlation value calculation block 905 are similar.

ここでは、相関値を求める際にSADを用いるようにしたが、例えば、差分二乗和(SSD)又は正規化相互相関(NCC)などを用いて相関値を得るようにしてもよい。なお、SADを用いて相関値を算出する際には、その特性によって相関値が小さい程類似度が高い場合と相関値が大きい程類似度が高い場合が存在するため、その特性に応じて処理も変更する必要がある。   Here, the SAD is used when obtaining the correlation value. However, for example, the correlation value may be obtained using a sum of squared differences (SSD) or a normalized cross-correlation (NCC). When calculating a correlation value using SAD, there are cases where the similarity is higher as the correlation value is smaller depending on the characteristic, and the case where the similarity is higher as the correlation value is larger. Also need to be changed.

サーチ範囲904の全領域について相関値対象ブロック905を移動させて、上述のようにして相関値を算出する。そして、テンプレートブロック903とサーチ範囲904との間で相関値を算出して、当該相関値が最も小さくなる位置を判定することによって、原画像901のテンプレートブロック903が参照画像902においていずれの位置に移動したか、つまり、画像間の動きベクトルを検出する。   The correlation value target block 905 is moved for the entire region of the search range 904, and the correlation value is calculated as described above. Then, by calculating a correlation value between the template block 903 and the search range 904 and determining a position where the correlation value is the smallest, the template block 903 of the original image 901 is located at any position in the reference image 902. The movement vector, that is, the motion vector between images is detected.

動きベクトル検出回路109は、上述の動きベクトル検出処理を、フレーム画像間の複数の領域について行って、検出した動きベクトル群を幾何変形パラメータ推定回路110に送る。   The motion vector detection circuit 109 performs the above-described motion vector detection processing for a plurality of regions between the frame images, and sends the detected motion vector group to the geometric deformation parameter estimation circuit 110.

再び図2を参照して、続いて、幾何変形パラメータ推定回路110は動きベクトル群によってフレーム画像間(つまり、ここでは原画像と参照画像)の幾何変形パラメータを推定する(ステップS205)。ここでは、幾何変形モデルとして、ホモグラフィ行列を画像変形量とした例で説明する。   Referring to FIG. 2 again, subsequently, the geometric deformation parameter estimation circuit 110 estimates the geometric deformation parameters between the frame images (that is, here, the original image and the reference image) based on the motion vector group (step S205). Here, an example in which a homography matrix is used as an image deformation amount will be described as a geometric deformation model.

いま、式(2)で示す画像上のある点aが次のフレームにおいて式(3)で示す点a′に移動したとする。   Now, it is assumed that a certain point a on the image represented by Expression (2) has moved to a point a ′ represented by Expression (3) in the next frame.


ここで、添え字Tは転置行列であること示す。

Here, the subscript T indicates a transposed matrix.

式(2)で示す点aと式(3)で示す点a′との対応関係は、ホモグラフィ行列Hを用いることによって、式(4)で表すことができる。   By using the homography matrix H, the correspondence relationship between the point a shown in Expression (2) and the point a ′ shown in Expression (3) can be expressed by Expression (4).


ホモグラフィ行列Hは、画像間の並進、回転、変倍、せん断、およびあおりに起因する変形量を示す行列式であって、式(5)で表される。

The homography matrix H is a determinant representing the amount of deformation caused by translation, rotation, scaling, shearing, and tilting between images, and is represented by Expression (5).


なお、h31およびh32は、あおり係数である。

Note that h 31 and h 32 are tilt coefficients.

ホモグラフィ行列Hの各要素は、ステップS204で得られた動きベクトル群、つまり、フレーム画像間における代表点の対応関係を用いて最小二乗法などの統計的処理を用いて算出することができる。   Each element of the homography matrix H can be calculated using a statistical process such as a least square method using the motion vector group obtained in step S204, that is, the correspondence of representative points between frame images.

但し、縮小処理されたフレーム画像を用いて検出された動きベクトルは、縮小画像に係る動きベクトルであるので、幾何変形パラメータを推定する際には、動きベクトルを等倍サイズに変換する必要がある。   However, since the motion vector detected using the reduced frame image is a motion vector related to the reduced image, it is necessary to convert the motion vector to the same size when estimating the geometric deformation parameter. .

上述のようにして得られたホモグラフィ行列Hは、カメラのブレに起因する画像の変形量を示している。よって、画像のブレを補正するためには、当該ブレによる変形を打ち消す画像変形量となるようにホモグラフィ行列Hを変換する必要がある。つまり、ホモグラフィ行列Hを逆行列H−1に変換することによって、点a′と点aとの対応関係が式(6)で得られる。 The homography matrix H obtained as described above indicates the amount of deformation of the image due to camera shake. Therefore, in order to correct image blurring, it is necessary to convert the homography matrix H so as to obtain an image deformation amount that cancels the deformation caused by the blurring. That is, by converting the homography matrix H to the inverse matrix H- 1 , the correspondence between the point a 'and the point a can be obtained by Expression (6).


式(6)を用いて、ブレが生じた後の点a′をブレが生じる前の点aと同一の座標に戻すことができる。

Using the equation (6), the point a ′ after the blurring can be returned to the same coordinates as the point a before the blurring.

なお、ここでは、フレーム画像間のブレ量を表すモデルとしてホモグラフィ行列を例に挙げて説明したが、ホモグラフィ行列Hの代わりに、ヘルマート行列又はアフィン行列などの他のモデルを用いるようにしてもよい。さらに、主被写体を防振対象に設定した際には、並進におけるブレ補正量のみを求めればよく、単に動きベクトル群の平均値を求めれば、統計的な推定を行うことなく計算量を削減することができる。   Here, the homography matrix has been described as an example of the model representing the blurring amount between the frame images. However, instead of the homography matrix H, another model such as a Helmat matrix or an affine matrix is used. Also good. Furthermore, when the main subject is set as the image stabilization target, it is only necessary to obtain the blur correction amount in translation, and if the average value of the motion vector group is simply obtained, the calculation amount can be reduced without performing statistical estimation. be able to.

上述のようにして、幾何変形パラメータを推定した後、幾何変形パラメータ推定回路110は当該幾何変形パラメータをマイコン112に送る。そして、マイコン112から与えられた幾何変形パラメータに応じて、幾何変形回路111はメモリ104から入力されたフレーム画像について幾何変換処理を行って、防振処理が施された画像を得る(ステップS206)。そして、幾何変形回路111は当該防振処理が施された画像を記憶装置(図示せず)に記憶するとともに、表示装置(図示せず)に表示する(ステップS207)。その後、マイコン112は撮影動作を終了する。   After estimating the geometric deformation parameter as described above, the geometric deformation parameter estimation circuit 110 sends the geometric deformation parameter to the microcomputer 112. Then, according to the geometric deformation parameter given from the microcomputer 112, the geometric deformation circuit 111 performs a geometric transformation process on the frame image input from the memory 104 to obtain an image subjected to the image stabilization process (step S206). . The geometric deformation circuit 111 stores the image subjected to the image stabilization processing in a storage device (not shown) and displays it on a display device (not shown) (step S207). Thereafter, the microcomputer 112 ends the photographing operation.

このように、本発明の第1の実施形態では、撮影シーンにおいてブレを補正したい対象に応じて動きベクトルの検出に用いる画像の縮小率を変更する。これによって、限られたリソースにおいても指定された対象に対して良好にブレ補正処理が行われた映像を生成することができる。   As described above, in the first embodiment of the present invention, the reduction ratio of an image used for detecting a motion vector is changed according to an object for which blurring is to be corrected in a shooting scene. As a result, it is possible to generate a video in which the blur correction process has been satisfactorily performed on a specified target even with limited resources.

なお、縮小率については、上述のように現在撮像中のフレームに係る焦点距離に応じて設定するようにしてもよいが、過去のフレームで設定した縮小率、つまり、原画像を撮影する前に設定された複数の縮小率を時間方向において平滑化して得られた縮小率を設定するようにしてもよい。   As described above, the reduction rate may be set according to the focal length of the currently captured frame, but the reduction rate set in the past frame, that is, before the original image is captured. A reduction rate obtained by smoothing a plurality of set reduction rates in the time direction may be set.

さらには、原画像を撮影する前に設定された複数の絞り値を時間方向に平滑化して得られた絞り値に応じて縮小率を変更するようにしてもよく、原画像を撮影する前に設定された複数の幾何変形パラメータを時間方向に平滑化して得られた幾何変形パラメータに応じて縮小率を変更するようにしてもよい。   Furthermore, the reduction ratio may be changed in accordance with the aperture value obtained by smoothing a plurality of aperture values set in the time direction before capturing the original image. The reduction ratio may be changed according to the geometric deformation parameter obtained by smoothing a plurality of set geometric deformation parameters in the time direction.

[第2の実施形態]
続いて、本発明の第2の実施形態によるカメラの一例について説明する。
[Second Embodiment]
Next, an example of a camera according to the second embodiment of the present invention will be described.

図10は、本発明の第2の実施形態によるカメラの一例についてその構成を示すブロック図である。なお、図10において、図1に示すカメラと同一の構成要素については同一の参照番号を付して説明を省略する。   FIG. 10 is a block diagram showing the configuration of an example of a camera according to the second embodiment of the present invention. In FIG. 10, the same components as those of the camera shown in FIG.

第2の実施形態によるカメラでは、メモリ104に縮小処理を施したフレーム画像も記憶することによってメモリ104に画像を送る際の帯域の削減を図る。図示のカメラは、画像縮小回路108の代わりに画像リサイズ回路1001を備え、さらに画像縮小回路107にはカメラ信号処理回路103からフレーム画像が与えられる。   In the camera according to the second embodiment, a frame image subjected to the reduction process is also stored in the memory 104 so as to reduce a bandwidth when the image is transmitted to the memory 104. The illustrated camera includes an image resizing circuit 1001 instead of the image reducing circuit 108, and a frame image is given to the image reducing circuit 107 from the camera signal processing circuit 103.

図11は、図10に示すカメラで行われる撮影動作の一例を説明するためのフローチャートである。   FIG. 11 is a flowchart for explaining an example of a photographing operation performed by the camera shown in FIG.

なお、図示のフローチャートに係る処理はマイコン112の制御下で行われる。また、図示のフローチャートにおいて図2に示すフローチャートのステップと同一のステップについては同一の参照符号を付して説明を省略する。   Note that the processing according to the illustrated flowchart is performed under the control of the microcomputer 112. In the illustrated flowchart, the same steps as those in the flowchart shown in FIG.

撮影動作が開始されると、ステップS201において、カメラ信号処理回路103の出力であるフレーム画像がメモリ104に送られるとともに、画像縮小回路107に送られる。そして、ステップS202の処理において、縮小率決定回路106が画像縮小回路107および画像リサイズ回路1001に縮小率を設定する。   When the photographing operation is started, a frame image that is an output of the camera signal processing circuit 103 is sent to the memory 104 and also sent to the image reduction circuit 107 in step S201. In step S202, the reduction rate determination circuit 106 sets the reduction rate in the image reduction circuit 107 and the image resizing circuit 1001.

その後、ステップS203の処理において、画像縮小回路107が設定された縮小率に応じてフレーム画像を縮小処理して縮小画像を得る。そして、当該縮小画像は画像縮小回路107からメモリ104に送られて、メモリ104に記憶される。   Thereafter, in the process of step S203, the image reduction circuit 107 reduces the frame image according to the set reduction rate to obtain a reduced image. Then, the reduced image is sent from the image reduction circuit 107 to the memory 104 and stored in the memory 104.

続いて、画像リサイズ回路1001は、メモリ104に記憶された縮小画像に対してリサイズ処理を行う(ステップS1101)。メモリ104に記憶された縮小画像のサイズは、画像縮小回路107にフレーム画像が入力された時点において縮小率決定回路106で設定された縮小率に対応している。   Subsequently, the image resizing circuit 1001 performs resizing processing on the reduced image stored in the memory 104 (step S1101). The size of the reduced image stored in the memory 104 corresponds to the reduction rate set by the reduction rate determination circuit 106 when the frame image is input to the image reduction circuit 107.

一方、前述のように撮影シーンの時間的変動に応じて縮小率が変更されると、既にメモリ104に記憶された縮小画像と縮小率が変更された後に縮小処理された画像との間においては画像サイズの差異が生じる。このため、原画像と参照画像とにおいて画像サイズが異なることがあり、画像サイズが異なると動きベクトルを検出することはできない。このため、双方(つまり、原画像と参照画像)の画像サイズを合わせるため、画像リサイズ回路1001は、縮小率決定回路106で設定された縮小率に応じて、メモリ104から入力された縮小画像に対してリサイズ処理を行う。   On the other hand, when the reduction ratio is changed according to the temporal variation of the shooting scene as described above, between the reduced image already stored in the memory 104 and the image that has been reduced after the reduction ratio is changed. Differences in image size occur. For this reason, the image size may differ between the original image and the reference image, and the motion vector cannot be detected if the image sizes differ. For this reason, in order to match the image sizes of both (that is, the original image and the reference image), the image resizing circuit 1001 applies the reduced image input from the memory 104 in accordance with the reduction ratio set by the reduction ratio determination circuit 106. Resizing processing is performed on the image.

例えば、画像縮小回路107にフレーム画像が入力された時点における設定縮小率が1/8縮小であったとする。そして、撮影シーンの時間的変動に応じて縮小率が1/4縮小に変更されると、画像リサイズ回路1001はメモリ104に記憶された縮小画像に対して2倍の拡大処理を施して、当該閣外処理された画像を動きベクトル検出回路109に送る。   For example, it is assumed that the set reduction ratio at the time when a frame image is input to the image reduction circuit 107 is 1/8 reduction. When the reduction ratio is changed to 1/4 reduction according to the temporal variation of the shooting scene, the image resizing circuit 1001 performs a double enlargement process on the reduced image stored in the memory 104, and The image processed outside the cabinet is sent to the motion vector detection circuit 109.

これによって、画像縮小回路107の出力である画像と画像リサイズ回路1001の出力である画像、つまり、原画像と参照画像とはともに1/4縮小サイズとなって、動きベクトル検出回路109は前述のようにして動きベクトル検出を行うことができる。   As a result, the image output from the image reduction circuit 107 and the image output from the image resizing circuit 1001, that is, the original image and the reference image are both reduced to ¼, and the motion vector detection circuit 109 performs the above-described operation. In this way, motion vector detection can be performed.

なお、画像リサイズ回路1001で行われるリサイズ処理の手法は特に限定されず、例えば、バイリニア又はバイキュービックのような補間処理が用いられる。   Note that the method of resizing processing performed by the image resizing circuit 1001 is not particularly limited, and for example, bilinear or bicubic interpolation processing is used.

その後、ステップS204において、動きベクトル検出回路109によって動きベクトルが検出されて、ステップS205おいて、幾何変形パラメータ推定回路110が前述のようにして幾何変形パラメータを推定する。そして、ステップS206において、幾何変形回路111がメモリ104に記憶された等倍サイズのフレーム画像について、幾何変形パラメータに応じた画像幾何変形処理してブレ補正が行われた画像を生成する。その後、ステップS207において、画像が出力される。   Thereafter, in step S204, a motion vector is detected by the motion vector detection circuit 109, and in step S205, the geometric deformation parameter estimation circuit 110 estimates the geometric deformation parameter as described above. In step S <b> 206, the geometric deformation circuit 111 generates an image subjected to blur correction by performing image geometric deformation processing according to the geometric deformation parameter on the frame image of the same size stored in the memory 104. Thereafter, in step S207, an image is output.

上述の第1の実施形態においては、メモリ104に等倍サイズのフレーム画像のみが記憶される結果、設定縮小率の変動の都度、等倍サイズのフレーム画像に対して画像縮小処理を施すことになる。このため、メモリ104においては常に等倍サイズのフレーム画像が送られることになって、必要する帯域が大きくなってしまう。   In the first embodiment described above, only the same size frame image is stored in the memory 104. As a result, the image reduction process is performed on the same size frame image every time the set reduction rate changes. Become. For this reason, a frame image of the same size is always sent in the memory 104, and the required bandwidth becomes large.

一方、第2の実施形態では、画像縮小回路107にフレーム画像が入力される時点における設定縮小率で画像を縮小してメモリ104に記憶する。そして、縮小率の変化に応じてメモリ104に記憶された縮小画像をリサイズ処理する。これによって、メモ104には縮小画像が送られることになって、その帯域(伝送帯域)を削減することが可能となる。   On the other hand, in the second embodiment, the image is reduced and stored in the memory 104 at a set reduction rate when the frame image is input to the image reduction circuit 107. Then, the reduced image stored in the memory 104 is resized according to the change in the reduction ratio. As a result, a reduced image is sent to the memo 104, and the band (transmission band) can be reduced.

[第3の実施形態]
次に、本発明の第3の実施形態によるカメラの一例について説明する。
[Third Embodiment]
Next, an example of a camera according to the third embodiment of the present invention will be described.

図12は、本発明の第3の実施形態によるカメラの一例についてその構成を示すブロック図である。なお、図12において、図1に示すカメラと同一の構成要素については同一の参照番号を付して説明を省略する。   FIG. 12 is a block diagram showing the configuration of an example of a camera according to the third embodiment of the present invention. In FIG. 12, the same components as those of the camera shown in FIG. 1 are denoted by the same reference numerals and description thereof is omitted.

図示のカメラは、姿勢変化検出部120〜122を有しており、カメラの姿勢変化を三軸方向で検出して、その検出結果(以下姿勢変化情報と呼ぶ)をマイコン112に送る。図示の姿勢変化検出部120〜122は、例えば、ジャイロセンサであり、ここでは、ジャイロセンサ120がヨー方向の姿勢変化を検知し、ジャイロセンサ121がピッチ方向の姿勢変化を検知する。そして、ジャイロセンサ122がロール方向の姿勢変化を検知する。   The illustrated camera has posture change detection units 120 to 122, detects the posture change of the camera in three axis directions, and sends the detection result (hereinafter referred to as posture change information) to the microcomputer 112. The illustrated posture change detection units 120 to 122 are, for example, gyro sensors. Here, the gyro sensor 120 detects a posture change in the yaw direction, and the gyro sensor 121 detects a posture change in the pitch direction. The gyro sensor 122 detects a change in posture in the roll direction.

マイコン112は姿勢変化情報に基づいてカメラの角度ぶれ量を検出する。そして、マイコン112は当該角度ぶれ量に応じて焦点距離と縮小率との関係を示す制御線図を変更する。   The microcomputer 112 detects the amount of camera shake based on the posture change information. Then, the microcomputer 112 changes the control diagram indicating the relationship between the focal length and the reduction ratio in accordance with the amount of angular blur.

図13は、図12に示すカメラにおいて角度ぶれ量を変化させた際の焦点距離と縮小率との関係を示す図である。   FIG. 13 is a diagram showing the relationship between the focal length and the reduction ratio when the amount of angular blur is changed in the camera shown in FIG.

ここでは、カメラの角度ぶれ量に応じて焦点距離と縮小率との関係である制御線図を変更する。ジャイロセンサ120〜122の出力は、単位時間当たりの角度変化(つまり、角速度)を示している。よって、マイコン112はこれら角速度の各々を積分して角度ぶれ量を得る。   Here, the control diagram which is the relationship between the focal length and the reduction ratio is changed in accordance with the amount of camera shake. The outputs of the gyro sensors 120 to 122 indicate angular changes per unit time (that is, angular velocities). Accordingly, the microcomputer 112 integrates each of these angular velocities to obtain an angular blur amount.

角度ぶれ量が大きい場合には、検出すべき動きベクトルが大きくなる。このため、動きベクトル検出のためのサーチ範囲を広くする必要がある。但し、サーチ範囲を拡大すると演算量が増加するので、ここでは、縮小率を大きくして、つまり、画像サイズを小さくして動きベクトルを検出する。   When the amount of angular blur is large, the motion vector to be detected becomes large. For this reason, it is necessary to widen the search range for motion vector detection. However, since the amount of calculation increases when the search range is expanded, the motion vector is detected by increasing the reduction ratio, that is, reducing the image size.

一方、角度ぶれ量が小さい場合には、検出すべき動きベクトルが小さくなる。このため、動きベクトル検出のためのサーチ範囲を狭くしてもよい。この場合には、縮小率を小さくして、つまり、画像サイズを大きくして動きベクトルを検出する。   On the other hand, when the amount of angular blur is small, the motion vector to be detected is small. For this reason, the search range for motion vector detection may be narrowed. In this case, the motion vector is detected by reducing the reduction ratio, that is, increasing the image size.

縮小率については、上述のように、現在の撮像で得られたフレーム画像に係る焦点距離について設定してもよいが、過去のフレーム画像で検出した角度ぶれ量を時間方向に平滑化して、縮小率を設定するようにしてもよい。   As described above, the reduction rate may be set for the focal length of the frame image obtained by the current imaging, but the angle blur detected in the past frame image is smoothed in the time direction to reduce the reduction rate. The rate may be set.

なお、ジャイロセンサ120〜122の出力には、パンおよびチルトなどのカメラワークによる変化が含まれるので、それらの成分を取り除くためジャイロセンサ120〜122の出力に対してハイパスフィルタ処理を行うようにしてもよい。   Since the outputs of the gyro sensors 120 to 122 include changes due to camera work such as pan and tilt, high-pass filter processing is performed on the outputs of the gyro sensors 120 to 122 in order to remove these components. Also good.

上述のように、本発明の第3の実施形態では、ジャイロセンサなどの姿勢変化検出部を備えて、カメラの角度ぶれ量に応じて焦点距離と縮小率との関係を示す制御線図を変更する。この結果、上述の第1の実施形態による効果に加えて、カメラの角度ぶれ量に応じた焦点距離と縮小率との関係を的確に選択して、動きベクトルを検出することができる。   As described above, in the third embodiment of the present invention, a posture change detection unit such as a gyro sensor is provided, and the control diagram indicating the relationship between the focal length and the reduction ratio is changed according to the amount of camera shake. To do. As a result, in addition to the effects of the first embodiment described above, it is possible to detect the motion vector by accurately selecting the relationship between the focal length and the reduction ratio according to the amount of camera shake.

[第4の実施形態]
次に、本発明の第4の実施形態によるカメラの一例について説明する。
[Fourth Embodiment]
Next, an example of a camera according to the fourth embodiment of the present invention will be described.

図14は、本発明の第4の実施形態によるカメラの一例についてその構成を示すブロック図である。なお、図14において、図10に示すカメラと同一の構成要素については同一の参照番号を付して説明を省略する。   FIG. 14 is a block diagram showing the configuration of an example of a camera according to the fourth embodiment of the present invention. In FIG. 14, the same components as those of the camera shown in FIG. 10 are denoted by the same reference numerals and description thereof is omitted.

図示のカメラは、姿勢変化検出部120〜122を有しており、カメラの姿勢変化を三軸方向で検出して、その検出結果(以下姿勢変化情報と呼ぶ)をマイコン112に送る。図示の姿勢変化検出部120〜122は、例えば、ジャイロセンサであり、ここでは、ジャイロセンサ120がヨー方向の姿勢変化を検知し、ジャイロセンサ121がピッチ方向の姿勢変化を検知する。そして、ジャイロセンサ122がロール方向の姿勢変化を検知する。   The illustrated camera has posture change detection units 120 to 122, detects the posture change of the camera in three axis directions, and sends the detection result (hereinafter referred to as posture change information) to the microcomputer 112. The illustrated posture change detection units 120 to 122 are, for example, gyro sensors. Here, the gyro sensor 120 detects a posture change in the yaw direction, and the gyro sensor 121 detects a posture change in the pitch direction. The gyro sensor 122 detects a change in posture in the roll direction.

マイコン112は姿勢変化情報に基づいてカメラの角度ぶれ量を検出する。そして、マイコン112は当該角度ぶれ量に応じて焦点距離と縮小率との関係を示す制御線図を変更する。   The microcomputer 112 detects the amount of camera shake based on the posture change information. Then, the microcomputer 112 changes the control diagram indicating the relationship between the focal length and the reduction ratio in accordance with the amount of angular blur.

上述のように、本発明の第4の実施形態では、ジャイロセンサなどの姿勢変化検出部を備えて、カメラの角度ぶれ量に応じて焦点距離と縮小率との関係を示す制御線図を変更する。この結果、上述の第2の実施形態による効果に加えて、カメラの角度ぶれ量に応じた焦点距離と縮小率との関係を的確に選択して、動きベクトルを検出することができる。   As described above, the fourth embodiment of the present invention includes a posture change detection unit such as a gyro sensor, and changes the control diagram indicating the relationship between the focal length and the reduction ratio according to the amount of camera shake. To do. As a result, in addition to the effects of the second embodiment described above, the motion vector can be detected by accurately selecting the relationship between the focal length and the reduction ratio according to the amount of camera shake.

以上のように、本発明の実施の形態では、光学系の焦点距離に応じて動きベクトル検出用の画像である原画像および参照画像のリサイズ率を制御する。これによって、ワイド側においてはあおり補正、そして、テレ側においては並進補正のための動きベクトルを精度よく検出できて、ぶれが良好に補正された画像を生成することが可能となる。   As described above, in the embodiment of the present invention, the resizing rate of the original image and the reference image, which are images for motion vector detection, is controlled according to the focal length of the optical system. As a result, it is possible to accurately detect a motion vector for tilt correction on the wide side and for translation correction on the tele side, and to generate an image in which blurring is well corrected.

上述の説明から明らかなように、図1に示す例では、画像縮小回路107および108がリサイズ手段として機能し、動きベクトル検出回路109が動きベクトル検出手段として機能する。また、マイコン112および縮小率決定回路106が制御手段として機能し、マイコン112、幾何変形パラメータ推定回路110、および幾何変形回路111がぶれ補正手段として機能する。   As is clear from the above description, in the example shown in FIG. 1, the image reduction circuits 107 and 108 function as resizing means, and the motion vector detection circuit 109 functions as motion vector detection means. In addition, the microcomputer 112 and the reduction ratio determination circuit 106 function as control means, and the microcomputer 112, the geometric deformation parameter estimation circuit 110, and the geometric deformation circuit 111 function as blur correction means.

以上、本発明について実施の形態に基づいて説明したが、本発明は、これらの実施の形態に限定されるものではなく、この発明の要旨を逸脱しない範囲の様々な形態も本発明に含まれる。   As mentioned above, although this invention was demonstrated based on embodiment, this invention is not limited to these embodiment, Various forms of the range which does not deviate from the summary of this invention are also contained in this invention. .

例えば、上記の実施の形態の機能を制御方法として、この制御方法を撮像装置に実行させるようにすればよい。また、上述の実施の形態の機能を有するプログラムを制御プログラムとして、当該制御プログラムを撮像装置が備えるコンピュータに実行させるようにしてもよい。なお、制御プログラムは、例えば、コンピュータに読み取り可能な記録媒体に記録される。   For example, the function of the above embodiment may be used as a control method, and this control method may be executed by the imaging apparatus. Further, a program having the functions of the above-described embodiments may be used as a control program, and the control program may be executed by a computer included in the imaging apparatus. The control program is recorded on a computer-readable recording medium, for example.

上記の制御方法および制御プログラムの各々は、少なくともリサイズステップ、制御ステップ、動きベクトル検出ステップ、およびぶれ補正ステップを有している。   Each of the above control method and control program has at least a resizing step, a control step, a motion vector detection step, and a shake correction step.

また、本発明は、以下の処理を実行することによっても実現される。つまり、上述した実施形態の機能を実現するソフトウェア(プログラム)を、ネットワーク又は各種の記録媒体を介してシステム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPUなど)がプログラムを読み出して実行する処理である。   The present invention can also be realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various recording media, and the computer (or CPU, MPU, etc.) of the system or apparatus reads the program. To be executed.

101 光学系
102 撮像素子
103 カメラ信号処理回路
104 メモリ
106 縮小率決定回路
107,108 画像縮小回路
109 動きベクトル検出回路
110 幾何変形パラメータ推定回路
111 幾何変形回路
112 マイコン
DESCRIPTION OF SYMBOLS 101 Optical system 102 Image pick-up element 103 Camera signal processing circuit 104 Memory 106 Reduction rate determination circuit 107,108 Image reduction circuit 109 Motion vector detection circuit 110 Geometric deformation parameter estimation circuit 111 Geometric deformation circuit 112 Microcomputer

Claims (15)

焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置であって、
前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズ手段と、
前記光学系の焦点距離に応じて、前記リサイズ手段におけるリサイズ率を制御する制御手段と、
前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出手段と、
前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正手段と、
を有することを特徴とする撮像装置。
An imaging apparatus that includes an optical system having a variable focal length, and that captures a plurality of temporally continuous images via the optical system,
One of the images is used as an original image, an image taken before the original image is used as a reference image, and the original image and the reference image are resized to be a first image and a second image, respectively. Resizing means;
Control means for controlling a resizing rate in the resizing means in accordance with a focal length of the optical system;
Motion vector detection means for detecting a motion vector between the first image and the second image;
Blur correction means for correcting blur of the original image according to the motion vector;
An imaging device comprising:
少なくとも前記参照画像を保持するメモリ手段を備えており、
前記リサイズ手段は、前記リサイズ処理として前記原画像を縮小処理する第1の縮小手段と、前記リサイズ処理として前記参照画像を縮小処理する第2の縮小手段とを有することを特徴とする請求項1に記載の撮像装置。
Memory means for holding at least the reference image;
2. The resizing means comprises: a first reducing means for reducing the original image as the resizing process; and a second reducing means for reducing the reference image as the resizing process. The imaging device described in 1.
少なくとも前記参照画像を保持するメモリ手段を備えており、
前記リサイズ手段は、前記リサイズ処理として前記原画像を縮小処理する縮小手段と、前記リサイズ処理として前記参照画像を縮小処理又は拡大処理するリサイズ処理手段とを有し、
前記縮小手段は縮小処理して得られた第1の画像を前記参照画像として前記メモリ手段に保存することを特徴とする請求項1に記載の撮像装置。
Memory means for holding at least the reference image;
The resizing means includes a reducing means for reducing the original image as the resizing process, and a resizing processing means for reducing or enlarging the reference image as the resizing process,
The imaging apparatus according to claim 1, wherein the reduction unit stores a first image obtained by reduction processing in the memory unit as the reference image.
前記制御手段は、前記焦点距離が大きくなるにつれて、前記原画像および前記参照画像のサイズが大きくなるように前記リサイズ率を変更することを特徴とする請求項1〜3のいずれか1項に記載の撮像装置。   The said control means changes the said resizing rate so that the size of the said original image and the said reference image may become large as the said focal distance becomes large, The any one of Claims 1-3 characterized by the above-mentioned. Imaging device. 前記ぶれ補正手段は、前記動きベクトルに応じて前記撮像装置のぶれに起因する画像の変形量を示す幾何変形パラメータを推定する推定手段と、
前記幾何変形パラメータに応じて前記原画像について幾何変換処理を行って、前記原画像のぶれを補正する幾何変形手段とを有することを特徴とする請求項1〜4のいずれか1項に記載の撮像装置。
The blur correction unit estimates a geometric deformation parameter indicating a deformation amount of an image caused by the blur of the imaging device according to the motion vector;
5. The apparatus according to claim 1, further comprising a geometric deformation unit that performs a geometric transformation process on the original image in accordance with the geometric deformation parameter to correct blur of the original image. 6. Imaging device.
前記制御手段は、前記光学系の絞り値が大きくなるにつれて、前記原画像および前記参照画像のサイズが小さくなるように前記リサイズ率を変更することを特徴とする請求項4又は5に記載の撮像装置。   6. The imaging according to claim 4, wherein the control unit changes the resizing rate so that the sizes of the original image and the reference image become smaller as the aperture value of the optical system becomes larger. apparatus. 前記制御手段は、前記幾何変形パラメータのあおり成分が大きくなるにつれて、前記原画像および前記参照画像のサイズが小さくなるように前記リサイズ率を変更することを特徴とする請求項5に記載の撮像装置。   6. The imaging apparatus according to claim 5, wherein the control unit changes the resizing ratio so that the sizes of the original image and the reference image become smaller as the tilt component of the geometric deformation parameter becomes larger. . さらに、前記撮像装置の姿勢の変化を検出して姿勢変化情報を得る姿勢変化検出手段を備え、
前記制御手段は、前記焦点距離に加えて前記姿勢変化情報に応じて前記リサイズ手段におけるリサイズ率を制御することを特徴とする請求項1〜3のいずれか1項に記載の撮像装置。
Furthermore, it comprises posture change detection means for detecting posture change of the imaging device and obtaining posture change information,
The imaging apparatus according to claim 1, wherein the control unit controls a resizing rate in the resizing unit according to the posture change information in addition to the focal length.
前記制御手段は、前記姿勢変化情報が示すぶれ量が大きくなるにつれて、前記原画像および前記参照画像のサイズが小さくなるように前記リサイズ率を変更することを特徴とする請求項8に記載の撮像装置。   9. The imaging according to claim 8, wherein the control unit changes the resizing rate so that the sizes of the original image and the reference image become smaller as the amount of blur indicated by the posture change information becomes larger. apparatus. 前記制御手段は、前記原画像を撮影する前に設定された複数のリサイズ率を平滑化して得られたリサイズ率を前記リサイズ手段におけるリサイズ率とすることを特徴とする請求項1〜9のいずれか1項に記載の撮像装置。   10. The control unit according to claim 1, wherein the resizing rate obtained by smoothing a plurality of resizing rates set before photographing the original image is used as a resizing rate in the resizing unit. The imaging apparatus of Claim 1. 前記制御手段は、前記原画像を撮影する前に設定された複数の絞り値を平滑化して得られた絞り値に応じて前記リサイズ手段におけるリサイズ率を変更することを特徴とする請求項6に記載の撮像装置。   The said control means changes the resizing rate in the said resizing means according to the aperture value obtained by smoothing the several aperture value set before image | photographing the said original image, It is characterized by the above-mentioned. The imaging device described. 前記制御手段は、前記原画像を撮影する前に設定された複数の幾何変形パラメータを平滑化して得られた幾何変形パラメータに応じて前記リサイズ手段におけるリサイズ率を変更することを特徴とする請求項7に記載の撮像装置。   The control means changes a resizing rate in the resizing means according to a geometric deformation parameter obtained by smoothing a plurality of geometric deformation parameters set before photographing the original image. 8. The imaging device according to 7. 前記制御手段は、前記原画像を撮影する前に前記姿勢変化検出手段で得られた複数の姿勢変化情報が示すぶれ量を平滑化して得られたぶれ量に応じて前記リサイズ手段におけるリサイズ率を変更することを特徴とする請求項8に記載の撮像装置。   The control means sets the resizing rate in the resizing means according to the shake amount obtained by smoothing the shake amount indicated by the plurality of posture change information obtained by the posture change detection means before photographing the original image. The imaging apparatus according to claim 8, wherein the imaging apparatus is changed. 焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置の制御方法であって、
前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズステップと、
前記光学系の焦点距離に応じて、前記リサイズステップで行われるリサイズ処理におけるリサイズ率を制御する制御ステップと、
前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出ステップと、
前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正ステップと、
を有することを特徴とする制御方法。
A control method of an imaging apparatus that includes an optical system having a variable focal length and that captures a plurality of temporally continuous images via the optical system,
One of the images is used as an original image, an image taken before the original image is used as a reference image, and the original image and the reference image are resized to be a first image and a second image, respectively. Resize step,
A control step for controlling a resizing rate in the resizing process performed in the resizing step in accordance with a focal length of the optical system;
A motion vector detection step of detecting a motion vector between the first image and the second image;
A blur correction step of correcting blur of the original image according to the motion vector;
A control method characterized by comprising:
焦点距離が可変の光学系を備え、前記光学系を介して時間的に連続する複数の画像を撮影する撮像装置で用いられる制御プログラムであって、
前記撮像装置が備えるコンピュータに、
前記画像の1つを原画像とし、当該原画像よりも前に撮影された画像を参照画像として、前記原画像および前記参照画像をリサイズ処理してそれぞれ第1の画像および第2の画像とするリサイズステップと、
前記光学系の焦点距離に応じて、前記リサイズステップで行われるリサイズ処理におけるリサイズ率を制御する制御ステップと、
前記第1の画像と前記第2の画像との間における動きベクトルを検出する動きベクトル検出ステップと、
前記動きベクトルに応じて前記原画像のぶれを補正するぶれ補正ステップと、
を実行させることを特徴とする制御プログラム。
A control program used in an imaging apparatus that includes an optical system having a variable focal length and captures a plurality of temporally continuous images through the optical system,
In the computer provided in the imaging device,
One of the images is used as an original image, an image taken before the original image is used as a reference image, and the original image and the reference image are resized to be a first image and a second image, respectively. Resize step,
A control step for controlling a resizing rate in the resizing process performed in the resizing step in accordance with a focal length of the optical system;
A motion vector detection step of detecting a motion vector between the first image and the second image;
A blur correction step of correcting blur of the original image according to the motion vector;
A control program characterized by causing
JP2014027599A 2014-02-17 2014-02-17 Imaging device, control method thereof, and control program Expired - Fee Related JP6282133B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014027599A JP6282133B2 (en) 2014-02-17 2014-02-17 Imaging device, control method thereof, and control program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014027599A JP6282133B2 (en) 2014-02-17 2014-02-17 Imaging device, control method thereof, and control program

Publications (2)

Publication Number Publication Date
JP2015154334A true JP2015154334A (en) 2015-08-24
JP6282133B2 JP6282133B2 (en) 2018-02-21

Family

ID=53896163

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014027599A Expired - Fee Related JP6282133B2 (en) 2014-02-17 2014-02-17 Imaging device, control method thereof, and control program

Country Status (1)

Country Link
JP (1) JP6282133B2 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018159122A1 (en) * 2017-02-28 2018-09-07 パナソニックIpマネジメント株式会社 Imaging device and method for correcting shake of captured image
US10922798B2 (en) * 2017-09-01 2021-02-16 Samsung Electronics Co., Ltd. Image processing apparatus, method for processing image and computer-readable recording medium
CN114755789A (en) * 2020-12-28 2022-07-15 北京小米移动软件有限公司 Focusing method, device, terminal and storage medium
JP7446805B2 (en) 2019-12-18 2024-03-11 キヤノン株式会社 Imaging device, control method and program

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008085688A (en) * 2006-09-28 2008-04-10 Casio Comput Co Ltd Image pickup device, method and program
JP2010118862A (en) * 2008-11-12 2010-05-27 Canon Inc Image processor, imaging apparatus and image processing method
JP2012199691A (en) * 2011-03-18 2012-10-18 Ricoh Co Ltd Imaging apparatus, imaging method, and imaging program

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008085688A (en) * 2006-09-28 2008-04-10 Casio Comput Co Ltd Image pickup device, method and program
JP2010118862A (en) * 2008-11-12 2010-05-27 Canon Inc Image processor, imaging apparatus and image processing method
JP2012199691A (en) * 2011-03-18 2012-10-18 Ricoh Co Ltd Imaging apparatus, imaging method, and imaging program

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018159122A1 (en) * 2017-02-28 2018-09-07 パナソニックIpマネジメント株式会社 Imaging device and method for correcting shake of captured image
JP2018142911A (en) * 2017-02-28 2018-09-13 パナソニックIpマネジメント株式会社 Imaging apparatus and method for correcting shake of image to be taken
US10922798B2 (en) * 2017-09-01 2021-02-16 Samsung Electronics Co., Ltd. Image processing apparatus, method for processing image and computer-readable recording medium
JP7446805B2 (en) 2019-12-18 2024-03-11 キヤノン株式会社 Imaging device, control method and program
CN114755789A (en) * 2020-12-28 2022-07-15 北京小米移动软件有限公司 Focusing method, device, terminal and storage medium
CN114755789B (en) * 2020-12-28 2023-07-04 北京小米移动软件有限公司 Focusing method, focusing device, terminal and storage medium

Also Published As

Publication number Publication date
JP6282133B2 (en) 2018-02-21

Similar Documents

Publication Publication Date Title
JP5284048B2 (en) Image processing apparatus, imaging apparatus, and image processing method
JP4534172B2 (en) Image processing apparatus, image processing method, and program
JP6385212B2 (en) Image processing apparatus and method, imaging apparatus, and image generation apparatus
US9055217B2 (en) Image compositing apparatus, image compositing method and program recording device
JP6087671B2 (en) Imaging apparatus and control method thereof
US10917567B2 (en) Image processing apparatus, image processing method, program, and image pickup system
JP2005252626A (en) Image pickup device and image processing method
JP2011029735A5 (en)
JP2006295626A (en) Fish-eye image processing apparatus, method thereof and fish-eye imaging apparatus
JP2007166269A (en) Image processor, image pickup device and image processing method
US9172870B2 (en) Real-time image processing method and device enhancing the resolution of successive images
JP6656035B2 (en) Image processing apparatus, imaging apparatus, and control method for image processing apparatus
JP2008160300A (en) Image processor, and imaging apparatus
JP6282133B2 (en) Imaging device, control method thereof, and control program
JP6178646B2 (en) Imaging apparatus and image shake correction processing method
JP2018061130A (en) Image processing device, image processing method, and program
JP6223161B2 (en) Image processing apparatus, imaging apparatus including the same, and image processing method
JP6231816B2 (en) IMAGING DEVICE, ITS CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM
KR20100046544A (en) Image distortion compensation method and apparatus
EP3836540B1 (en) Image processing apparatus and image capturing apparatus
JP6316030B2 (en) Imaging apparatus and control method thereof
JP6016546B2 (en) Imaging device, control method thereof, and control program
JP2015079329A (en) Image processor, image processing method and program
JP6245847B2 (en) Image processing apparatus and image processing method
JP6381212B2 (en) Imaging apparatus and control method thereof

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20170130

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20171005

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20171017

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20171214

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180123

R151 Written notification of patent or utility model registration

Ref document number: 6282133

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

LAPS Cancellation because of no payment of annual fees