JP6004741B2 - Image processing apparatus, control method therefor, and imaging apparatus - Google Patents
Image processing apparatus, control method therefor, and imaging apparatus Download PDFInfo
- Publication number
- JP6004741B2 JP6004741B2 JP2012116875A JP2012116875A JP6004741B2 JP 6004741 B2 JP6004741 B2 JP 6004741B2 JP 2012116875 A JP2012116875 A JP 2012116875A JP 2012116875 A JP2012116875 A JP 2012116875A JP 6004741 B2 JP6004741 B2 JP 6004741B2
- Authority
- JP
- Japan
- Prior art keywords
- parallax
- amount
- image
- correction
- calculated
- 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
Links
Images
Landscapes
- Stereoscopic And Panoramic Photography (AREA)
- Testing, Inspecting, Measuring Of Stereoscopic Televisions And Televisions (AREA)
- Studio Devices (AREA)
Description
本発明は、画像処理装置および撮像装置に関し、特に撮像信号の記録に関するものである。
The present invention relates to an image processing apparatus and an imaging apparatus, and more particularly to recording of an imaging signal.
近年、3次元(3D)シネマや3Dディスプレイ等、立体映像関連機器の普及が急速に進んでいる。立体映像撮影は従来からフィルム式カメラ等でも行われてきたが、デジタル撮像装置の普及に伴い、デジタルカメラやデジタルビデオカメラ等により立体映像を生成するための元画像が撮影されるようになってきている。 In recent years, three-dimensional (3D) cinema, 3D display, and other 3D video related devices are rapidly spreading. Although stereoscopic video shooting has been conventionally performed with a film camera or the like, with the widespread use of digital imaging devices, original images for generating stereoscopic video with a digital camera, a digital video camera, and the like have been captured. ing.
立体映像をユーザが鑑賞する仕組みとしては、対象物を左目で見た像及び右目で見た像に対応するように、左右方向に視差を持たせた、右目用画像と左目用画像のデータが用意される。各画像をユーザが右目と左目でそれぞれ見ることで立体視可能である。その方法には、視差バリア方式やレンチキュラ方式等のように鑑賞対象の映像を視差分割する方法がある。また左右で特性の異なるフィルタを介して、ユーザの左目と右目に異なる映像を提示する方法等が知られている。 As a mechanism for a user to view a stereoscopic video, right eye image data and left eye image data with parallax in the left-right direction so as to correspond to an image of an object viewed with the left eye and an image viewed with the right eye are provided. Prepared. A user can view each image stereoscopically by looking at the right eye and the left eye. As such a method, there is a method of dividing an image to be viewed, such as a parallax barrier method or a lenticular method, into a parallax. There is also known a method for presenting different images to the left and right eyes of the user through filters having different characteristics on the left and right.
一方、立体映像として鑑賞可能な画像の撮影方法として、異なる視点での画像を同時に撮影する方法が、特許文献1および2に開示されている。特許文献1は、複数の微小レンズが形成され、該微小レンズの各々に近接して、対を成すフォトダイオードが1対以上配置されている固体撮像素子を開示する。フォトダイオード対のうち、一方のフォトダイオードの出力から第1の画像信号が得られ、他方のフォトダイオードの出力から第2の画像信号が得られる。第1及び第2の画像信号を、左目用画像及び右目用画像としてそれぞれ用いることで、立体映像の鑑賞が可能となる。また、特許文献2は、第1の画像のそれぞれの画素に適用されるべきシフトに対応する出力値を持つ出力要素を有する出力視差マップを開示する。この出力視差マップと第1の画像に基づいて、第2の画像を生成することができる。
On the other hand,
ところで、撮影したステレオ画像を表示装置で表示する際、表示装置の表示画面の大きさと鑑賞者の位置によって、得られる立体感が異なる。視差マップに保存されている視差量は立体感を表現した値であるが、視差量と表示画面の大きさが合っていない場合、ユーザは立体感の不自然さに気付いてしまう。例えば、充分な立体感が得られないことや、逆に立体感が強すぎてユーザの眼に疲労を起こす可能性等が挙げられる。特許文献3では、ステレオ画像の視差を変更する画像処理によって、適切な立体感を得る技術が開示されている。 By the way, when the captured stereo image is displayed on the display device, the stereoscopic effect obtained varies depending on the size of the display screen of the display device and the position of the viewer. The amount of parallax stored in the parallax map is a value representing the stereoscopic effect, but if the amount of parallax and the size of the display screen do not match, the user will notice the unnaturalness of the stereoscopic effect. For example, there is a possibility that a sufficient stereoscopic effect cannot be obtained, or that the stereoscopic effect is too strong to cause fatigue in the user's eyes. Patent Document 3 discloses a technique for obtaining an appropriate stereoscopic effect by image processing for changing the parallax of a stereo image.
従来の技術では、撮影パラメータの違いによって表示映像の立体感が損なわれないようにする対策が講じられていないという問題がある。
特許文献3では、ステレオ画像の視差を変更する視差変更装置がステレオ表示装置のディスプレイの大きさを情報取得部から取得する。この場合、再生時にディスプレイの大きさに応じた視差補正が行われる。しかし、撮影の際には既に、絞り、レンズの焦点距離、被写体までの距離、ピント面までの距離等の撮影パラメータによって、視差量が変動してしまっている。その結果、撮影パラメータによっては表示映像の立体感が不十分な場合や過剰な場合が起こり得る。
The conventional technology has a problem in that no measures are taken to prevent the stereoscopic effect of the displayed image from being impaired due to a difference in shooting parameters.
In Patent Literature 3, a parallax changing device that changes the parallax of a stereo image acquires the size of the display of the stereo display device from the information acquisition unit. In this case, parallax correction corresponding to the size of the display is performed during reproduction. However, the amount of parallax has already fluctuated depending on the shooting parameters such as the aperture, the focal length of the lens, the distance to the subject, and the distance to the focus surface. As a result, depending on the shooting parameters, there may be a case where the stereoscopic effect of the displayed image is insufficient or excessive.
本発明は、如何なる撮影パラメータで撮影しても、表示映像の立体感が過不足なく得られる視差マップデータと画像データを生成することを目的とする。
The present invention may be taken with any imaging parameters, and an object thereof is three-dimensional effect of the displayed image to generate a disparity map data and images data obtained just proportion.
上記課題を解決するために、本発明に係る装置は、視差を有する複数の画像データを取得して画像生成処理を行う画像処理装置であって、前記視差を有する複数の画像データから被写体の視差量を算出する視差量算出手段と、前記視差量算出手段が算出した視差量と、設定された視差量の基準値から視差補正率を算出し、前記視差量に前記視差補正率を乗算して拡大および縮小の視差補正を行う視差補正手段を備える。前記視差補正手段は、算出された正値の前記視差量に対応する第1の基準値および算出された負値の前記視差量に対応する第2の基準値と、算出された前記視差量との比率から前記視差補正率をそれぞれ算出する。
In order to solve the above-described problem, an apparatus according to the present invention is an image processing apparatus that acquires a plurality of image data having parallax and performs image generation processing, and the parallax of a subject from the plurality of image data having parallax. A parallax amount calculating unit that calculates an amount, a parallax amount calculated by the parallax amount calculating unit, and a reference value of the set parallax amount, and multiplying the parallax amount by the parallax correction rate Disparity correction means for performing enlargement and reduction parallax correction is provided. The parallax correction means includes a first reference value corresponding to the calculated positive parallax amount, a second reference value corresponding to the calculated negative parallax amount, and the calculated parallax amount. The parallax correction rate is calculated from each ratio.
本発明によれば、如何なる撮影パラメータで撮影しても、表示映像の立体感が過不足なく得られる視差マップデータと画像データを生成することができる。
According to the present invention, even when taken with any imaging parameters, it is possible to three-dimensional effect of the displayed image to generate a disparity map data and images data obtained just proportion.
以下に、本発明の各実施形態を、添付図面に基づいて詳細に説明する。
[第1実施形態]
図1は本実施形態の撮像装置で使用する撮像素子の構成例を概略的に示す図である。撮像素子100は、画素アレイ101と、画素アレイ101における行を選択する垂直選択回路102と、画素アレイ101における列を選択する水平選択回路104を含む。読み出し回路103は、画素アレイ101中の画素のうち垂直選択回路102によって選択される画素の信号を読み出す。読み出し回路103は、信号を蓄積するメモリ、ゲインアンプ、AD変換器等を列毎に有する。
Embodiments of the present invention will be described below in detail with reference to the accompanying drawings.
[First Embodiment]
FIG. 1 is a diagram schematically illustrating a configuration example of an imaging element used in the imaging apparatus of the present embodiment. The
シリアルインターフェース(SI)部105は、各回路の動作モード等を外部回路からの指示に従って決定する。垂直選択回路102は、画素アレイ101の複数の行を順次選択し、読み出し回路103に画素信号を取り出す。また水平選択回路104は、読み出し回路103によって読み出された複数の画素信号を列毎に順次選択する。なお、撮像素子100には、図1に示す構成要素以外に、例えば、垂直選択回路102、水平選択回路104、読み出し回路103等にタイミング信号を提供するタイミングジェネレータや、制御回路等が存在するが、これらの詳細な説明は省略する。
The serial interface (SI)
図2は撮像素子100の画素の構成例を示す図である。図2(A)は1画素の構成を概略的に示す。図2(B)は画素アレイ101の配置を示す。図2(A)に示す画素201は、光学素子としてのマイクロレンズ202と、受光素子としての複数のフォトダイオード(以下、PDと略記する)とを有する。
FIG. 2 is a diagram illustrating a configuration example of pixels of the
図2(A)には、1画素に左側のPD203と右側のPD204の2個を設けた例を示すが、3個以上(例えば、4個または9個)のPDを用いてもよい。PD203は、受光した光束を光電変換して左目用画像の信号を出力する。PD204は、受光した光束を光電変換して右目用画像の信号を出力する。なお、画素201は、図示の構成要素以外にも、例えば、PD信号を読み出し回路103に取り出す画素増幅アンプや、行選択スイッチ、PD信号のリセットスイッチ等を備える。
FIG. 2A illustrates an example in which two pixels, the
画素アレイ101は、2次元画像を提供するため、図2(B)に示す多数の画素301から304のように、2次元アレイ状に配列して構成される。画素301から304にて、PD301L、302L、303L、304Lは、図2(A)中のPD203に相当する。また、PD301R、302R、303R、304Rは、図2(A)中のPD204に相当する。すなわち、各画素において、左目用画像データを出力する第1の光電変換部(PD203)と、右目用画像データを出力する第2の光電変換部(PD204)とを有する。
In order to provide a two-dimensional image, the
次に、図2(B)に示す画素構成を有する撮像素子100の受光について説明する。図3は撮影レンズの射出瞳から出た光束が撮像素子100に入射する様子を表した概念図である。
画素アレイ101は、マイクロレンズ202と、カラーフィルタ403と、PD404および405を有する。PD404、PD405は、図2(A)中のPD203、PD204にそれぞれ相当する。
Next, light reception of the
The
図3において、各マイクロレンズ202に対して、撮影レンズの射出瞳406から出た光束の中心を光軸409とする。射出瞳406から出た光は、光軸409を中心として撮像素子100に入射する。一部領域407、408は、撮影レンズの射出瞳406の領域である。光線410、411は、一部領域407を通過する光のうち最外周の光線である。光線412、413は、一部領域408を通過する光のうち最外周の光線である。
In FIG. 3, the center of the light beam emitted from the
射出瞳406から出る光束のうち、光軸409を境界線として、図3の上側の光束はPD405に入射し、下側の光束はPD404に入射する。つまり、PD404とPD405は、撮影光学系の射出瞳の異なる領域からの光束をそれぞれ受光する。
Among the light beams emitted from the
図4は、本実施形態の撮像装置の構成例を示す。以下、図4を参照してデジタルカメラへの適用例について説明する。撮像光学系を構成するレンズ部501は、被写体からの光を撮像素子505に結像する。撮像素子505は、図1に示す撮像素子100に相当し、図2(B)に示す画素構成を有する。
FIG. 4 shows a configuration example of the imaging apparatus of the present embodiment. Hereinafter, an application example to a digital camera will be described with reference to FIG. The
レンズ駆動装置502は、ズーム制御、フォーカス制御、絞り制御等を行う。メカニカルシャッタ503は、シャッタ駆動装置504によって制御される。撮像素子505は、レンズ部501により結像した被写体像を画像信号に光電変換する。撮像信号処理回路506は、撮像素子505の出力する画像信号に対して各種の処理や補正、データ圧縮等を行う。タイミング発生部507は、撮像素子505や撮像信号処理回路506に必要なタイミング信号を出力する。
The
システム制御部509は各種演算を行い、撮像装置全体を制御する制御手段であり、不図示のCPU(中央演算処理装置)がプログラムを実行することで処理を行う。システム制御部509は、画像合成回路513によって生成される合成画像データと、視差マップ生成回路514によって生成される視差マップデータに基づいて、立体視表示に使用する左目用画像と右目用画像の各データの生成処理を制御する。また、システム制御部509は、左目用画像と右目用画像の再生制御を行うことで、ユーザは表示画面上で立体画像を鑑賞できる。なお、システム制御部509は、左目用画像データと右目用画像データに基づいて位相差を検出して、位相差AF(オートフォーカス)を実現することもできる。
A
記憶部508は、画像データを一時的に記憶するメモリを備える。記録媒体制御インターフェース部(以下、インターフェースをI/Fと略記する)510は、記録媒体511に画像データ等を記録し、または読み出す。撮像装置に着脱可能な記録媒体511は、半導体メモリ等である。外部I/F部512は、外部装置との間でデータを送受する。表示部516は、表示制御回路517からの表示用データに従って、各種情報や撮影画像を表示する。
The
撮像信号処理回路506は、撮像素子505が出力する撮像データを左目用画像データと右目用画像データに振り分けて画像処理を行う。記憶部508は、撮像信号処理回路506の出力データ、画像合成回路513によって生成された合成画像データ、視差マップ生成回路514によって生成された視差マップデータを記憶する。
The imaging
画像合成回路513は、左目用画像と右目用画像とを合成し、合成画像データを生成する。視差マップ生成回路514は視差量算出処理を行う。視差マップ生成回路514は、合成画像での被写体像の位置を基準として左目用画像/右目用画像での被写体像の位置ずれ量を視差量として算出する。視差マップ生成回路514は、検出した視差量と、視差量に係る基準値を用いて視差量を補正する。補正後の視差量を示すデータは視差マップデータとして記憶部508に記憶される。視差補正処理の詳細については後述する。測光装置515は、露出制御に用いる測光値を取得してシステム制御部509に出力する。操作部518はレリーズスイッチ等を有し、ユーザの操作指示をシステム制御部509に出力する。
The
次に、本実施形態における撮影時のカメラ動作を説明する。メイン電源が投入されると、制御系回路部の電源がオン状態となる。更に撮像信号処理回路506等の撮像処理系回路の電源がオン状態となり、カメラがスタンバイ状態となる。システム制御部509は、ユーザが操作部518のレリーズボタンを操作したか否かを判定する。撮影動作を開始させる操作指示があった場合、システム制御部509は、撮像素子505からの出力データに基づいて焦点状態検出および焦点調節動作に係る演算処理を行う。この演算処理では、カメラから被写体までの距離に応じた合焦位置が算出され、フォーカスレンズの駆動量が算出される。システム制御部509は、演算結果に従ってレンズ駆動装置502を介してレンズ部501の駆動制御を行い、合焦状態であるか否かを判定する。
Next, the camera operation at the time of shooting in the present embodiment will be described. When the main power supply is turned on, the power supply of the control system circuit unit is turned on. Further, the power of the imaging processing system circuit such as the imaging
システム制御部509は、合焦状態でないと判定した場合、再びレンズ部501の駆動制御により、焦点状態の検出処理を実行する。なお、被写体までの距離を求める演算については、撮像素子505からのデータから算出する方法以外に、図示しない測距専用装置を用いて行う方法でも構わない。システム制御部509は、合焦状態と判定した後に撮影動作を開始させる。撮影動作が終了すると、撮像信号処理回路506は撮像素子505が出力した画像信号を処理し、システム制御部509は画像データを記憶部508に書き込む制御を行う。
If the
次に、本実施形態における画像処理について説明する。
撮像素子505は、PDからの全ての画像信号を出力する。図2(B)に示す例では、各PD、つまり301L、301R、302L、302R、303L、303R、304L、304Rという具合に、画像信号が順番に出力される。撮像信号処理回路506は、撮像素子505の出力信号から画像データを取得し、左目用画像データと右目用画像データへのデータ分離処理を行う。左目用画像のデータは、図2(B)におけるPD301L、302L、303L、304L等の出力(左PD出力)のみを選択的に処理した画像データである。また、右目用画像データは、図2(B)におけるPD301R、302R、303R、304R等の出力(右PD出力)のみを選択的に処理した画像データである。左目用画像データと右目用画像データは別々に記憶部508に保存される。
Next, image processing in this embodiment will be described.
The
記憶部508に記憶された左目用画像データおよび右目用画像データは、画像合成回路513に送られて合成画像データが生成される。生成された合成画像データは記憶部508に保存される。画像合成回路513が行う画像処理は、左目用画像データと右目用画像データに対して画素毎の加算平均値を求める加算合成処理である。撮像素子505から読み出した画像データにて、左目用画像と右目用画像とで被写体の形状が異なって撮影された場合でも、画像合成処理によって被写体の形状が補間されて、正しい形状の画像データが生成される。なお、撮像信号処理回路506が、画像処理を行った後の左目用画像と右目用画像とを合成する構成でもよい。
The left-eye image data and right-eye image data stored in the
次に、視差マップ生成回路514は左目用画像データと右目用画像データを用いて、視差マップデータを生成する。求めた視差マップデータは記憶部508に保存される。視差マップに保存される情報について、図5を用いて説明する。
Next, the parallax
図5は撮影画像を模式的に示す図である。図5(A)は、画像枠601内にて、カメラからの距離が異なる3つの被写体像602から604を示す。図5(B)の矢印Zは奥行き方向を表し、被写体602はカメラから最も遠い被写体を表す。被写体604はカメラに最も近い被写体を表し、被写体603は、被写体602と604との間の距離に位置する被写体を表す。
FIG. 5 is a diagram schematically showing a captured image. FIG. 5A shows three
図5(C)は、図5(A)の画像枠601で示す構図を撮影した場合に得られるステレオ画像をそれぞれ示す。画像枠605に示す左目用画像には、各被写体602、603、604に各々相当する像607L、608L、609Lが写っている。また画像枠606に示す右目用画像には、被写体602、603、604に各々相当する像607R、608R、609Rが写っている。図中の1点鎖線は、画像枠605、606における被写体像の位置関係を表しており、左目用画像と右目用画像での被写体のシフト量を視差量と定義する。視差量610は、被写体602に関する、左目用画像と右目用画像での位置ずれ量、つまり像607Lと607Rの視差を表す。同様に視差量611は被写体604に関し、像609Lと609Rの位置ずれ量を表す。なお、被写体603については、左目用画像と右目用画像との間で、視差量がゼロの状態を示している。
FIG. 5C shows a stereo image obtained when the composition shown by the
視差マップ生成回路514は視差量を求める際、画像枠605内の左目用画像と画像枠606内の右目用画像に含まれる被写体像の位置を検出し、被写体像同士のシフト量を求めることで視差量を算出する。具体的には、視差マップ生成回路514に左目用画像データと右目用画像データが入力された場合、視差量610と611が算出される。そして、合成画像における被写体像の重心、つまり左目用画像での重心と右目用画像での重心との中点を基準として、左目用画像または右目用画像での被写体像の重心までの距離が演算により求められる。視差量610の半分の量612を示すデータと、視差量611の半分の量613を示すデータが、視差マップの情報として記憶部508に保存される。
When obtaining the parallax amount, the parallax
次に、左目用画像および右目用画像がステレオ表示装置に表示された場合に、観察者に立体感を与える理由について、図6を参照して説明する。
図6はステレオ表示での映像鑑賞時の様子を模式的に示し、ステレオ表示装置と観察者を上から俯瞰した図である。観察者702は、ステレオ表示装置のスクリーン面701を観察し、その左目703Lと右目703Rの位置をそれぞれに示す。スクリーン面701に映し出される各々の被写体の特徴点が、右目703Lと右目703Rに投影される様子を点線で模式的に示す。
Next, the reason why a stereoscopic effect is given to the observer when the left-eye image and the right-eye image are displayed on the stereo display device will be described with reference to FIG.
FIG. 6 is a diagram schematically showing a state of viewing a video in a stereo display, and is an overhead view of the stereo display device and an observer. The
スクリーン面701には、左目用画像、右目用画像が表示されて、観察者の左目703L、右目703Rのみに各々投影される。三角形、円形、四角形で示す各位置は、図5に示した被写体602ないし604の1点を表す。これらは、例えば、三角形(602参照)の頂点、楕円形(603参照)の短径上の1点、長方形(604参照)の長辺の中点等の特徴点であり、符号は、図5に示す各像との対応関係を表している。
A left-eye image and a right-eye image are displayed on the
左目用画像における像607L、608L、609Lは左目703Lに投影され、右目用画像における像607R、608R、609Rの映像は右目703Rに投影される。観察者には、左目用画像での像607Lと右目用画像での像607Rに対応する被写体像の位置704が、スクリーン面701よりも奥に見える。また、観察者には、左目用画像での像608Lと右目用画像での像608Rに対応する被写体像の位置705が、スクリーン面701上に見える。さらに、観察者には、左目用画像での像609Lと右目用画像での像609Rに対応する被写体像の位置706が、スクリーン面701よりも手前に飛び出して見える。被写体像の奥行き量や飛び出し量は、左目用画像と右目用画像における被写体像の視差量に依存する。図5の視差量610は、カメラから最も遠い被写体602の映像を表示させた場合の、見かけ上の位置704での奥行き量に対応する。また、視差量611は、カメラから最も近い被写体604の映像を表示させた場合の、見かけ上の位置706での飛び出し量に対応する。つまり、左目用画像と右目用画像との視差量は、被写体を右目と左目で見た場合の視差を表しており、見かけ上の奥行き量や飛び出し量を決定する。
The
本実施形態では、左目用画像と右目用画像に含まれる被写体像をそれぞれ検出してそのシフト量を求める際、合成画像での被写体の重心(左目用画像の重心と右目用画像の重心の中点)を基準とする。この重心から、左目用画像での被写体の重心までの距離、つまり、視差量の半分の情報がデータとして使用される。図5の視差量612は負値であって奥行き量を表し、視差量611は正値であって飛び出し量を表す。なお、被写体ごとに視差量を求める処理を説明したが、画素ごとに視差量を求めて視差マップを生成してもよい。
In this embodiment, when the subject images included in the left-eye image and the right-eye image are detected and their shift amounts are obtained, the center of gravity of the subject in the composite image (the center of gravity of the left-eye image and the right-eye image) Point). The distance from the center of gravity to the center of gravity of the subject in the left-eye image, that is, information that is half the amount of parallax is used as data. The
次に、本実施形態の視差補正について、図7および図8を用いて説明する。図7は画像枠605に示す左目用画像と画像枠606に示す右目用画像、および画像枠801に示す視差補正された左目用画像および画像枠802に示す右目用画像を示す。図8は視差補正の処理例を説明するフローチャートである。以下の処理は視差マップ生成回路514が実行する。つまり、視差マップ生成回路514は、左目用画像データおよび右目用画像データから被写体の視差量を算出する視差量算出処理と、算出した視差量を補正する視差補正処理を担当する。
視差マップ生成回路514は検出した視差量に対して、設定された視差範囲に拡張し、または、縮小する補正を行う。視差量は、絞り、レンズの焦点距離、被写体までの距離、ピント面までの距離等の撮影パラメータによって大きく変動する。そこで視差補正を行うことにより、意図した範囲内の飛び出し量や奥行き量で撮影が可能となる。以下では、視差補正に使用する視差補正率、つまり、設定された視差量の基準値と検出した視差量から演算される比率を「視差拡大率」という。視差拡大率が1より大きい場合に拡大の補正を表し、1未満の場合に縮小の補正を表す。
Next, parallax correction according to the present embodiment will be described with reference to FIGS. 7 and 8. FIG. 7 shows a left-eye image shown in an
The parallax
まず、飛び出し量のみを補正する方法について説明する。本実施形態では、合成画像での位置から、左目用画像にて該当する位置までの距離として視差量を表しているので、視差量が正値の場合、立体視表示の効果上では映像が手前に飛び出して見える状態を表す。つまり、正値の視差量が大きいほど、飛び出し具合が著しいことを意味する。そこで、事前にステップ画像の飛び出し量や奥行き量が適正値となるように、視差量を調査した結果から得られた基準値が用意されている。このデータは記憶部508にて、視差量の基準値として保存されている。記憶部508に保存されている視差量の最大値に対する基準値のデータは、システム制御部509により読み出されて、視差マップ生成回路514に設定される(S901)。次に、生成された視差マップデータの中から正値の視差量だけを対象として、そのうちで最大の視差量が検出される(S902)。図7の例では像609Lの視差量613が検出される。
S902で検出された最大の視差量(図7の視差量613参照)と、S901で設定された視差量の最大値に対する基準値から下式1001を用いて視差拡大率が算出される(S903)。
First, a method for correcting only the pop-out amount will be described. In this embodiment, the amount of parallax is expressed as the distance from the position in the composite image to the corresponding position in the image for the left eye. Therefore, when the amount of parallax is a positive value, the image is on the front for the effect of stereoscopic display. Represents a state that appears to jump out. In other words, the larger the positive parallax amount, the greater the degree of popping out. Therefore, a reference value obtained from the result of examining the amount of parallax is prepared so that the amount of projection and depth of the step image become appropriate values in advance. This data is stored in the
The parallax expansion rate is calculated using the following equation 1001 from the maximum parallax amount detected in S902 (see the
視差量の最大値に対する基準値と、検出された視差量の最大値との比率から視差拡大率が算出される。
The parallax expansion rate is calculated from the ratio between the reference value for the maximum value of the parallax amount and the maximum value of the detected parallax amount.
被写体ごとに視差量を求める場合、視差量の総数は検出された被写体の数だけ存在する。また、画素ごとに視差量を求める場合、視差量の総数は画素数に等しい。各場合で視差マップ内に存在する視差量の総数は異なるが、その全てについて、視差量に対する視差補正処理が実行される。そのために、視差量の個数について計数に使用するカウンタの値(iと記す)が初期化され、初期値1が設定される(S904)。そして、カウンタ値iが視差量の総数を超えているか否かについて判定される(S905)。カウンタ値iが視差量の総数を超えていないと判定された場合、S906に処理を進める。S906では、図7に例示する視差量612や613に対して、S903で算出した視差拡大率を用いて、視差量806や807にそれぞれ補正する処理が行われる。つまり、視差量612や613に視差拡大率を乗算して視差補正が行われる。そして、カウンタ値iに1を加算するインクリメント処理(S907)が行われた後、S905に戻る。S905でカウンタ値iが視差量の総数を超えていると判定された場合、視差補正を終了する。但し、S902で視差マップから正値の視差量を検出できなかった場合、視差補正を行う必要はない。また、S901とS902の処理の順番はどちらが先でもよい。S901に示す視差量の基準値の設定処理は事前に行っておいてもよく、また、視差量の総数に亘る視差補正処理ではカウンタを使用しない方法でもよい。なお、視差マップ生成回路514が視差補正を行う例を説明したが、システム制御部509が視差補正を行ってもよい。この場合、システム制御部509は、視差マップ生成回路514が算出した視差量と、設定された視差量の基準値から演算した視差拡大率を用いて視差量を補正する。
When obtaining the amount of parallax for each subject, the total number of parallax amounts is the same as the number of detected subjects. Further, when the amount of parallax is obtained for each pixel, the total number of parallax amounts is equal to the number of pixels. Although the total number of parallax amounts existing in the parallax map is different in each case, the parallax correction processing for the parallax amount is executed for all of them. For this purpose, a counter value (denoted i) used for counting the number of parallax amounts is initialized, and an
次に、立体視表示映像の奥行き量に係る視差補正について説明する。図8のS901では視差量の最小値に対する基準値が設定される。S902で視差マップの中から負値の視差量だけを対象として、その最小の視差量が検出される。S903では、下式1002を用いて視差拡大率が算出される。 Next, the parallax correction related to the depth amount of the stereoscopic display video will be described. In S901 of FIG. 8, a reference value for the minimum value of the parallax amount is set. In S902, the minimum amount of parallax is detected only for the negative amount of parallax from the parallax map. In step S903, the parallax magnification rate is calculated using the following expression 1002.
視差量の最小値に対する基準値と、検出された視差量の最小値との比率から視差拡大率が算出される。
The parallax magnification rate is calculated from the ratio between the reference value for the minimum value of the parallax amount and the minimum value of the detected parallax amount.
S904ないしS907では前記と同様に、視差量の全てに対して、上式1002で算出した視差拡大率を用いて視差補正が行われる。
次に、最大視差量と最小視差量の差を基準にした補正を行う場合について説明する。図8のS901では、視差量の最大値と最小値の差に対する基準値が設定される。S902では視差マップの中から最大の視差量と最小の視差量が検出される。S903で下式1003を用いて視差拡大率が算出される。
In S904 to S907, as described above, the parallax correction is performed on all the parallax amounts using the parallax enlargement ratio calculated by the above equation 1002.
Next, a case where correction is performed based on the difference between the maximum parallax amount and the minimum parallax amount will be described. In S901 of FIG. 8, a reference value for the difference between the maximum value and the minimum value of the parallax amount is set. In S902, the maximum parallax amount and the minimum parallax amount are detected from the parallax map. In step S903, the parallax enlargement ratio is calculated using the following expression 1003.
視差量の最大値と最小値との差に対する基準値と、検出された視差量の最大値と最小値の差との比率から視差拡大率が算出される。
The parallax enlargement ratio is calculated from the ratio between the reference value for the difference between the maximum value and the minimum value of the parallax amount and the difference between the maximum value and the minimum value of the detected parallax amount.
S904ないしS907では前記と同様に、視差量の全てに対して、上式1003で算出した視差拡大率を用いて視差補正が行われる。
なお、前記の処理では、視差拡大率を一定の比率として視差補正処理を行う例を説明したが、飛び出し量または奥行き量に応じた数次の関数式を使って視差拡大率を算出して視差補正を行ってもよい。
視差量の数値表現については、合成画像での被写体の重心(左目用画像の重心と右目用画像の重心の中点)を基準として、左目用画像または右目用画像にて対応する重心までの距離で表す方法に限定されない。例えば、左目用画像での重心を基準として、右目用画像にて対応する重心までの距離で表す方法と、これとは逆に、右目用画像での重心を基準として、左目用画像にて対応する重心までの距離で表す方法がある。このような方法の違いにより、飛び出し量が負値になり、また奥行き量が正値になる場合がある。よって、各方法に応じて基準値の設定や視差量を変更する必要がある。さらに、視差量として負の数を扱わないようにするためには、視差量全体に対して固定値をオフセットとして加算して視差マップを生成する処理が行われる。この場合には、視差量から固定値を減算してから、視差補正が行われる。
視差補正後の視差マップデータは記憶部508に保存される。記憶部508には、画像合成回路513によって生成された合成画像データも記憶されている。システム制御部509の制御下で、合成画像データや視差マップデータは記録媒体制御I/F部510から、半導体メモリ等の着脱可能な記録媒体511に所定のファイル形式で記録される。
In S904 to S907, as described above, the parallax correction is performed on all the parallax amounts using the parallax expansion rate calculated by the above equation 1003.
In the above-described processing, the example in which the parallax correction processing is performed with the parallax magnification rate being a constant ratio has been described. However, the parallax magnification rate is calculated by calculating the parallax magnification rate using a mathematical function according to the pop-out amount or the depth amount. Correction may be performed.
For the numerical expression of the amount of parallax, the distance to the corresponding center of gravity in the left-eye image or right-eye image based on the center of gravity of the subject in the composite image (the midpoint between the center of gravity of the left-eye image and the center of gravity of the right-eye image) It is not limited to the method represented by. For example, using the center of gravity in the image for the left eye as a reference and the distance to the corresponding center of gravity in the image for the right eye, on the contrary, the method for the left eye using the center of gravity in the image for the right eye as a reference There is a method to express by the distance to the center of gravity. Due to such a difference in method, the pop-out amount may be a negative value, and the depth amount may be a positive value. Therefore, it is necessary to change the setting of the reference value and the amount of parallax according to each method. Furthermore, in order not to handle negative numbers as the amount of parallax, processing for generating a parallax map by adding a fixed value as an offset to the entire amount of parallax is performed. In this case, the parallax correction is performed after the fixed value is subtracted from the parallax amount.
The parallax map data after the parallax correction is stored in the
第1実施形態では、視差量の基準値に基づいて視差補正を行い、補正後の視差マップデータを合成画像データとともに記録媒体に記録する処理が行われる。すなわち、視差量の基準値を用いて算出した視差補正率により、飛び出し具合や奥行き量が適正範囲となるように視差量が補正される。よって、撮影時の撮影パラメータが変動しても、常に適切な立体感を奏する視差マップと合成画像を提供できる。 In the first embodiment, a process of performing parallax correction based on the reference value of the parallax amount and recording the corrected parallax map data together with the composite image data on a recording medium is performed. In other words, the amount of parallax is corrected by the parallax correction rate calculated using the reference value of the amount of parallax so that the pop-out degree and the depth amount are in an appropriate range. Therefore, it is possible to provide a parallax map and a composite image that always provide an appropriate stereoscopic effect even when shooting parameters at the time of shooting vary.
[第2実施形態]
次に本発明の第2実施形態を説明する。なお、第2実施形態に係る撮像装置の構成は第1実施形態の場合と同様であるため、既に使用した符号を用いることにより、各部の詳細な説明を省略し、相違点を説明する。
[Second Embodiment]
Next, a second embodiment of the present invention will be described. Since the configuration of the imaging apparatus according to the second embodiment is the same as that of the first embodiment, the detailed description of each part is omitted by using the reference numerals already used, and differences will be described.
第2実施形態では、記憶部508に保存されている基準値を使用する代わりに、ユーザ操作によって設定した基準値を使用する。以下、図8のS901の処理を説明する。図9は、視差補正時に使用する視差量の基準値を、ユーザ操作により設定する処理例を説明するフローチャートである。本処理は図4の操作部518の操作指示を受け付けたシステム制御部509により実行される。操作部518は、ユーザが視差量の基準値の入力操作または選択操作に使用する。
本実施形態では、表示部516の表示画面上にステレオ画像を表示させ、立体感がユーザの好みに合致したステレオ画像を選択させる処理が実行される。操作部518を使用したユーザ操作により選択されたステレオ画像から視差量の基準値を算出する処理が行われ、算出した基準値が視差補正時に設定される。これにより、撮影したステレオ画像の視差マップは、ユーザの設定したステレオ画像と同等の立体感をもつように生成される。
In the second embodiment, instead of using the reference value stored in the
In the present embodiment, a process of displaying a stereo image on the display screen of the
ユーザがステレオ画像を選択する方法については、例えば、表示部516の表示画面上にサンプル画像を提示してその中から選択する方法や、記録媒体511に保存されている任意の画像からユーザが選択する方法等がある。この場合、操作部518は、ユーザが視差量の異なる複数の画像から1つを選択したときの操作指示信号をシステム制御部509に出力する。操作部518を用いてユーザがステレオ画像の選択操作を行った場合、その選択により設定された画像の視差量が検出される(S1101)。次に、飛び出し量を補正する場合には、ステレオ画像の視差量の中から最大値が検出される(S1102)。その最大値のデータは記憶部508に保存される(S1103)。視差補正時には、S1103で保存した値が視差量の基準値として設定される(図8のS901参照)。
As for a method for selecting a stereo image by the user, for example, a method of selecting a sample image from a display image of the
なお、前記の例ではユーザ操作による画像選択処理および基準値設定処理を説明したが、視差拡大レベルの設定処理および基準設定処理を行っても構わない。例えば、システム制御部509は、視差拡大レベルを設定するGUI画面等をユーザに提示して設定する処理を行う。ユーザは選択操作を行って意図するレベルを操作部518でシステム制御部509に指示する。あるいはユーザが基準値の数値入力操作を行ってもよい。選択操作や入力操作によって指定される設定レベルに応じた基準値が図8のS901で設定される。
In the above example, the image selection process and the reference value setting process by the user operation have been described. However, the parallax magnification level setting process and the reference setting process may be performed. For example, the
第2実施形態では、ユーザが選択した画像や視差拡大レベル等の値に従って設定された基準値に基づいて視差補正率が演算されて視差補正が行われる。視差補正後の視差マップデータは合成画像データとともに記録媒体に記録される。よって、撮影時の撮影パラメータが変動しても、常にユーザが望んでいる立体感が得られる視差マップと合成画像を提供できる。 In the second embodiment, the parallax correction rate is calculated based on the reference value set according to the image selected by the user, the value such as the parallax magnification level, and the parallax correction is performed. The parallax map data after the parallax correction is recorded on the recording medium together with the composite image data. Therefore, it is possible to provide a parallax map and a composite image that always provide the stereoscopic effect desired by the user even if the shooting parameters at the time of shooting vary.
201 画素
202 マイクロレンズ
203,204 PD
505 撮像素子
509 システム制御部
513 画像合成回路
514 視差マップ生成回路
518 操作部
201
505
Claims (9)
前記視差を有する複数の画像データから被写体の視差量を算出する視差量算出手段と、
前記視差量算出手段が算出した視差量と、設定された視差量の基準値から視差補正率を算出し、前記視差量に前記視差補正率を乗算して拡大および縮小の視差補正を行う視差補正手段を備え、
前記視差補正手段は、算出された正値の前記視差量に対応する第1の基準値および算出された負値の前記視差量に対応する第2の基準値と、算出された前記視差量との比率から前記視差補正率をそれぞれ算出することを特徴とする画像処理装置。 An image processing apparatus that acquires a plurality of image data having parallax and performs image generation processing,
A parallax amount calculating means for calculating a parallax amount of the subject from the plurality of image data having the parallax;
Parallax correction for calculating a parallax correction rate from the parallax amount calculated by the parallax amount calculating means and a reference value of the set parallax amount, and multiplying the parallax amount by the parallax correction rate to perform enlargement / reduction parallax correction With means ,
The parallax correction means includes a first reference value corresponding to the calculated positive parallax amount, a second reference value corresponding to the calculated negative parallax amount, and the calculated parallax amount. the image processing apparatus according to claim from ratios to calculate the parallax correction factor, respectively.
前記視差補正手段は、前記操作手段から取得した前記第1および第2の基準値を設定して視差補正を行うことを特徴とする請求項1から3のいずれか1項に記載の画像処理装置。 Operating means used for input operation or selection operation of the first and second reference values;
The parallax correction means the image processing apparatus according to any one of claims 1 to 3, characterized in that to set to parallax correcting the first and second reference values obtained from said operation means .
前記視差補正手段は、前記操作手段により選択された画像の視差量を取得し、該視差量を前記第1および第2の基準値として設定して視差補正を行うことを特徴とする請求項1から3のいずれか1項に記載の画像処理装置。 Comprising an operation means used for selecting one of a plurality of images having different parallax amounts;
The parallax correction unit acquires the parallax amount of the image selected by the operation unit, sets the parallax amount as the first and second reference values, and performs parallax correction. 4. The image processing device according to any one of items 1 to 3 .
請求項1から7のいずれか1項に記載の画像処理装置と、を有することを特徴とする撮像装置。An image processing apparatus comprising: the image processing apparatus according to claim 1.
前記視差を有する複数の画像データから被写体の視差量を算出する視差量算出ステップと、
前記視差量算出ステップで算出した視差量と、設定された視差量の基準値から視差補正率を算出し、前記視差量に前記視差補正率を乗算して拡大および縮小の視差補正を行う視差補正ステップを有し、
前記視差補正ステップでは、算出された正値の前記視差量に対応する第1の基準値および算出された負値の前記視差量に対応する第2の基準値と、算出された前記視差量との比率から前記視差補正率をそれぞれ算出することを特徴とする画像処理装置の制御方法。
A control method executed by an image processing apparatus that acquires a plurality of image data having parallax and performs image generation processing,
A parallax amount calculating step of calculating a parallax amount of the subject from a plurality of image data having the parallax;
Parallax correction for calculating a parallax correction rate from the parallax amount calculated in the parallax amount calculating step and a reference value of the set parallax amount, and multiplying the parallax amount by the parallax correction rate to perform enlargement / reduction parallax correction step have a,
In the parallax correction step, a first reference value corresponding to the calculated positive parallax amount, a second reference value corresponding to the calculated negative parallax amount, and the calculated parallax amount A control method for an image processing apparatus , wherein the parallax correction rate is calculated from each ratio .
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2012116875A JP6004741B2 (en) | 2012-05-22 | 2012-05-22 | Image processing apparatus, control method therefor, and imaging apparatus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2012116875A JP6004741B2 (en) | 2012-05-22 | 2012-05-22 | Image processing apparatus, control method therefor, and imaging apparatus |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2013243602A JP2013243602A (en) | 2013-12-05 |
JP6004741B2 true JP6004741B2 (en) | 2016-10-12 |
Family
ID=49844062
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2012116875A Active JP6004741B2 (en) | 2012-05-22 | 2012-05-22 | Image processing apparatus, control method therefor, and imaging apparatus |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6004741B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6253030B2 (en) * | 2015-02-06 | 2017-12-27 | パナソニックIpマネジメント株式会社 | Image processing apparatus, imaging apparatus, and image processing method |
US10536633B2 (en) | 2015-02-06 | 2020-01-14 | Panasonic Intellectual Property Management Co., Ltd. | Image processing device, imaging system and imaging apparatus including the same, and image processing method |
JP7006498B2 (en) * | 2018-05-15 | 2022-01-24 | 株式会社デンソー | Head-up display |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5505881B2 (en) * | 2010-02-02 | 2014-05-28 | 学校法人早稲田大学 | Stereoscopic image production apparatus and program |
CN102812714B (en) * | 2010-03-24 | 2014-04-30 | 富士胶片株式会社 | 3D imaging device |
WO2011162209A1 (en) * | 2010-06-25 | 2011-12-29 | 富士フイルム株式会社 | Image output device, method, and program |
JP2012090094A (en) * | 2010-10-20 | 2012-05-10 | Sony Corp | Image processing device, image processing method, and program |
JP5302285B2 (en) * | 2010-10-28 | 2013-10-02 | シャープ株式会社 | Stereoscopic video output device, stereoscopic video output method, stereoscopic video output program, computer-readable recording medium, and stereoscopic video display device |
-
2012
- 2012-05-22 JP JP2012116875A patent/JP6004741B2/en active Active
Also Published As
Publication number | Publication date |
---|---|
JP2013243602A (en) | 2013-12-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103493484B (en) | Imaging device and formation method | |
US9341935B2 (en) | Image capturing device | |
US10587860B2 (en) | Imaging apparatus and method for controlling same | |
US9648305B2 (en) | Stereoscopic imaging apparatus and stereoscopic imaging method | |
US10574906B2 (en) | Image processing apparatus and image processing method | |
WO2013038629A1 (en) | Imaging apparatus and method for controlling same | |
JP5627438B2 (en) | IMAGING DEVICE, ITS CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM | |
JP6004741B2 (en) | Image processing apparatus, control method therefor, and imaging apparatus | |
JP6053276B2 (en) | Imaging apparatus, control method therefor, and image processing apparatus | |
US9369698B2 (en) | Imaging apparatus and method for controlling same | |
JP2014022888A (en) | Image pickup device and image pickup device manufacturing method | |
JP2012124650A (en) | Imaging apparatus, and imaging method | |
JP5864992B2 (en) | Imaging apparatus and control method thereof, and image processing apparatus and control method thereof | |
JP2012094997A (en) | Imaging device | |
JP6230266B2 (en) | Imaging apparatus, image processing apparatus, and control method | |
JP2013242378A (en) | Imaging device, display method, and program | |
JP2014204299A (en) | Imaging apparatus and method for controlling the same | |
JP5911276B2 (en) | Imaging apparatus, control method therefor, and image processing apparatus | |
WO2015163350A1 (en) | Image processing device, imaging device and image processing program | |
JP5963483B2 (en) | IMAGING DEVICE AND IMAGING DEVICE CONTROL METHOD | |
JP2014090252A (en) | Image processing device and control method for the same, image pickup device and control method for the same and image processing program | |
JP6172949B2 (en) | IMAGING DEVICE, IMAGING DEVICE CONTROL METHOD, IMAGE PROCESSING DEVICE, AND IMAGE PROCESSING DEVICE CONTROL METHOD | |
JP2014146962A (en) | Image pickup device and control method of the same | |
JP2016154360A (en) | Imaging apparatus and control method therefor | |
JP2013157726A (en) | Imaging apparatus and method for controlling imaging apparatus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20150420 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20160210 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20160223 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20160418 |
|
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: 20160809 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20160906 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 6004741 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |