JP6004741B2 - Image processing apparatus, control method therefor, and imaging apparatus - Google Patents

Image processing apparatus, control method therefor, and imaging apparatus Download PDF

Info

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
Application number
JP2012116875A
Other languages
Japanese (ja)
Other versions
JP2013243602A (en
Inventor
智実 千葉
智実 千葉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
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 JP2012116875A priority Critical patent/JP6004741B2/en
Publication of JP2013243602A publication Critical patent/JP2013243602A/en
Application granted granted Critical
Publication of JP6004741B2 publication Critical patent/JP6004741B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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, Patent Documents 1 and 2 disclose a method for simultaneously capturing images from different viewpoints as a method for capturing an image that can be viewed as a stereoscopic video. Patent Document 1 discloses a solid-state imaging device in which a plurality of microlenses are formed, and one or more pairs of photodiodes are arranged in proximity to each of the microlenses. A first image signal is obtained from the output of one of the photodiode pairs, and a second image signal is obtained from the output of the other photodiode. By using the first and second image signals as the left-eye image and the right-eye image, respectively, it is possible to view a stereoscopic video. Patent Document 2 discloses an output parallax map having an output element having an output value corresponding to a shift to be applied to each pixel of the first image. A second image can be generated based on the output parallax map and the first image.

ところで、撮影したステレオ画像を表示装置で表示する際、表示装置の表示画面の大きさと鑑賞者の位置によって、得られる立体感が異なる。視差マップに保存されている視差量は立体感を表現した値であるが、視差量と表示画面の大きさが合っていない場合、ユーザは立体感の不自然さに気付いてしまう。例えば、充分な立体感が得られないことや、逆に立体感が強すぎてユーザの眼に疲労を起こす可能性等が挙げられる。特許文献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.

特開昭58−24105号公報JP-A-58-24105 特表2008−518317号公報Special table 2008-518317 特開2010−045584号公報JP 2010-045584 A

従来の技術では、撮影パラメータの違いによって表示映像の立体感が損なわれないようにする対策が講じられていないという問題がある。
特許文献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.

図2ないし図8と併せて本発明の第1実施形態を説明するために、撮像素子の全体構成を概略的に示す図である。FIG. 9 is a diagram schematically showing an entire configuration of an image sensor for explaining the first embodiment of the present invention in conjunction with FIGS. 2 to 8. 撮像素子の画素の構成例を示す図である。It is a figure which shows the structural example of the pixel of an image pick-up element. 撮影レンズの射出瞳から出た光束が撮像素子に入射する様子を表した概念図である。It is the conceptual diagram showing a mode that the light beam which came out of the exit pupil of the imaging lens injects into an image pick-up element. 撮像装置の構成例を示す図である。It is a figure which shows the structural example of an imaging device. 視差マップデータの生成処理例を説明する図である。It is a figure explaining the production | generation process example of parallax map data. ステレオ画像観賞時の様子を模式的に示す図である。It is a figure which shows typically the mode at the time of stereo image appreciation. 視差補正処理を概念的に示す図である。It is a figure which shows a parallax correction process notionally. 視差補正処理例を説明するフローチャートである。It is a flowchart explaining the example of a parallax correction process. 本発明の第2実施形態における、視差補正時の基準値の設定処理例を説明するフローチャートである。It is a flowchart explaining the setting process example of the reference value at the time of parallax correction in 2nd Embodiment of this invention.

以下に、本発明の各実施形態を、添付図面に基づいて詳細に説明する。
[第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 image sensor 100 includes a pixel array 101, a vertical selection circuit 102 that selects a row in the pixel array 101, and a horizontal selection circuit 104 that selects a column in the pixel array 101. The readout circuit 103 reads out the signal of the pixel selected by the vertical selection circuit 102 among the pixels in the pixel array 101. The reading circuit 103 includes a memory for accumulating signals, a gain amplifier, an AD converter, and the like for each column.

シリアルインターフェース(SI)部105は、各回路の動作モード等を外部回路からの指示に従って決定する。垂直選択回路102は、画素アレイ101の複数の行を順次選択し、読み出し回路103に画素信号を取り出す。また水平選択回路104は、読み出し回路103によって読み出された複数の画素信号を列毎に順次選択する。なお、撮像素子100には、図1に示す構成要素以外に、例えば、垂直選択回路102、水平選択回路104、読み出し回路103等にタイミング信号を提供するタイミングジェネレータや、制御回路等が存在するが、これらの詳細な説明は省略する。   The serial interface (SI) unit 105 determines an operation mode of each circuit according to an instruction from an external circuit. The vertical selection circuit 102 sequentially selects a plurality of rows in the pixel array 101 and extracts pixel signals to the readout circuit 103. The horizontal selection circuit 104 sequentially selects a plurality of pixel signals read by the reading circuit 103 for each column. In addition to the components shown in FIG. 1, the imaging device 100 includes a timing generator that provides timing signals to the vertical selection circuit 102, the horizontal selection circuit 104, the readout circuit 103, and the like, a control circuit, and the like. Detailed description thereof will be omitted.

図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 image sensor 100. FIG. 2A schematically shows the configuration of one pixel. FIG. 2B shows the arrangement of the pixel array 101. A pixel 201 illustrated in FIG. 2A includes a microlens 202 as an optical element and a plurality of photodiodes (hereinafter abbreviated as PD) as light receiving elements.

図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 left PD 203 and the right PD 204, are provided in one pixel, but three or more (for example, four or nine) PDs may be used. The PD 203 photoelectrically converts the received light beam and outputs a left-eye image signal. The PD 204 photoelectrically converts the received light beam and outputs a right eye image signal. The pixel 201 includes, for example, a pixel amplification amplifier that extracts a PD signal to the readout circuit 103, a row selection switch, a PD signal reset switch, and the like in addition to the illustrated components.

画素アレイ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 pixel array 101 is arranged in a two-dimensional array like a large number of pixels 301 to 304 shown in FIG. In the pixels 301 to 304, PDs 301L, 302L, 303L, and 304L correspond to the PD 203 in FIG. PDs 301R, 302R, 303R, and 304R correspond to the PD 204 in FIG. That is, each pixel has a first photoelectric conversion unit (PD 203) that outputs image data for the left eye and a second photoelectric conversion unit (PD 204) that outputs image data for the right eye.

次に、図2(B)に示す画素構成を有する撮像素子100の受光について説明する。図3は撮影レンズの射出瞳から出た光束が撮像素子100に入射する様子を表した概念図である。
画素アレイ101は、マイクロレンズ202と、カラーフィルタ403と、PD404および405を有する。PD404、PD405は、図2(A)中のPD203、PD204にそれぞれ相当する。
Next, light reception of the imaging element 100 having the pixel configuration illustrated in FIG. FIG. 3 is a conceptual diagram showing a state where a light beam emitted from the exit pupil of the photographing lens is incident on the image sensor 100.
The pixel array 101 includes a microlens 202, a color filter 403, and PDs 404 and 405. PD 404 and PD 405 correspond to PD 203 and PD 204 in FIG.

図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 exit pupil 406 of the photographing lens is defined as the optical axis 409 for each microlens 202. The light emitted from the exit pupil 406 enters the image sensor 100 with the optical axis 409 as the center. Partial areas 407 and 408 are areas of the exit pupil 406 of the photographing lens. Rays 410 and 411 are the outermost rays among the light passing through the partial region 407. Light rays 412 and 413 are the outermost light rays among the light passing through the partial region 408.

射出瞳406から出る光束のうち、光軸409を境界線として、図3の上側の光束はPD405に入射し、下側の光束はPD404に入射する。つまり、PD404とPD405は、撮影光学系の射出瞳の異なる領域からの光束をそれぞれ受光する。   Among the light beams emitted from the exit pupil 406, with the optical axis 409 as a boundary line, the upper light beam in FIG. 3 is incident on the PD 405, and the lower light beam is incident on the PD 404. That is, PD 404 and PD 405 receive light beams from different regions of the exit pupil of the photographing optical system.

図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 lens unit 501 constituting the imaging optical system forms an image of light from the subject on the imaging element 505. The imaging element 505 corresponds to the imaging element 100 illustrated in FIG. 1 and has a pixel configuration illustrated in FIG.

レンズ駆動装置502は、ズーム制御、フォーカス制御、絞り制御等を行う。メカニカルシャッタ503は、シャッタ駆動装置504によって制御される。撮像素子505は、レンズ部501により結像した被写体像を画像信号に光電変換する。撮像信号処理回路506は、撮像素子505の出力する画像信号に対して各種の処理や補正、データ圧縮等を行う。タイミング発生部507は、撮像素子505や撮像信号処理回路506に必要なタイミング信号を出力する。   The lens driving device 502 performs zoom control, focus control, aperture control, and the like. The mechanical shutter 503 is controlled by a shutter driving device 504. The image sensor 505 photoelectrically converts the subject image formed by the lens unit 501 into an image signal. The imaging signal processing circuit 506 performs various processes, corrections, data compression, and the like on the image signal output from the imaging element 505. The timing generator 507 outputs a timing signal necessary for the image sensor 505 and the image signal processing circuit 506.

システム制御部509は各種演算を行い、撮像装置全体を制御する制御手段であり、不図示のCPU(中央演算処理装置)がプログラムを実行することで処理を行う。システム制御部509は、画像合成回路513によって生成される合成画像データと、視差マップ生成回路514によって生成される視差マップデータに基づいて、立体視表示に使用する左目用画像と右目用画像の各データの生成処理を制御する。また、システム制御部509は、左目用画像と右目用画像の再生制御を行うことで、ユーザは表示画面上で立体画像を鑑賞できる。なお、システム制御部509は、左目用画像データと右目用画像データに基づいて位相差を検出して、位相差AF(オートフォーカス)を実現することもできる。   A system control unit 509 is a control unit that performs various calculations and controls the entire imaging apparatus, and performs processing by a CPU (central processing unit) (not shown) executing a program. Based on the composite image data generated by the image composition circuit 513 and the parallax map data generated by the parallax map generation circuit 514, the system control unit 509 performs processing for each of the left-eye image and the right-eye image used for stereoscopic display. Control the data generation process. In addition, the system control unit 509 performs playback control of the left-eye image and the right-eye image, so that the user can view a stereoscopic image on the display screen. Note that the system control unit 509 can also realize phase difference AF (autofocus) by detecting a phase difference based on the left-eye image data and the right-eye image data.

記憶部508は、画像データを一時的に記憶するメモリを備える。記録媒体制御インターフェース部(以下、インターフェースをI/Fと略記する)510は、記録媒体511に画像データ等を記録し、または読み出す。撮像装置に着脱可能な記録媒体511は、半導体メモリ等である。外部I/F部512は、外部装置との間でデータを送受する。表示部516は、表示制御回路517からの表示用データに従って、各種情報や撮影画像を表示する。   The storage unit 508 includes a memory that temporarily stores image data. A recording medium control interface unit (hereinafter, the interface is abbreviated as I / F) 510 records or reads image data or the like on the recording medium 511. The recording medium 511 that can be attached to and detached from the imaging apparatus is a semiconductor memory or the like. The external I / F unit 512 transmits / receives data to / from an external device. The display unit 516 displays various information and captured images in accordance with display data from the display control circuit 517.

撮像信号処理回路506は、撮像素子505が出力する撮像データを左目用画像データと右目用画像データに振り分けて画像処理を行う。記憶部508は、撮像信号処理回路506の出力データ、画像合成回路513によって生成された合成画像データ、視差マップ生成回路514によって生成された視差マップデータを記憶する。   The imaging signal processing circuit 506 performs image processing by distributing imaging data output from the imaging element 505 into left-eye image data and right-eye image data. The storage unit 508 stores the output data of the imaging signal processing circuit 506, the synthesized image data generated by the image synthesis circuit 513, and the parallax map data generated by the parallax map generation circuit 514.

画像合成回路513は、左目用画像と右目用画像とを合成し、合成画像データを生成する。視差マップ生成回路514は視差量算出処理を行う。視差マップ生成回路514は、合成画像での被写体像の位置を基準として左目用画像/右目用画像での被写体像の位置ずれ量を視差量として算出する。視差マップ生成回路514は、検出した視差量と、視差量に係る基準値を用いて視差量を補正する。補正後の視差量を示すデータは視差マップデータとして記憶部508に記憶される。視差補正処理の詳細については後述する。測光装置515は、露出制御に用いる測光値を取得してシステム制御部509に出力する。操作部518はレリーズスイッチ等を有し、ユーザの操作指示をシステム制御部509に出力する。   The image composition circuit 513 synthesizes the left-eye image and the right-eye image to generate composite image data. The parallax map generation circuit 514 performs a parallax amount calculation process. The parallax map generation circuit 514 calculates, as a parallax amount, a positional deviation amount of the subject image in the left-eye image / right-eye image based on the position of the subject image in the composite image. The parallax map generation circuit 514 corrects the parallax amount using the detected parallax amount and a reference value related to the parallax amount. Data indicating the corrected amount of parallax is stored in the storage unit 508 as parallax map data. Details of the parallax correction processing will be described later. The photometric device 515 acquires a photometric value used for exposure control and outputs it to the system control unit 509. The operation unit 518 includes a release switch and the like, and outputs a user operation instruction to the system control unit 509.

次に、本実施形態における撮影時のカメラ動作を説明する。メイン電源が投入されると、制御系回路部の電源がオン状態となる。更に撮像信号処理回路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 signal processing circuit 506 is turned on, and the camera enters a standby state. The system control unit 509 determines whether the user has operated the release button of the operation unit 518. When there is an operation instruction to start the shooting operation, the system control unit 509 performs arithmetic processing related to focus state detection and focus adjustment operations based on output data from the image sensor 505. In this calculation process, the in-focus position corresponding to the distance from the camera to the subject is calculated, and the driving amount of the focus lens is calculated. The system control unit 509 performs drive control of the lens unit 501 via the lens driving device 502 in accordance with the calculation result, and determines whether or not it is in focus.

システム制御部509は、合焦状態でないと判定した場合、再びレンズ部501の駆動制御により、焦点状態の検出処理を実行する。なお、被写体までの距離を求める演算については、撮像素子505からのデータから算出する方法以外に、図示しない測距専用装置を用いて行う方法でも構わない。システム制御部509は、合焦状態と判定した後に撮影動作を開始させる。撮影動作が終了すると、撮像信号処理回路506は撮像素子505が出力した画像信号を処理し、システム制御部509は画像データを記憶部508に書き込む制御を行う。   If the system control unit 509 determines that it is not in focus, the system control unit 509 executes focus state detection processing again by driving control of the lens unit 501. The calculation for obtaining the distance to the subject may be performed by using a dedicated distance measuring device (not shown) in addition to the method of calculating from the data from the image sensor 505. The system control unit 509 starts the photographing operation after determining the focused state. When the photographing operation is completed, the imaging signal processing circuit 506 processes the image signal output from the imaging element 505, and the system control unit 509 performs control to write the image data in the storage unit 508.

次に、本実施形態における画像処理について説明する。
撮像素子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 image sensor 505 outputs all image signals from the PD. In the example shown in FIG. 2B, image signals are sequentially output in the order of PDs, that is, 301L, 301R, 302L, 302R, 303L, 303R, 304L, and 304R. The imaging signal processing circuit 506 acquires image data from the output signal of the imaging element 505 and performs data separation processing into left-eye image data and right-eye image data. The left-eye image data is image data obtained by selectively processing only the outputs (left PD output) of PDs 301L, 302L, 303L, and 304L in FIG. The right-eye image data is image data obtained by selectively processing only the outputs (right PD output) of PDs 301R, 302R, 303R, 304R, etc. in FIG. The left-eye image data and the right-eye image data are stored in the storage unit 508 separately.

記憶部508に記憶された左目用画像データおよび右目用画像データは、画像合成回路513に送られて合成画像データが生成される。生成された合成画像データは記憶部508に保存される。画像合成回路513が行う画像処理は、左目用画像データと右目用画像データに対して画素毎の加算平均値を求める加算合成処理である。撮像素子505から読み出した画像データにて、左目用画像と右目用画像とで被写体の形状が異なって撮影された場合でも、画像合成処理によって被写体の形状が補間されて、正しい形状の画像データが生成される。なお、撮像信号処理回路506が、画像処理を行った後の左目用画像と右目用画像とを合成する構成でもよい。   The left-eye image data and right-eye image data stored in the storage unit 508 are sent to the image composition circuit 513 to generate composite image data. The generated composite image data is stored in the storage unit 508. The image processing performed by the image composition circuit 513 is addition composition processing for obtaining an addition average value for each pixel with respect to the image data for the left eye and the image data for the right eye. Even when the image data read from the image sensor 505 is photographed with different shapes of the subject for the left-eye image and the right-eye image, the shape of the subject is interpolated by the image composition processing, and image data with the correct shape is obtained. Generated. Note that the imaging signal processing circuit 506 may synthesize the left-eye image and the right-eye image after image processing.

次に、視差マップ生成回路514は左目用画像データと右目用画像データを用いて、視差マップデータを生成する。求めた視差マップデータは記憶部508に保存される。視差マップに保存される情報について、図5を用いて説明する。   Next, the parallax map generation circuit 514 generates parallax map data using the left-eye image data and the right-eye image data. The obtained parallax map data is stored in the storage unit 508. Information stored in the parallax map will be described with reference to FIG.

図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 subject images 602 to 604 having different distances from the camera in the image frame 601. An arrow Z in FIG. 5B represents the depth direction, and a subject 602 represents a subject farthest from the camera. A subject 604 represents a subject closest to the camera, and a subject 603 represents a subject located at a distance between the subjects 602 and 604.

図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 image frame 601 in FIG. The left-eye image shown in the image frame 605 includes images 607L, 608L, and 609L corresponding to the subjects 602, 603, and 604, respectively. The right eye image shown in the image frame 606 includes images 607R, 608R, and 609R corresponding to the subjects 602, 603, and 604, respectively. A one-dot chain line in the figure represents the positional relationship between the subject images in the image frames 605 and 606, and the shift amount of the subject in the left-eye image and the right-eye image is defined as the parallax amount. The parallax amount 610 represents the positional deviation amount between the left-eye image and the right-eye image regarding the subject 602, that is, the parallax between the images 607L and 607R. Similarly, the parallax amount 611 represents the positional deviation amount of the images 609L and 609R with respect to the subject 604. The subject 603 shows a state in which the amount of parallax is zero between the left-eye image and the right-eye image.

視差マップ生成回路514は視差量を求める際、画像枠605内の左目用画像と画像枠606内の右目用画像に含まれる被写体像の位置を検出し、被写体像同士のシフト量を求めることで視差量を算出する。具体的には、視差マップ生成回路514に左目用画像データと右目用画像データが入力された場合、視差量610と611が算出される。そして、合成画像における被写体像の重心、つまり左目用画像での重心と右目用画像での重心との中点を基準として、左目用画像または右目用画像での被写体像の重心までの距離が演算により求められる。視差量610の半分の量612を示すデータと、視差量611の半分の量613を示すデータが、視差マップの情報として記憶部508に保存される。   When obtaining the parallax amount, the parallax map generation circuit 514 detects the position of the subject image included in the left-eye image in the image frame 605 and the right-eye image in the image frame 606, and obtains the shift amount between the subject images. The amount of parallax is calculated. Specifically, when left-eye image data and right-eye image data are input to the parallax map generation circuit 514, parallax amounts 610 and 611 are calculated. Then, the distance to the center of gravity of the subject image in the left-eye image or right-eye image is calculated based on the center point of the subject image in the composite image, that is, the midpoint between the center of gravity in the left-eye image and the center of gravity in the right-eye image. Is required. Data indicating a half amount 612 of the parallax amount 610 and data indicating a half amount 613 of the parallax amount 611 are stored in the storage unit 508 as parallax map information.

次に、左目用画像および右目用画像がステレオ表示装置に表示された場合に、観察者に立体感を与える理由について、図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 observer 702 observes the screen surface 701 of the stereo display device and indicates the positions of the left eye 703L and the right eye 703R, respectively. The manner in which the feature points of each subject projected on the screen surface 701 are projected onto the right eye 703L and the right eye 703R is schematically shown by dotted lines.

スクリーン面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 screen surface 701, and are projected only to the left eye 703L and the right eye 703R of the observer. Each position indicated by a triangle, a circle, and a rectangle represents one point of the subjects 602 to 604 shown in FIG. These are, for example, feature points such as the apex of a triangle (see 602), one point on the minor axis of an ellipse (see 603), and the midpoint of the long side of a rectangle (see 604). The corresponding relationship with each image shown in FIG.

左目用画像における像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 images 607L, 608L, and 609L in the left-eye image are projected onto the left eye 703L, and the images of the images 607R, 608R, and 609R in the right-eye image are projected onto the right eye 703R. For the observer, the position 704 of the subject image corresponding to the image 607L in the left-eye image and the image 607R in the right-eye image appears behind the screen surface 701. In addition, the observer can see the position 705 of the subject image corresponding to the image 608L in the left-eye image and the image 608R in the right-eye image on the screen surface 701. Furthermore, the observer sees the position 706 of the subject image corresponding to the image 609L in the image for the left eye and the image 609R in the image for the right eye that protrudes toward the front of the screen surface 701. The depth amount and the pop-out amount of the subject image depend on the parallax amount of the subject image in the left-eye image and the right-eye image. The parallax amount 610 in FIG. 5 corresponds to the depth amount at the apparent position 704 when the image of the subject 602 farthest from the camera is displayed. Further, the parallax amount 611 corresponds to the pop-out amount at the apparent position 706 when the image of the subject 604 closest to the camera is displayed. That is, the parallax amount between the left-eye image and the right-eye image represents the parallax when the subject is viewed with the right eye and the left eye, and determines the apparent depth amount and pop-out amount.

本実施形態では、左目用画像と右目用画像に含まれる被写体像をそれぞれ検出してそのシフト量を求める際、合成画像での被写体の重心(左目用画像の重心と右目用画像の重心の中点)を基準とする。この重心から、左目用画像での被写体の重心までの距離、つまり、視差量の半分の情報がデータとして使用される。図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 parallax amount 612 in FIG. 5 is a negative value representing the depth amount, and the parallax amount 611 is a positive value representing the pop-out amount. In addition, although the process which calculates | requires the amount of parallax for every to-be-photographed object was demonstrated, you may obtain | require the amount of parallax for every pixel, and may produce | generate a parallax map.

次に、本実施形態の視差補正について、図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 image frame 605, a right-eye image shown in an image frame 606, a parallax-corrected left-eye image shown in an image frame 801, and a right-eye image shown in an image frame 802. FIG. 8 is a flowchart for explaining a processing example of parallax correction. The following processing is executed by the parallax map generation circuit 514. That is, the parallax map generation circuit 514 is in charge of a parallax amount calculation process for calculating the parallax amount of the subject from the left-eye image data and the right-eye image data, and a parallax correction process for correcting the calculated parallax amount.
The parallax map generation circuit 514 performs correction for extending or reducing the detected parallax amount to the set parallax range. The amount of parallax varies greatly depending on shooting parameters such as the aperture, the focal length of the lens, the distance to the subject, and the distance to the focus surface. Therefore, by performing parallax correction, it is possible to shoot with an amount of protrusion and depth within an intended range. Hereinafter, the parallax correction rate used for the parallax correction, that is, the ratio calculated from the set reference value of the parallax amount and the detected parallax amount is referred to as “parallax magnification rate”. When the parallax magnification rate is greater than 1, enlargement correction is indicated, and when it is less than 1, reduction correction is indicated.

まず、飛び出し量のみを補正する方法について説明する。本実施形態では、合成画像での位置から、左目用画像にて該当する位置までの距離として視差量を表しているので、視差量が正値の場合、立体視表示の効果上では映像が手前に飛び出して見える状態を表す。つまり、正値の視差量が大きいほど、飛び出し具合が著しいことを意味する。そこで、事前にステップ画像の飛び出し量や奥行き量が適正値となるように、視差量を調査した結果から得られた基準値が用意されている。このデータは記憶部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 storage unit 508 as a reference value for the amount of parallax. The reference value data for the maximum parallax amount stored in the storage unit 508 is read by the system control unit 509 and set in the parallax map generation circuit 514 (S901). Next, only the positive parallax amount is targeted from the generated parallax map data, and the maximum parallax amount is detected among them (S902). In the example of FIG. 7, the parallax amount 613 of the image 609L is detected.
The parallax expansion rate is calculated using the following equation 1001 from the maximum parallax amount detected in S902 (see the parallax amount 613 in FIG. 7) and the reference value for the maximum parallax amount set in S901 (S903). .

Figure 0006004741

視差量の最大値に対する基準値と、検出された視差量の最大値との比率から視差拡大率が算出される。
Figure 0006004741

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 initial value 1 is set (S904). Then, it is determined whether or not the counter value i exceeds the total number of parallaxes (S905). If it is determined that the counter value i does not exceed the total number of parallax amounts, the process proceeds to S906. In S906, the parallax amounts 612 and 613 illustrated in FIG. 7 are corrected to the parallax amounts 806 and 807, respectively, using the parallax expansion rate calculated in S903. That is, the parallax correction is performed by multiplying the parallax amounts 612 and 613 by the parallax magnification rate. Then, after increment processing for adding 1 to the counter value i (S907) is performed, the process returns to S905. If it is determined in S905 that the counter value i exceeds the total number of parallaxes, the parallax correction is terminated. However, when a positive parallax amount cannot be detected from the parallax map in S902, it is not necessary to perform parallax correction. In addition, the order of the processing of S901 and S902 may be either first. The setting process of the reference value of the parallax amount shown in S901 may be performed in advance, or may be a method that does not use a counter in the parallax correction process over the total number of parallax amounts. Note that although the example in which the parallax map generation circuit 514 performs parallax correction has been described, the system control unit 509 may perform parallax correction. In this case, the system control unit 509 corrects the parallax amount using the parallax amount calculated by the parallax map generation circuit 514 and the parallax enlargement ratio calculated from the set reference value of the parallax amount.

次に、立体視表示映像の奥行き量に係る視差補正について説明する。図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.

Figure 0006004741

視差量の最小値に対する基準値と、検出された視差量の最小値との比率から視差拡大率が算出される。
Figure 0006004741

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.

Figure 0006004741

視差量の最大値と最小値との差に対する基準値と、検出された視差量の最大値と最小値の差との比率から視差拡大率が算出される。
Figure 0006004741

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 storage unit 508. The storage unit 508 also stores composite image data generated by the image composition circuit 513. Under the control of the system control unit 509, the composite image data and the parallax map data are recorded in a predetermined file format from the recording medium control I / F unit 510 to a removable recording medium 511 such as a semiconductor memory.

第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 storage unit 508, the reference value set by the user operation is used. Hereinafter, the process of S901 in FIG. 8 will be described. FIG. 9 is a flowchart for explaining a processing example in which a reference value for the amount of parallax used during parallax correction is set by a user operation. This processing is executed by the system control unit 509 that has received an operation instruction from the operation unit 518 of FIG. The operation unit 518 is used by the user for an input operation or a selection operation for a reference value of the parallax amount.
In the present embodiment, a process of displaying a stereo image on the display screen of the display unit 516 and selecting a stereo image whose stereoscopic effect matches the user's preference is executed. A process of calculating a reference value for the amount of parallax from a stereo image selected by a user operation using the operation unit 518 is performed, and the calculated reference value is set during parallax correction. Thereby, the parallax map of the captured stereo image is generated so as to have a stereoscopic effect equivalent to the stereo image set by the user.

ユーザがステレオ画像を選択する方法については、例えば、表示部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 display unit 516 and selecting the sample image or a user selecting from any image stored in the recording medium 511 There are ways to do this. In this case, the operation unit 518 outputs an operation instruction signal to the system control unit 509 when the user selects one of a plurality of images having different parallax amounts. When the user performs a stereo image selection operation using the operation unit 518, the parallax amount of the image set by the selection is detected (S1101). Next, when correcting the pop-out amount, the maximum value is detected from the parallax amount of the stereo image (S1102). The maximum value data is stored in the storage unit 508 (S1103). At the time of parallax correction, the value stored in S1103 is set as the reference value of the parallax amount (see S901 in FIG. 8).

なお、前記の例ではユーザ操作による画像選択処理および基準値設定処理を説明したが、視差拡大レベルの設定処理および基準設定処理を行っても構わない。例えば、システム制御部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 system control unit 509 performs processing for presenting and setting a GUI screen or the like for setting the parallax magnification level to the user. The user performs a selection operation to instruct the system control unit 509 using the operation unit 518. Alternatively, the user may perform a numerical value input operation for the reference value. A reference value corresponding to the setting level specified by the selection operation or input operation is set in S901 of FIG.

第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 pixels 202 microlenses 203,204 PD
505 Image sensor 509 System control unit 513 Image composition circuit 514 Parallax map generation circuit 518 Operation unit

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の基準値と算出された前記視差量の最大値との比率から前記視差補正率を算出することを特徴とする請求項1に記載の画像処理装置The parallax correction means to claim 1, characterized in that to calculate the parallax correction factor from the ratio of the maximum value of the amount of parallax is calculated as the first reference value for the maximum value of the amount of parallax The image processing apparatus described. 前記視差補正手段は、前記視差量の最小値に対する前記第2の基準値と算出された前記視差量の最小値との比率から前記視差補正率を算出することを特徴とする請求項1に記載の画像処理装置The parallax correction means to claim 1, characterized in that to calculate the parallax correction factor from the ratio of the minimum value of the parallax amount computed with the second reference value for the minimum value of the parallax amount The image processing apparatus described. 前記第1および第2の基準値の入力操作または選択操作に用いる操作手段を備え、
前記視差補正手段は、前記操作手段から取得した前記第1および第2の基準値を設定して視差補正を行うことを特徴とする請求項1からのいずれか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つを選択する操作に用いる操作手段を備え、
前記視差補正手段は、前記操作手段により選択された画像の視差量を取得し、該視差量を前記第1および第2の基準値として設定して視差補正を行うことを特徴とする請求項1からのいずれか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からのいずれか1項に記載の画像処理装置Any of claims 1 to 5, characterized in that it comprises a control means for controlling to record the parallax correction means by the corrected parallax amount of data, and the image data generated by the image generation processing in recording medium The image processing apparatus according to claim 1 . 前記視差を有する複数の画像データは、複数のマイクロレンズと、各マイクロレンズに対応する複数の光電変換部を有する撮像素子によって出力されることを特徴とする請求項1から6のいずれか1項に記載の画像処理装置 The plurality of image data having the parallax is output by an imaging device having a plurality of microlenses and a plurality of photoelectric conversion units corresponding to the respective microlenses. An image processing apparatus according to 1 . 被写体を撮像し、前記視差を有する複数の画像データを出力する撮像素子と、An image sensor that images a subject and outputs a plurality of image data having the parallax;
請求項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 .
JP2012116875A 2012-05-22 2012-05-22 Image processing apparatus, control method therefor, and imaging apparatus Active JP6004741B2 (en)

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)

* Cited by examiner, † Cited by third party
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)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5505881B2 (en) * 2010-02-02 2014-05-28 学校法人早稲田大学 Stereoscopic image production apparatus and program
US8520059B2 (en) * 2010-03-24 2013-08-27 Fujifilm Corporation Stereoscopic image taking apparatus
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

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