JP2019114912A - Image processing device and image processing method, and imaging apparatus - Google Patents
Image processing device and image processing method, and imaging apparatus Download PDFInfo
- Publication number
- JP2019114912A JP2019114912A JP2017246404A JP2017246404A JP2019114912A JP 2019114912 A JP2019114912 A JP 2019114912A JP 2017246404 A JP2017246404 A JP 2017246404A JP 2017246404 A JP2017246404 A JP 2017246404A JP 2019114912 A JP2019114912 A JP 2019114912A
- Authority
- JP
- Japan
- Prior art keywords
- image
- viewpoint
- projection
- signal
- viewpoint image
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000003384 imaging method Methods 0.000 title claims abstract description 112
- 238000012545 processing Methods 0.000 title claims abstract description 86
- 238000003672 processing method Methods 0.000 title claims description 6
- 210000001747 pupil Anatomy 0.000 claims abstract description 134
- 238000012937 correction Methods 0.000 claims abstract description 107
- 238000006243 chemical reaction Methods 0.000 claims abstract description 68
- 230000003287 optical effect Effects 0.000 claims abstract description 53
- 238000000034 method Methods 0.000 claims description 41
- 238000011156 evaluation Methods 0.000 claims description 32
- 230000008569 process Effects 0.000 claims description 30
- 230000002950 deficient Effects 0.000 claims description 11
- 230000001186 cumulative effect Effects 0.000 claims description 2
- 230000004907 flux Effects 0.000 abstract description 9
- 238000003705 background correction Methods 0.000 description 61
- 230000007547 defect Effects 0.000 description 40
- 230000006870 function Effects 0.000 description 40
- 238000001514 detection method Methods 0.000 description 38
- 238000009826 distribution Methods 0.000 description 22
- 230000014509 gene expression Effects 0.000 description 11
- 229920006395 saturated elastomer Polymers 0.000 description 10
- 238000010586 diagram Methods 0.000 description 9
- 230000035945 sensitivity Effects 0.000 description 8
- 230000007423 decrease Effects 0.000 description 6
- 230000008859 change Effects 0.000 description 5
- 230000002093 peripheral effect Effects 0.000 description 5
- 230000003595 spectral effect Effects 0.000 description 4
- 239000002131 composite material Substances 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 238000005286 illumination Methods 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000010606 normalization Methods 0.000 description 3
- 238000007781 pre-processing Methods 0.000 description 3
- 230000004043 responsiveness Effects 0.000 description 3
- 238000003860 storage Methods 0.000 description 3
- 239000003086 colorant Substances 0.000 description 2
- 238000006073 displacement reaction Methods 0.000 description 2
- 230000005484 gravity Effects 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 239000004065 semiconductor Substances 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 238000004891 communication Methods 0.000 description 1
- 230000000295 complement effect Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 238000012790 confirmation Methods 0.000 description 1
- 238000005520 cutting process Methods 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 239000011521 glass Substances 0.000 description 1
- 239000004615 ingredient Substances 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 229910044991 metal oxide Inorganic materials 0.000 description 1
- 150000004706 metal oxides Chemical class 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 208000024891 symptom Diseases 0.000 description 1
- 238000002834 transmittance Methods 0.000 description 1
- 229910052724 xenon Inorganic materials 0.000 description 1
- FHNFHKCVQCLJFQ-UHFFFAOYSA-N xenon atom Chemical compound [Xe] FHNFHKCVQCLJFQ-UHFFFAOYSA-N 0.000 description 1
Landscapes
- Transforming Light Signals Into Electric Signals (AREA)
- Studio Devices (AREA)
- Focusing (AREA)
- Automatic Focus Adjustment (AREA)
Abstract
Description
本発明は、画像処理装置および画像処理方法、並びに撮像装置に関する。 The present invention relates to an image processing apparatus, an image processing method, and an imaging apparatus.
撮像装置の焦点検出方法の1つとして、撮像素子で得られる信号を用いて位相差方式の焦点検出を行う撮像面位相差方式が知られている。特許文献1には、1つの画素に対して、1つのマイクロレンズと複数に分割された光電変換部が形成されている2次元撮像素子を用いる撮像装置が開示されている。複数に分割された光電変換部は、1つのマイクロレンズを介して撮影レンズの射出瞳の異なる領域を通過した光束を受光するように構成されているため、いわゆる瞳分割を実現することができる。瞳分割により得られる複数の視点信号間の視差から像ずれ量を算出することができるため、得られた象ずれ量をデフォーカス量に換算することで、位相差方式の焦点検出を行うことができる。また、特許文献2には、複数に分割された光電変換部で受光した複数の視点信号を加算することで、撮像信号を生成することが開示されている。 As one of focus detection methods of an imaging apparatus, an imaging surface phase difference method is known in which phase difference focus detection is performed using a signal obtained by an imaging device. Patent Document 1 discloses an imaging device using a two-dimensional imaging element in which one microlens and a photoelectric conversion unit divided into a plurality of pixels are formed for one pixel. The photoelectric conversion unit divided into a plurality of parts is configured to receive light fluxes that have passed through different regions of the exit pupil of the photographing lens via one microlens, and so-called pupil division can be realized. Since the image shift amount can be calculated from the parallax between a plurality of viewpoint signals obtained by pupil division, focus detection of the phase difference method can be performed by converting the obtained image shift amount into the defocus amount. it can. Further, Patent Document 2 discloses that an imaging signal is generated by adding a plurality of viewpoint signals received by a plurality of divided photoelectric conversion units.
なお、複数に分割された光電変換部では、上述したように撮影レンズの射出瞳の異なる領域を通過した光束を受光するため、光強度の空間分布および角度分布を取得することができる。従って、複数に分割された光電変換部を用いて撮影された複数の視点信号は、光強度の空間分布および角度分布の情報を含むLF(Light Field)データと等価である。 Note that, as described above, the photoelectric conversion unit divided into a plurality of pieces receives the light flux that has passed through different regions of the exit pupil of the photographing lens, so that it is possible to acquire spatial distribution and angular distribution of light intensity. Therefore, a plurality of viewpoint signals captured using a plurality of divided photoelectric conversion units are equivalent to light field (LF) data including information on spatial distribution of light intensity and angular distribution.
しかしながら、上述の特許文献に開示された撮像素子で取得されたLFデータを用いる場合、撮影レンズの射出瞳と撮像素子の入射瞳とのずれに起因して、光電変換部の間に光量分布の偏りが生じる場合がある。このため、視点画像に光量の変動(シェーディング)が生じて画質品位が低下し、位相差方式の焦点検出精度が低下する場合がある。上述した特許文献では、視点画像に生じる光量の変動は考慮されておらず、LFデータを用いる場合に、生成される視点画像の光量の変動を低減する技術が求められている。 However, in the case of using LF data acquired by the imaging device disclosed in the above-mentioned patent document, due to the deviation between the exit pupil of the imaging lens and the entrance pupil of the imaging device, A bias may occur. For this reason, fluctuation of the light quantity (shading) may occur in the viewpoint image to deteriorate the image quality and the focus detection accuracy of the phase difference method may be deteriorated. In the patent document mentioned above, the fluctuation of the light quantity which arises in a viewpoint picture is not taken into consideration, and when using LF data, the art which reduces the fluctuation of the light quantity of the generated viewpoint picture is called for.
本発明は、上記の課題に鑑みてなされたものであり、LFデータを用いる場合に、生成される視点画像の光量の変動を低減することが可能な画像処理装置および画像処理方法、並びに撮像装置を提供することを目的とする。 The present invention has been made in view of the above problems, and when using LF data, an image processing apparatus, an image processing method, and an imaging apparatus capable of reducing the fluctuation of the light quantity of a viewpoint image to be generated. Intended to provide.
上述の目的は、結像光学系の瞳領域のうち、異なる部分領域を通過する光束を受光する複数の光電変換部の、一部の光電変換部で得られる信号から生成される視点画像と、全部の光電変換部で得られる信号から生成される撮像画像とを取得する画像取得手段と、視点画像の輝度補正量を、視点画像および撮像画像を用いて取得する補正量取得手段と、輝度補正量に基づいて視点画像の輝度を補正する補正手段と、を有する画像処理装置であって、補正量取得手段は、撮像画像および視点画像それぞれの射影信号を生成する射影手段と、視点画像の射影信号の有効性を判定する判定手段と、視点画像の射影信号のうち、判定手段に有効と判定された射影信号と、撮像画像の射影信号とを用いて輝度補正量を生成する生成手段と、を有することを特徴とする画像処理装置によって達成される。 The above object is to provide a viewpoint image generated from signals obtained by a part of photoelectric conversion units of a plurality of photoelectric conversion units that receive light beams passing through different partial regions of a pupil region of an imaging optical system, Image acquisition means for acquiring a captured image generated from signals obtained by all the photoelectric conversion units, correction amount acquisition means for acquiring a luminance correction amount of a viewpoint image using a viewpoint image and a captured image, luminance correction An image processing apparatus comprising: correction means for correcting the luminance of a viewpoint image based on an amount, wherein the correction amount acquisition means comprises: projection means for generating a projection signal of each of the captured image and the viewpoint image; A determination unit that determines the validity of a signal; a generation unit that generates a luminance correction amount using a projection signal that is determined to be effective as the determination unit among projection signals of a viewpoint image and a projection signal of a captured image; To have It is achieved by an image processing apparatus according to symptoms.
本発明によれば、LFデータを用いる場合に、生成される視点画像の光量の変動を低減することが可能な画像処理装置および画像処理方法、並びに撮像装置を提供できる。 According to the present invention, it is possible to provide an image processing device, an image processing method, and an imaging device capable of reducing the fluctuation of the light amount of a viewpoint image to be generated when using LF data.
以下、本発明の例示的な実施形態を、図面に基づいて詳細に説明する。以下の実施形態では、本発明を画像処理装置の一例としてのデジタルカメラに適用した場合を例に説明するが、本発明はLFデータを処理可能な任意の機器に適用可能である。任意の機器には、例えばパーソナルコンピュータ、タブレット、ゲーム機、眼鏡型や時計型等のウェアラブル端末、車載用システム、監視カメラ用システム、医療機器が含まれてよい。 Hereinafter, exemplary embodiments of the present invention will be described in detail based on the drawings. In the following embodiments, the present invention is applied to a digital camera as an example of an image processing apparatus, but the present invention can be applied to any apparatus capable of processing LF data. The optional devices may include, for example, personal computers, tablets, game machines, wearable terminals such as glasses and watches, in-vehicle systems, surveillance camera systems, and medical devices.
(第1の実施形態)
第1の実施形態に係る画像処理装置の一例としてのデジタルカメラ100の機能構成例を、図1を参照しながら説明する。
First Embodiment
An exemplary functional configuration of a digital camera 100 as an example of an image processing apparatus according to the first embodiment will be described with reference to FIG.
図1は本実施形態に係る撮像装置の機能構成例を示すブロック図である。撮影レンズ(結像光学系)の先端に配置された第1レンズ群101は、レンズ鏡筒にて光軸方向に進退可能に保持される。絞り兼用シャッタ102は、その開口径を調節することで撮影時の光量調節を行う他、静止画撮影時には露光秒時調節用シャッタとしての機能をもつ。第2レンズ群103は、絞り兼用シャッタ102と一体となって光軸方向に進退し、第1レンズ群101の進退動作との連動により、変倍作用(ズーム機能)を有する。第3レンズ群105は、光軸方向の進退により焦点調節を行うフォーカスレンズである。光学的ローパスフィルタ106は、撮像画像の偽色やモアレを軽減するための光学素子である。撮像素子107は、例えば2次元CMOS(相補型金属酸化膜半導体)フォトセンサーと周辺回路とを含み、結像光学系の結像面に配置される。撮像素子107の詳細は後述する。 FIG. 1 is a block diagram showing an example of a functional configuration of an imaging device according to the present embodiment. The first lens group 101 disposed at the tip of the imaging lens (imaging optical system) is held by the lens barrel so as to be movable back and forth in the optical axis direction. The diaphragm / shutter 102 adjusts the light amount at the time of shooting by adjusting the aperture diameter, and also has a function as an exposure time adjustment shutter at the time of still image shooting. The second lens group 103 moves forward and backward in the optical axis direction integrally with the aperture / shutter 102 and has a variable power operation (zoom function) by interlocking with the forward and backward movement of the first lens group 101. The third lens group 105 is a focusing lens that performs focusing by moving back and forth in the optical axis direction. The optical low pass filter 106 is an optical element for reducing false color and moiré of a captured image. The imaging element 107 includes, for example, a two-dimensional CMOS (complementary metal oxide semiconductor) photosensor and a peripheral circuit, and is disposed on the imaging surface of the imaging optical system. Details of the imaging element 107 will be described later.
ズームアクチュエータ111は、不図示のカム筒を回動することにより、第1レンズ群101および第2レンズ群103を光軸方向に移動させて変倍動作を行う。絞りシャッタアクチュエータ112は、絞り兼用シャッタ102の開口径を制御して撮影光量を調節すると共に、静止画撮影時の露光時間制御を行う。フォーカスアクチュエータ114は、第3レンズ群105を光軸方向に移動させて焦点調節動作を行う。 The zoom actuator 111 rotates the cam barrel (not shown) to move the first lens group 101 and the second lens group 103 in the optical axis direction to perform a zooming operation. The aperture shutter actuator 112 controls the aperture diameter of the aperture / shutter 102 to adjust the imaging light amount, and performs exposure time control at the time of still image imaging. The focus actuator 114 moves the third lens group 105 in the optical axis direction to perform a focusing operation.
被写体照明用の電子フラッシュ115は、キセノン管を用いた閃光照明装置、又は連続発光するLED(発光ダイオード)を備えた照明装置を含み、撮影時に使用される。AF(オートフォーカス)補助光源116は、所定の開口パターンを有したマスクの像を、投光レンズを介して被写界に投影する。これにより、低輝度の被写体または低コントラストの被写体に対する焦点検出能力が向上する。 The electronic flash 115 for object illumination includes a flash illumination device using a xenon tube or an illumination device provided with a continuously emitting LED (Light Emitting Diode), and is used at the time of photographing. An AF (Auto Focus) auxiliary light source 116 projects an image of a mask having a predetermined aperture pattern onto a field via a light projection lens. This improves the focus detection capability for low brightness subjects or low contrast subjects.
制御部121は、例えばCPU(中央演算処理装置)を含み、デジタルカメラ100全体の動作を制御する。制御部121は、演算部、ROM(リード・オンリー・メモリ)、RAM(ランダム・アクセス・メモリ)、A(アナログ)/D(デジタル)コンバーター、D/Aコンバーター、通信インターフェイス回路等を含む。制御部121は、ROMに記憶された所定のプログラムをRAMに展開、実行することにより、デジタルカメラ100の各部を駆動し、AF制御、撮像処理、画像処理、記録処理等の一連の動作を実行する。 The control unit 121 includes, for example, a CPU (central processing unit), and controls the overall operation of the digital camera 100. The control unit 121 includes an operation unit, a ROM (read only memory), a RAM (random access memory), an A (analog) / D (digital) converter, a D / A converter, a communication interface circuit, and the like. The control unit 121 drives each unit of the digital camera 100 by developing and executing a predetermined program stored in the ROM in the RAM, and executes a series of operations such as AF control, imaging processing, image processing, recording processing, etc. Do.
電子フラッシュ制御回路122は制御部121の制御指令に従い、撮影動作に同期して電子フラッシュ115を点灯制御する。補助光源駆動回路123は制御部121の制御指令に従い、焦点検出動作に同期してAF補助光源116を点灯制御する。撮像素子駆動回路124は撮像素子107の撮像動作を制御するとともに、取得した画像信号をA/D変換して制御部121に送信する。画像処理回路125は制御部121の制御指令に従い、撮像素子107により取得された画像信号に対してガンマ変換、カラー補間、JPEG(Joint Photographic Experts Group)圧縮等の処理を行う。 The electronic flash control circuit 122 performs lighting control of the electronic flash 115 in synchronization with the photographing operation according to the control command of the control unit 121. The auxiliary light source drive circuit 123 performs lighting control of the AF auxiliary light source 116 in synchronization with the focus detection operation according to the control command of the control unit 121. The imaging device drive circuit 124 controls the imaging operation of the imaging device 107, A / D converts the acquired image signal, and transmits it to the control unit 121. The image processing circuit 125 performs processing such as gamma conversion, color interpolation, JPEG (Joint Photographic Experts Group) compression, and the like on the image signal acquired by the imaging device 107 in accordance with a control command of the control unit 121.
フォーカス駆動回路126は制御部121の制御指令に従い、焦点検出結果に基づいてフォーカスアクチュエータ114を駆動し、第3レンズ群105を光軸方向に移動させて焦点調節を行う。絞りシャッタ駆動回路128は制御部121の制御指令に従い、絞りシャッタアクチュエータ112を駆動し、絞り兼用シャッタ102の開口径を制御する。ズーム駆動回路129は制御部121の制御指令に従い、撮影者のズーム操作指示に応じてズームアクチュエータ111を駆動する。 The focus drive circuit 126 drives the focus actuator 114 based on the focus detection result according to the control command of the control unit 121, moves the third lens group 105 in the optical axis direction, and performs focus adjustment. The aperture shutter drive circuit 128 drives the aperture shutter actuator 112 in accordance with a control command from the control unit 121 to control the aperture diameter of the aperture / shutter 102. The zoom drive circuit 129 drives the zoom actuator 111 according to the zoom operation instruction of the photographer according to the control instruction of the control unit 121.
表示部131は、例えばLCD(液晶表示装置)等の表示デバイスを含み、カメラの撮影モードに関する情報、撮影前のプレビュー画像と撮影後の確認用画像、焦点検出時の合焦状態表示画像等を表示する。操作部132は、例えば電源スイッチ、レリーズ(撮影トリガ)スイッチ、ズーム操作スイッチ、撮影モード選択スイッチ等の操作スイッチやタッチパネルを含み、操作指示信号を制御部121に出力する。記録媒体133は、半導体メモリカードなど、デジタルカメラ100に着脱可能な記録媒体である。撮影で得られた画像データ等を記録媒体133に記録することができる。 The display unit 131 includes, for example, a display device such as an LCD (liquid crystal display device), and information on the shooting mode of the camera, the preview image before shooting and the confirmation image after shooting, the focus state display image at the time of focus detection, etc. indicate. The operation unit 132 includes, for example, operation switches such as a power switch, a release (shooting trigger) switch, a zoom operation switch, a shooting mode selection switch, and a touch panel, and outputs an operation instruction signal to the control unit 121. The recording medium 133 is a recording medium removable from the digital camera 100, such as a semiconductor memory card. Image data and the like obtained by photographing can be recorded on the recording medium 133.
(撮像素子の構成)
本実施形態に係る撮像素子107の画素と副画素の配列の概略図を図2に示す。図2の左右方向をx方向(水平方向)、上下方向をy方向(垂直方向)、x方向およびy方向に直交する方向(紙面に垂直な方向)をz方向(光軸方向)とする。図2に示す例は、2次元CMOSセンサー(撮像素子)の画素(単位画素)配列を4列×4行の範囲で、副画素配列を8列×4行の範囲で示している。
(Configuration of imaging device)
A schematic view of the arrangement of pixels and sub-pixels of the image sensor 107 according to the present embodiment is shown in FIG. The horizontal direction in FIG. 2 is taken as the x direction (horizontal direction), the vertical direction as the y direction (vertical direction), and the direction orthogonal to the x direction and the y direction (direction perpendicular to the paper) as the z direction (optical axis direction). In the example shown in FIG. 2, the pixel (unit pixel) array of the two-dimensional CMOS sensor (image pickup device) is shown in a range of 4 columns × 4 rows, and the sub-pixel array is shown in a range of 8 columns × 4 rows.
2列×2行の画素群200は、例えば左上の位置に第1色のR(赤)の分光感度を有する画素200Rが左上に、第2色のG(緑)の分光感度を有する画素200Gが右上と左下に、第3色のB(青)の分光感度を有する画素200Bが右下に配置される。さらに、各画素(単位画素)は、x方向に2分割(Nx分割)、y方向に1分割(Ny分割)された分割数2(分割数NLF=Nx×Ny)の第1副画素201と第2副画素202(第1副画素から第NLF副画素)の複数の副画素により構成されている。 For example, in the pixel group 200 of 2 columns × 2 rows, a pixel 200R having the spectral sensitivity of R (red) of the first color at the upper left position has a spectral sensitivity of G (green) of the second color at the upper left. In the upper right and lower left, the pixel 200B having the spectral sensitivity of the third color B (blue) is arranged in the lower right. Furthermore, each pixel (unit pixel) is divided into two (Nx division) in the x direction and one division (Ny division) in the y direction into the first subpixel 201 of the division number 2 (division number N LF = Nx × Ny). And a plurality of sub-pixels of the second sub-pixel 202 (the first sub-pixel to the N.sub.LF sub-pixel).
図2に示す例では、撮像素子107の各画素を水平方向に並んだ2つの副画素に分割することにより、1回の撮影で得られる画像信号(LFデータ)から、分割数NLFに等しい数の視点画像と、全ての視点画像を合成した撮像画像とを生成することができる。なお、画素は2方向に分割してもよいし、方向ごとの分割数にも制限はない。したがって、視点画像は複数の副画素のうち、一部の副画素の信号から生成される画像、撮像画像は全部の副画素の信号から生成される画像ということができる。本実施形態では一例として撮像素子107の水平および垂直方向の画素周期Pを6μm、水平画素数NH=6000、垂直画素数NV=4000とする。したがって、総画素数N=NH×NV=2400万である。また、副画素の水平方向周期PSを3μmとすると、総副画素数NS=NH×(P/PS)×NV=4800万である。 In the example shown in FIG. 2, by dividing each pixel of the image sensor 107 into two sub-pixels aligned in the horizontal direction, an image signal (LF data) obtained by one shooting is equal to the division number N LF A number of viewpoint images and a captured image obtained by combining all viewpoint images can be generated. Note that pixels may be divided in two directions, and the number of divisions in each direction is not limited. Therefore, it can be said that the viewpoint image is an image generated from the signals of some of the plurality of sub-pixels, and the captured image is an image generated from the signals of all the sub-pixels. In this embodiment, as an example, the pixel period P in the horizontal and vertical directions of the image sensor 107 is 6 μm, the number of horizontal pixels N H = 6000, and the number of vertical pixels N V = 4000. Therefore, the total number of pixels N = N H × N V = 24 million. Further, assuming that the horizontal direction period P S of the sub-pixels is 3 μm, the total number of sub-pixels N S = N H × (P / P S ) × N V = 48 million.
図2に示した撮像素子107の1つの画素200Gを、撮像素子107の受光面側(+z側)から見た場合の平面図を図3(A)に示す。図3(A)の紙面に垂直な方向にz軸を設定し、手前側をz軸の正方向と定義する。また、z軸に直交する上下方向にy軸を設定して上方をy軸の正方向とし、z軸およびy軸に直交する左右方向にx軸を設定して右方をx軸の正方向と定義する。図3(A)にてa−a切断線に沿って、−y側から見た場合の断面図を図3(B)に示す。 The top view at the time of seeing one pixel 200G of the image pick-up element 107 shown in FIG. 2 from the light-receiving surface side (+ z side) of the image pick-up element 107 is shown to FIG. 3 (A). The z-axis is set in a direction perpendicular to the sheet of FIG. 3A, and the near side is defined as the positive direction of the z-axis. In addition, the y-axis is set in the vertical direction orthogonal to the z-axis, with the upper side being the positive direction of the y-axis, and the x-axis set in the horizontal direction orthogonal to the z-axis and y-axis Define as FIG. 3 (B) shows a cross-sectional view as viewed from the −y side along the a-a cutting line in FIG. 3 (A).
図3(A)および、図3(B)に示すように、画素200Gには、各画素の受光面側(+z方向)にマイクロレンズ305が形成され、このマイクロレンズ305によって入射光が集光される。さらに、x(水平)方向に2分割、y(垂直)方向に1分割された分割数2の第1光電変換部301と第2光電変換部302の複数の光電変換部が形成される。第1光電変換部301と第2光電変換部302が、それぞれ図2の第1副画素201と第2副画素202に対応する。より一般的に記載すれば、各画素の光電変換部が、x方向にNx分割、y方向にNy分割され、光電変換部の分割数NLF=Nx×Nyであるとき、第1〜第NLF光電変換部が、第1〜第NLF副画素に対応する。 As shown in FIGS. 3A and 3B, in the pixel 200G, a micro lens 305 is formed on the light receiving surface side (+ z direction) of each pixel, and the incident light is collected by the micro lens 305. Be done. Furthermore, a plurality of photoelectric conversion units, ie, a first photoelectric conversion unit 301 and a second photoelectric conversion unit 302, each of which is divided into two in the x (horizontal) direction and divided into one in the y (vertical) direction, are formed. The first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 correspond to the first subpixel 201 and the second subpixel 202 in FIG. 2, respectively. More generally, the photoelectric conversion units of each pixel are divided into Nx in the x direction and Ny in the y direction, and the number of divisions of the photoelectric conversion units N LF = Nx × Ny. The LF photoelectric conversion unit corresponds to the first to Nth LF sub-pixels.
第1光電変換部301と第2光電変換部302は、2つの独立したpn接合フォトダイオードであり、p型ウェル層300と2つに分割されたn型層301とn型層302から構成される。必要に応じて、イントリンシック層を挟み、pin構造フォトダイオードとして形成してもよい。各画素には、マイクロレンズ305と、第1光電変換部301および第2光電変換部302との間に、カラーフィルター306が形成される。必要に応じて、画素毎や光電変換部毎などで、カラーフィルター306の分光透過率を変えても良いし、カラーフィルターを省略しても構わない。 The first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 are two independent pn junction photodiodes, and are composed of a p-type well layer 300 and an n-type layer 301 and an n-type layer 302 divided into two. Ru. If necessary, the intrinsic layer may be sandwiched and formed as a pin structure photodiode. A color filter 306 is formed between the microlens 305 and the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 in each pixel. If necessary, the spectral transmittance of the color filter 306 may be changed for each pixel, each photoelectric conversion unit, or the like, or the color filter may be omitted.
画素200Gに入射した光はマイクロレンズ305が集光し、さらにカラーフィルター306で分光された後に、第1光電変換部301と第2光電変換部302がそれぞれ受光する。第1光電変換部301と第2光電変換部302では、受光量に応じて電子とホール(正孔)が対生成され、空乏層で分離された後、電子が蓄積される。一方、ホールは定電圧源(不図示)に接続されたp型ウェル層を通じて撮像素子107の外部へ排出される。第1光電変換部301と第2光電変換部302に蓄積された電子は、転送ゲートを介して、静電容量部(FD)に転送されて電圧信号に変換される。 The light incident on the pixel 200G is collected by the micro lens 305, and after being dispersed by the color filter 306, the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 respectively receive light. In the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302, electrons and holes (hole) are generated in a pair according to the amount of light received, and after being separated by the depletion layer, the electrons are accumulated. On the other hand, holes are discharged to the outside of the imaging element 107 through a p-type well layer connected to a constant voltage source (not shown). The electrons stored in the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 are transferred to the electrostatic capacitance unit (FD) through the transfer gate and converted into a voltage signal.
図4は、画素構造と瞳分割との対応関係を概略的に示している。図4には、図3(A)に示した画素構造のa−a線での切断面を、+y方向から見た場合の断面図と、結像光学系の射出瞳面を、−z方向から見た図を示す。図4では、射出瞳面の座標軸と対応を取るために、断面図にてx軸とy軸を図3に示す状態とは反転させて示している。 FIG. 4 schematically shows the correspondence between the pixel structure and the pupil division. FIG. 4 is a cross-sectional view of the section taken along line aa of the pixel structure shown in FIG. 3A as viewed from the + y direction, and the exit pupil plane of the imaging optical system in the −z direction. Shows a view from a perspective. In FIG. 4, in order to correspond to the coordinate axes of the exit pupil plane, the x-axis and the y-axis are shown inverted in the cross-sectional view from the state shown in FIG.
撮像素子107は、撮影レンズ(結像光学系)の結像面近傍に配置されており、被写体からの光束は、結像光学系の射出瞳400を通過して、それぞれの画素に入射する。なお、撮像素子107が配置された面を撮像面とする。 The imaging element 107 is disposed in the vicinity of the imaging surface of the imaging lens (imaging optical system), and the light flux from the subject passes through the exit pupil 400 of the imaging optical system and enters each pixel. Note that the surface on which the imaging element 107 is disposed is taken as an imaging surface.
第1瞳部分領域501と第2瞳部分領域502は、第1光電変換部301と第2光電変換部302の受光面と、マイクロレンズによって、概ね、光学的に共役である。つまり、第1瞳部分領域501と第2瞳部分領域502は、第1副画素201と第2副画素202でそれぞれ受光可能な瞳領域である。このように、瞳領域をNx×Ny分割することで得られる第1〜第NLF瞳部分領域は、第1〜第NLF副画素の対応する1つで受光可能な瞳領域となる。また、第1副画素201が対応する第1瞳部分領域501は瞳面上で+X側に重心が偏心しており、第2副画素202が対応する第2瞳部分領域502は瞳面上で−X側に重心が偏心している。 The first pupil partial region 501 and the second pupil partial region 502 are approximately optically conjugate by the light receiving surfaces of the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 and the microlens. That is, the first pupil partial region 501 and the second pupil partial region 502 are pupil regions which can be received by the first subpixel 201 and the second subpixel 202, respectively. As described above, the first to N-th N LF pupil partial regions obtained by dividing the pupil region by N ×× Ny become pupil regions that can receive light at corresponding ones of the first to N-th N L subpixels. The first pupil partial region 501 to which the first subpixel 201 corresponds is decentered on the pupil plane to the + X side, and the second pupil partial region 502 to which the second subpixel 202 corresponds is-on the pupil surface The center of gravity is eccentric to the X side.
また、瞳領域500は、分割された全ての光電変換部(ここでは第1および第2光電変換部301および302)の受光面を合わせた受光面と、マイクロレンズによって、概ね、光学的に共役である。つまり、分割された第1〜第NLF光電変換部は、全体で瞳領域500を受光可能である。したがって、第1〜第NLF光電変換部で得られる信号を合成することにより、画素200全体が受光可能な瞳領域500に対応した画素信号を得ることができる。この合成信号は、画素200の光電変換部が分割されていない場合に得られる画素信号に相当する。 In addition, the pupil region 500 is approximately optically conjugated by the micro-lens and the light-receiving surface in which the light-receiving surfaces of all the divided photoelectric conversion units (here, the first and second photoelectric conversion units 301 and 302) are combined. It is. That is, the divided first to N th LF photoelectric conversion units can receive the pupil region 500 as a whole. Therefore, by combining the signals obtained by the first to N-th N LF photoelectric conversion units, it is possible to obtain a pixel signal corresponding to the pupil region 500 in which the entire pixel 200 can receive light. The composite signal corresponds to a pixel signal obtained when the photoelectric conversion unit of the pixel 200 is not divided.
図5は、各画素に形成されたマイクロレンズに光が入射した場合の光強度分布を模式的に示す図である。図5(A)は、マイクロレンズの光軸に平行な断面における光強度分布を示している。また、図5(B)はマイクロレンズの焦点位置において、マイクロレンズの光軸に垂直な断面における光強度分布を示している。図5において、Hはマイクロレンズ305の凸側の面を、fはマイクロレンズの焦点距離を示している。また、nFΔは後述するリフォーカスによる焦点位置の可動範囲を、φは入射する光束の最大角度を示している。入射光は、マイクロレンズ305により、焦点位置に集光される。しかし、光の波動性による回折の影響により、集光スポットの直径は回折限界Δより小さくすることはできず、有限の大きさとなる。光電変換部の受光面サイズは約1〜2μm程度であり、これに対してマイクロレンズの集光スポットは約1μm程度である。そのため、光電変換部の受光面とマイクロレンズを介して共役の関係にある、図4に示した第1瞳部分領域501と第2瞳部分領域502は、回折ボケのため、明瞭に瞳分割されず、光の入射角に依存した受光率分布(瞳強度分布)となる。 FIG. 5 is a view schematically showing a light intensity distribution when light is incident on a microlens formed in each pixel. FIG. 5A shows the light intensity distribution in a cross section parallel to the optical axis of the microlens. Further, FIG. 5B shows the light intensity distribution in a cross section perpendicular to the optical axis of the microlens at the focal position of the microlens. In FIG. 5, H indicates the surface on the convex side of the micro lens 305, and f indicates the focal length of the micro lens. Further, nFΔ represents the movable range of the focal position by refocusing, which will be described later, and φ represents the maximum angle of the incident light flux. Incident light is collected by the micro lens 305 at a focal position. However, due to the influence of diffraction due to the wave nature of light, the diameter of the focused spot can not be made smaller than the diffraction limit Δ, and has a finite size. The light receiving surface size of the photoelectric conversion unit is about 1 to 2 μm, whereas the focusing spot of the microlens is about 1 μm. Therefore, the first pupil partial region 501 and the second pupil partial region 502 shown in FIG. 4 that are in a conjugate relationship with the light receiving surface of the photoelectric conversion unit via the micro lens are clearly pupil-divided due to diffraction blur. The light receiving rate distribution (pupil intensity distribution) depends on the incident angle of light.
図6に、光の入射角に依存した受光率分布(瞳強度分布)例を示す。横軸は瞳座標を表し、縦軸は受光率を表す。図6に実線で示すグラフ線L1は、図4の第1瞳部分領域501のX軸に沿った瞳強度分布を表す。グラフ線L1で示す受光率は、左端から急峻に上昇してピークに到達した後で徐々に低下してから変化率が緩やかになって右端へと至る。また、図6に破線で示すグラフ線L2は、第2瞳部分領域502のX軸に沿った瞳強度分布を表す。グラフ線L2で示す受光率は、グラフ線L1とは反対に、右端から急峻に上昇してピークに到達した後で徐々に低下してから変化率が緩やかになって左端へと至る。図示のように、緩やかに瞳分割されることがわかる。 FIG. 6 shows an example of a light receiving rate distribution (pupil intensity distribution) depending on the incident angle of light. The horizontal axis represents pupil coordinates, and the vertical axis represents light reception rate. A graph line L1 indicated by a solid line in FIG. 6 represents a pupil intensity distribution along the X axis of the first pupil partial region 501 of FIG. The light receiving rate indicated by the graph line L1 sharply rises from the left end and reaches a peak, then gradually decreases and then the change rate becomes gentle and reaches the right end. A graph line L2 indicated by a broken line in FIG. 6 represents a pupil intensity distribution along the X axis of the second pupil partial region 502. The light receiving rate indicated by the graph line L2 sharply rises from the right end and reaches a peak, and then gradually decreases, and then gradually decreases and reaches the left end, contrary to the graph line L1. As shown, it can be seen that the pupil division is performed gently.
次に、図7を参照して、撮像素子107と瞳分割との対応関係について説明する。第1光電変換部301と第2光電変換部302(第1副画素201と第2副画素202)は、それぞれ、結像光学系の第1瞳部分領域501と第2瞳部分領域502を通過した光束を受光する。第1副画素群で得られた画像信号と、第2副画素群で得られた画像信号とはそれぞれ異なる視点を有する画像である。LFデータは、各副画素群で得られた画像を生成可能なデータであり、光強度の空間分布および角度分布の情報を含む。なお、LFデータは各画素群で得られた画像の集合であってもよいし、各画素群で得られた画像を演算によって求めることが可能なデータであってもよい。例えば、第1副画素群で得られる画像をA像、第2副画素群で得られる画像をB像とすると、LFデータはA像およびB像のデータであってもよいし、A像とB像との合成画像(A+B像と記載する)のデータと、A像またはB像のデータとであってもよい。 Next, with reference to FIG. 7, the correspondence between the image sensor 107 and the pupil division will be described. The first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 (the first subpixel 201 and the second subpixel 202) pass through the first pupil partial region 501 and the second pupil partial region 502 of the imaging optical system, respectively. Receive the luminous flux. The image signal obtained by the first sub-pixel group and the image signal obtained by the second sub-pixel group are images having different viewpoints. The LF data is data that can generate an image obtained by each sub-pixel group, and includes information of spatial distribution of light intensity and angular distribution. The LF data may be a set of images obtained by each pixel group, or may be data capable of calculating an image obtained by each pixel group by calculation. For example, assuming that an image obtained by the first sub-pixel group is an A image and an image obtained by the second sub-pixel group is an B image, the LF data may be data of the A image and the B image. It may be data of a composite image (denoted as A + B image) with the B image and data of the A image or B image.
つまり、LFデータについて、画素ごとに、全ての副画素(ここでは第1副画素201と第2副画素202)の信号を合成することにより、総画素数Nの解像度を有する撮像画像を生成することができる。 That is, for LF data, a captured image having a resolution of the total number of pixels N is generated by combining the signals of all the sub-pixels (here, the first sub-pixel 201 and the second sub-pixel 202) for each pixel. be able to.
また、LFデータについて、画素ごとに、特定の副画素で得られた信号を抽出することにより、その副画素に対応する瞳部分領域に対応した画像(視点画像)を生成することができる。例えば、各画素について第1副画素201で得られた画像信号を抽出することで、結像光学系の第1瞳部分領域501に対応した、画素数Nの解像度を有する第1視点画像を生成できる。他の副画素についても同様である。 Further, by extracting a signal obtained in a specific sub-pixel for each pixel of the LF data, it is possible to generate an image (viewpoint image) corresponding to a pupil partial region corresponding to the sub-pixel. For example, by extracting the image signal obtained by the first subpixel 201 for each pixel, a first viewpoint image having a resolution of N pixels corresponding to the first pupil partial region 501 of the imaging optical system is generated. it can. The same applies to the other subpixels.
以上のように本実施形態の撮像素子107は、結像光学系の異なる瞳部分領域を通過する光束を受光する複数の副画素が設けられた画素が複数配列された構造を有し、LFデータを取得することができる。なお、上述した説明では、瞳領域が水平方向に2分割される例を示したが、水平方向の代わりに、あるいは水平方向に加えて、垂直方向にも分割されてよい。また、水平および垂直方向の少なくとも一方について分割数を3以上としてもよい。 As described above, the imaging element 107 according to the present embodiment has a structure in which a plurality of pixels provided with a plurality of sub-pixels for receiving light beams passing through different pupil partial regions of the imaging optical system are arranged. You can get In the above description, the pupil area is divided into two in the horizontal direction, but may be divided in the vertical direction instead of or in addition to the horizontal direction. In addition, the number of divisions may be three or more in at least one of the horizontal direction and the vertical direction.
(デフォーカス量と像ずれ量の関係)
さらに、図8を参照して、撮像素子107により取得されるLFデータに基づいて生成可能な第1視点画像と第2視点画像(第1〜第NLF視点画像)のデフォーカス量と像ずれ量との関係について説明する。
(Relationship between defocus amount and image shift amount)
Furthermore, referring to FIG. 8, the defocus amount and image shift of the first viewpoint image and the second viewpoint image (first to Nth LF viewpoint images) that can be generated based on the LF data acquired by the imaging element 107. The relationship with the quantity will be described.
図8は、第1視点画像と第2視点画像のデフォーカス量と、第1視点画像と第2視点画像との間の像ずれ量の関係を概略的に示している。撮像面600には撮像素子(不図示)が配置され、結像光学系の射出瞳は、図4、図7の場合と同様に、第1瞳部分領域501と第2瞳部分領域502に2×1分割される。 FIG. 8 schematically shows the relationship between the defocus amount of the first viewpoint image and the second viewpoint image, and the image shift amount between the first viewpoint image and the second viewpoint image. An imaging element (not shown) is disposed on the imaging surface 600, and the exit pupil of the imaging optical system is set in the first pupil partial region 501 and the second pupil partial region 502 in the same manner as in FIGS. × 1 divided.
デフォーカス量dは、その大きさ|d|が被写体像の結像位置から撮像面600までの距離を表す。被写体像の結像位置が撮像面600よりも被写体側にある前ピン状態では、負符号(d<0)とし、これとは反対の後ピン状態では正符号(d>0)として向きを定義する。被写体像の結像位置が撮像面(すなわち合焦位置)にある合焦状態では、d=0である。例えば、被写体801の位置は、合焦状態(d=0)に対応する位置を示しており、被写体802の位置は前ピン状態(d<0)に対応する位置を示している。以下では、前ピン状態(d<0)と後ピン状態(d>0)とを併せて、デフォーカス状態(|d|>0)という。 The defocus amount d represents the distance from the imaging position of the object image to the imaging surface 600 as the size | d |. A negative sign (d <0) is defined in the front pin state where the imaging position of the subject image is closer to the object than the imaging plane 600, and a positive sign (d> 0) is defined in the opposite rear pin state. Do. In the in-focus state where the imaging position of the subject image is on the imaging plane (that is, the in-focus position), d = 0. For example, the position of the subject 801 indicates the position corresponding to the in-focus state (d = 0), and the position of the subject 802 indicates the position corresponding to the front pin state (d <0). Hereinafter, the front pin state (d <0) and the rear pin state (d> 0) are collectively referred to as a defocus state (| d |> 0).
前ピン状態(d<0)では、被写体802から受光した光束のうち、第1瞳部分領域501(または第2瞳部分領域502)を通過した光束は、いったん集光した後、光束の重心位置G1(またはG2)を中心として幅Γ1(またはΓ2)に広がる。この場合、撮像面600上でボケ像となる。ボケ像は、撮像素子107に配列された各画素部を構成する第1副画素201(または第2副画素202)により受光され、第1視点画像(または第2視点画像)が生成される。よって、第1視点画像(または第2視点画像)は、撮像面600上の重心位置G1(またはG2)にて、幅Γ1(またはΓ2)をもった被写体像(ボケ像)の画像データとしてメモリに記憶される。被写体像の幅Γ1(またはΓ2)は、デフォーカス量dの大きさ|d|が増加するのに伴い、概ね比例して増加する。同様に、第1視点画像と第2視点画像との間の被写体像の像ずれ量を「p」と記すと、その大きさ|p|はデフォーカス量dの大きさ|d|の増加に伴って増加する。例えば、図8に示すように、像ずれ量pは光束の重心位置の差「G1−G2」として定義することができ、その大きさ|p|は、|d|が増加するのに伴い、概ね比例して増加する。なお、後ピン状態(d>0)では、第1視点画像と第2視点画像との間の被写体像の像ずれ方向が前ピン状態とは反対となるが、同様に|p|がデフォーカス量|d|に比例する傾向がある。 In the front pin state (d <0), the light flux that has passed through the first pupil partial area 501 (or the second pupil partial area 502) among the light flux received from the object 802 is once condensed and then the barycentric position of the light flux It spreads in width Γ1 (or Γ2) centering on G1 (or G2). In this case, a blurred image is obtained on the imaging surface 600. The blurred image is received by the first sub-pixel 201 (or the second sub-pixel 202) constituting each pixel unit arranged in the image sensor 107, and a first viewpoint image (or a second viewpoint image) is generated. Therefore, the first viewpoint image (or the second viewpoint image) is stored as image data of an object image (blurred image) having a width Γ1 (or Γ2) at the gravity center position G1 (or G2) on the imaging surface 600 Is stored in The width Γ1 (or Γ2) of the subject image generally increases in proportion to the increase of the magnitude | d | of the defocus amount d. Similarly, when the image shift amount of the subject image between the first viewpoint image and the second viewpoint image is denoted as "p", the size | p | is an increase in the size | d | of the defocus amount d. It increases with it. For example, as shown in FIG. 8, the image shift amount p can be defined as the difference “G1−G2” of the barycentric positions of light beams, and the size | p | thereof increases with | d | Generally increases in proportion. In the back focus state (d> 0), although the image shift direction of the subject image between the first viewpoint image and the second viewpoint image is opposite to that in the front focus state, | p | It tends to be proportional to the quantity | d |.
したがって、本実施形態では、第1視点画像と第2視点画像、または、第1視点画像と第2視点画像を加算した撮像画像のデフォーカス量が増減するのに伴い、第1視点画像と第2視点画像との間の像ずれ量の大きさが増加する。 Therefore, in the present embodiment, as the defocus amount of the captured image obtained by adding the first viewpoint image and the second viewpoint image or the first viewpoint image and the second viewpoint image increases or decreases, the first viewpoint image and the first viewpoint image The magnitude of the image shift amount between the two viewpoint images increases.
(撮像画像に基づく視点画像の補正処理)
以下の実施形態では、撮像画像に基づき、第1視点画像と第2視点画像(第1〜第NLF視点画像)に対するキズ補正やシェーディング補正等の画像処理(補正処理)を行い、出力画像を生成する例について説明する。
(Correction processing of viewpoint image based on captured image)
In the following embodiments, image processing (correction processing) such as flaw correction and shading correction is performed on the first viewpoint image and the second viewpoint image (first to Nth LF viewpoint images) based on the captured image, and the output image is displayed An example of generation will be described.
まず、図9および図10を参照して、取得されたLFデータに基づいて、補正処理を行い、出力画像を生成する一連の流れについて説明する。なお、図9および図10に示す処理は、制御部121がROMに記憶されたプログラムをRAMに展開、実行することにより実行される。また、撮像素子107や画像処理回路125は制御部121の指示に応じて動作する。 First, with reference to FIG. 9 and FIG. 10, a series of flows for performing correction processing and generating an output image based on the acquired LF data will be described. The processing shown in FIGS. 9 and 10 is executed by the control unit 121 loading and executing a program stored in the ROM into the RAM. The image sensor 107 and the image processing circuit 125 operate in accordance with an instruction from the control unit 121.
(撮像画像と視点画像)
まず、図9に示すS1の前処理として、画像取得手段としての制御部121は、撮像素子107により取得されたLFデータから、結像光学系の異なる瞳部分領域を合成した撮像画像と、結像光学系の瞳部分領域に対応する少なくとも1つの視点画像とを生成する。なお、制御部121は、撮像画像と視点画像をLFデータから生成する代わりに、生成済みの撮像画像と視点画像を記憶媒体から読み出すなどして取得してもよい。前処理を便宜上S0とする。以下、前処理S0について説明する。
(Captured image and viewpoint image)
First, as pre-processing of S1 shown in FIG. 9, the control unit 121 as an image acquisition unit combines a captured image obtained by combining different pupil partial regions of the imaging optical system from the LF data acquired by the imaging element 107. At least one viewpoint image corresponding to a pupil partial region of the image optical system is generated. The control unit 121 may acquire the generated captured image and the viewpoint image by reading the storage image from the storage medium instead of generating the captured image and the viewpoint image from the LF data. The preprocessing is referred to as S0 for convenience. The pre-processing S0 will be described below.
制御部121は、LFデータを取得する。LFデータは撮像素子107を用いて取得してもよいし、予め保存されているLFデータを例えば記録媒体から読み出すことによって取得してもよい。 The control unit 121 acquires LF data. The LF data may be acquired using the imaging device 107, or may be acquired by reading out LF data stored in advance from, for example, a recording medium.
そして制御部121は、LFデータを構成する複数の視点画像を合成することにより、撮像画像を生成する。LFデータを構成する各画素信号は、水平方向Nx、垂直方向Nyの総数NLFの副画素信号から構成される。ここで、1つの画素信号を構成する総数NLFの副画素信号のうち、水平方向にiS(1≦iS≦Nx)番目、垂直方向にjS(1≦jS≦Ny)番目の副画素の信号をk番目の副画素信号とする(k=Nx(jS−1)+iS)。ここで、1≦k≦NLFであり、kは、水平方向Nx,垂直方向Nyに分割された総数NLFの光電変換領域(副画素)の通し番号である。撮像画像は、図4における瞳領域500に対応する画像であり、各画素の副画素信号を合成することによって得られる。撮像画像Iを構成する、垂直方向にj番目、水平方向にi番目の画素I(j,i)、1≦j≦NV、1≦i≦NHは、式(1)に従って得ることができる。 Then, the control unit 121 generates a captured image by combining a plurality of viewpoint images constituting the LF data. Each pixel signal constituting the LF data is composed of sub-pixel signals of the total number N LF in the horizontal direction Nx and the vertical direction Ny. Here, of the total number N LF of sub-pixel signals constituting one pixel signal, the i S (1 ≦ i s ≦ N x) th in the horizontal direction and the j s (1 ≦ j s ≦ Ny) in the vertical direction Let the signal of the sub-pixel be the k-th sub-pixel signal (k = Nx (j s −1) + i S ). Here, 1 ≦ k ≦ N LF , and k is a serial number of the photoelectric conversion area (sub-pixel) of the total number N LF divided in the horizontal direction Nx and the vertical direction Ny. The captured image is an image corresponding to the pupil region 500 in FIG. 4, and is obtained by combining sub-pixel signals of respective pixels. The j th vertical pixel and the i th horizontal pixel I (j, i), 1 ≦ j ≦ N V , 1 ≦ i ≦ N H constituting the captured image I can be obtained according to equation (1) it can.
なお、本処理は、LFデータを生成する際に行ってもよい。この場合、撮像画像IのS/Nを良好に保持するため、各副画素信号をアナログ/デジタル変換(A/D変換)する前に、撮像素子107内の静電容量部(FD)において式(1)に従う副画素信号の合成を行ってもよい。撮像素子107内のFDに蓄積された電荷を電圧信号に変換する際に、式(1)に従う各副画素信号の合成を行ってもよいし、A/D変換を行った後に、式(1)に従う各副画素信号の合成を行ってもよい。 Note that this process may be performed when generating LF data. In this case, in order to maintain the S / N of the captured image I favorably, the expression of the equation in the electrostatic capacitance unit (FD) in the image sensor 107 before analog / digital conversion (A / D conversion) of each sub-pixel signal The sub-pixel signals may be combined according to (1). When converting the charge accumulated in the FD in the imaging element 107 into a voltage signal, the sub-pixel signals may be combined according to the equation (1), or after the A / D conversion is performed, the equation (1 The sub-pixel signals may be combined in accordance with.
なお、本実施形態は、Nx=2、Ny=1、NLF=2であるx方向2分割の場合であり、図2に例示した画素配列に対応した入力画像(LFデータ)を用いる。このため、制御部121は、画素ごとに、x方向に2分割された第1副画素201と第2副画素202の信号を全て合成した撮像画像を生成する。この撮像画像は、画素数N(=水平方向の画素数NH×垂直方向の画素数NV)の解像度を有するベイヤー配列のRGB信号である。 The present embodiment is a case of Nx = 2, Ny = 1, N LF = 2 a is the x-direction divided into two, using the input image corresponding to the illustrated pixel array in FIG. 2 (LF data). Therefore, the control unit 121 generates a captured image in which all the signals of the first sub-pixel 201 and the second sub-pixel 202 divided into two in the x-direction are combined for each pixel. This captured image is a Bayer-arranged RGB signal having a resolution of the number of pixels N (= the number of horizontal pixels N H × the number of vertical pixels N V ).
なお、後述する視点画像の補正処理では、撮像画像を補正基準の参照画像として用いるため、撮像画像Iに対してもRGB毎のシェーディング補正処理、欠陥補正処理を行う。 In addition, in the correction process of the viewpoint image to be described later, since the captured image is used as a reference image of correction standard, the shading correction process and the defect correction process for each RGB are also performed on the captured image I.
次に、制御部121は、結像光学系の第k瞳部分領域に対応した、水平方向i番目、垂直方向j番目の第k視点画像Ikを構成する画素Ik(j,i)を、式(2)に従って生成する。 Next, the control unit 121 sets the pixel I k (j, i) that constitutes the i-th in the horizontal direction and the j-th k-th viewpoint image I k in the vertical direction corresponding to the k-th pupil partial region of the imaging optical system. , According to equation (2).
なお、本実施形態では、x方向に光電変換部を2分割(水平方向に瞳領域を2分割)するNx=2、Ny=1、NLF=2の構成の撮像素子107で得られるLFデータから生成可能な2つの視点画像のうち、第1の視点画像(k=1)を生成するものとする。制御部121は、図2に例示した画素配列に対応したLFデータのうち、第1副画素201の信号を抽出し、第1視点画像I1を生成する。第1視点画像I1は、結像光学系の第1瞳部分領域501に対応した視点画像である。第1視点画像I1は、画素数N(=水平方向の画素数NH×垂直方向の画素数NV)の解像度を有するベイヤー配列のRGB信号である。なお、必要に応じて、結像光学系の第2瞳部分領域502に対応した第2視点画像I2を生成してもよい。 In the present embodiment, (2 divides the pupil area in the horizontal direction) photoelectric conversion unit 2 divides the x direction Nx = 2, Ny = 1, N LF = LF data obtained by the image sensor 107 of the second configuration The first viewpoint image (k = 1) is generated among the two viewpoint images that can be generated from. Control unit 121 of the LF data corresponding to the illustrated pixel array in Figure 2, to extract the signal of the first sub-pixel 201, to generate a first viewpoint image I 1. First viewpoint image I 1 is a viewpoint image corresponding to the first pupil partial area 501 of the image forming optical system. First viewpoint image I 1 is the RGB signals of the Bayer array having a resolution of pixel number N (= the number of pixels N V in the horizontal pixel number N H × vertical direction). Where necessary, it may generate the second viewpoint image I 2 corresponding to the second pupil partial area 502 of the image forming optical system.
このように本実施形態では、LFデータに基いて、結像光学系の瞳領域に対応する撮像画像Iと、それぞれが結像光学系の異なる瞳部分領域に対応する視点画像Ikの1つ以上とを生成する。生成した撮像画像および視点画像のデータは、記録媒体133に記録してもよい。なお、撮像画像Iから第1視点画像I1を減じることにより、第2視点画像I2を生成することができる。撮像画像Iは、各画素の光電変換部が分割されていない従来の撮像素子で得られる撮像画像に相当する。そのため、撮像画像Iには従来と同様の画像処理を適用することができる。また、各視点画像への処理を同等にするために、第1視点画像I1と、第2視点画像I2とを生成して、記録媒体133に記録するようにしてもよい。この場合、第1視点画像I1と第2視点画像I2とを合成することで、撮像画像Iを生成することができる。 As described above, in the present embodiment, based on the LF data, one of the captured image I corresponding to the pupil region of the imaging optical system and one of the viewpoint images I k corresponding to different pupil partial regions of the imaging optical system Generate the above. The generated captured image and viewpoint image data may be recorded on the recording medium 133. Incidentally, by subtracting the first viewpoint image I 1 from the captured image I, can generate a second viewpoint image I 2. The captured image I corresponds to a captured image obtained by a conventional imaging device in which the photoelectric conversion unit of each pixel is not divided. Therefore, the same image processing as in the prior art can be applied to the captured image I. Further, in order to equalize the process to each viewpoint image, the first viewpoint image I 1, and generates a second viewpoint image I 2, may be recorded on the recording medium 133. In this case, by combining the first viewpoint image I 1 and the second viewpoint image I 2, it is possible to generate a captured image I.
(視点画像のシェーディング補正(輝度補正))
次に、図9に示すS1におけるシェーディング補正(輝度補正)について説明する。本処理では、制御部121は、撮像画像Iに基づいて、第1視点画像I1(第k視点画像Ik)に対してRGB毎のシェーディング補正を行う。なお、以降の処理についても制御部121が実行する場合を例に説明するが、その一部又は全部を画像処理回路125が実行してもよい。
(Shading correction of the viewpoint image (brightness correction))
Next, shading correction (brightness correction) in S1 shown in FIG. 9 will be described. In the present process, the control unit 121 performs shading correction for each of the RGB with respect to the first viewpoint image I 1 (k th viewpoint image I k ) based on the captured image I. In addition, although the case where the control part 121 performs also about subsequent processes is demonstrated to an example, the image processing circuit 125 may perform the one part or all part.
まず、第1視点画像と第2視点画像(第1〜第NLF視点画像)の瞳ずれによるシェーディングについて説明する。図11は、撮像素子の周辺像高における第1光電変換部301が受光する第1瞳部分領域501、第2光電変換部302が受光する第2瞳部分領域502、および結像光学系の射出瞳400の関係を示している。図11では、第1光電変換部301と第2光電変換部302(第1光電変換部から第NLF光電変換部)が、それぞれ、第1副画素201と第2副画素202(第1副画素から第NLF副画素)に対応する。 First, shading due to pupil shift of the first viewpoint image and the second viewpoint image (first to Nth LF viewpoint images) will be described. FIG. 11 shows a first pupil partial region 501 received by the first photoelectric conversion unit 301 at a peripheral image height of the imaging device, a second pupil partial region 502 received by the second photoelectric conversion unit 302, and emission of the imaging optical system. The relationship of the pupil 400 is shown. In FIG. 11, the first photoelectric conversion unit 301 and the second photoelectric conversion unit 302 (the first photoelectric conversion unit to the N LF photoelectric conversion unit) respectively correspond to the first subpixel 201 and the second subpixel 202 (the first subpixel). Pixel to the N.sub.LF sub-pixel).
図11(A)は、結像光学系の射出瞳距離Dlと撮像素子107の設定瞳距離Dsが同じ場合を示している。この場合、第1瞳部分領域501と第2瞳部分領域502により、結像光学系の射出瞳400が、概ね、均等に瞳分割される。これに対して、図11(B)は、結像光学系の射出瞳距離Dlが撮像素子の設定瞳距離Dsより短い場合を示している。この場合、撮像素子107の周辺像高では、結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれが生じ、結像光学系の射出瞳400が、不均一に瞳分割されてしまう。図11(B)の例では、第1瞳部分領域501に対応した第1視点画像の実効絞り値が、第2瞳部分領域502に対応した第2視点画像の実効絞り値より小さい(明るい)値となる。反対側の像高(不図示)では、逆に、第1瞳部分領域501に対応した第1視点画像の実効絞り値が、第2瞳部分領域502に対応した第2視点画像の実効絞り値より大きい(暗い)値となる。 FIG. 11A shows the case where the exit pupil distance Dl of the imaging optical system and the set pupil distance Ds of the imaging element 107 are the same. In this case, the exit pupil 400 of the imaging optical system is approximately equally pupil-divided by the first pupil partial region 501 and the second pupil partial region 502. On the other hand, FIG. 11B shows the case where the exit pupil distance Dl of the imaging optical system is shorter than the set pupil distance Ds of the imaging device. In this case, at the peripheral image height of the imaging device 107, pupil deviation occurs between the exit pupil of the imaging optical system and the entrance pupil of the imaging device, and the exit pupil 400 of the imaging optical system is divided into pupils unevenly. In the example of FIG. 11B, the effective aperture value of the first viewpoint image corresponding to the first pupil partial region 501 is smaller (brighter) than the effective aperture value of the second viewpoint image corresponding to the second pupil partial region 502. It becomes a value. Conversely, at the image height on the opposite side (not shown), the effective aperture value of the first viewpoint image corresponding to the first pupil partial region 501 is the effective aperture value of the second viewpoint image corresponding to the second pupil partial region 502 It is a larger (darker) value.
同様に、図11(C)に示す、結像光学系の射出瞳距離Dlが撮像素子の設定瞳距離Dsより長い場合も、撮像素子107の周辺像高で結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれが生じる。このため、図11(C)に示す場合にも結像光学系の射出瞳400が不均一に瞳分割されてしまう。図11(C)の例では、第1瞳部分領域501に対応した第1視点画像の実効絞り値が、第2瞳部分領域502に対応した第2視点画像の実効絞り値より大きい(暗い)値となる。反対側の像高(不図示)では、逆に、第1瞳部分領域501に対応した第1視点画像の実効絞り値が、第2瞳部分領域502に対応した第2視点画像の実効絞り値より小さい(明るい)値となる。 Similarly, even when the exit pupil distance D1 of the imaging optical system is longer than the set pupil distance Ds of the imaging element shown in FIG. 11C, the exit pupil and imaging of the imaging optical system at the peripheral image height of the imaging element 107 A pupil shift of the entrance pupil of the element occurs. Therefore, the exit pupil 400 of the imaging optical system is divided into non-uniform pupils also in the case shown in FIG. In the example of FIG. 11C, the effective aperture value of the first viewpoint image corresponding to the first pupil partial region 501 is larger than the effective aperture value of the second viewpoint image corresponding to the second pupil partial region 502 (dark) It becomes a value. Conversely, at the image height on the opposite side (not shown), the effective aperture value of the first viewpoint image corresponding to the first pupil partial region 501 is the effective aperture value of the second viewpoint image corresponding to the second pupil partial region 502 It becomes smaller (brighter) value.
このように、瞳分割が不均一になることに伴い、第1視点画像と第2視点画像の強度も不均一になり(すなわち光量分布が偏り)、第1視点画像と第2視点画像のいずれか一方の強度が大きく、また他方の強度が小さくなるシェーディングが生じる。そして、このシェーディングは画素ごと、すなわちRGBごとに生じる。 Thus, as the pupil division becomes nonuniform, the intensities of the first viewpoint image and the second viewpoint image also become nonuniform (that is, the light amount distribution is biased), and either of the first viewpoint image and the second viewpoint image Shading occurs where one intensity is high and the other intensity is low. And, this shading occurs for each pixel, that is, for each RGB.
そこで、上述したシェーディングによる不均一な信号強度分布を一様に近づけて良好な画質品位の視点画像を生成するため、RGBごとのシェーディング補正を行う。すなわち、本実施形態では、補正撮像画像I(j,i)を基準の参照画像として第1視点画像I1(第k視点画像Ik)に対するRGB毎のシェーディング補正を行う。 Therefore, in order to generate a viewpoint image of good image quality and quality by uniformly bringing the above-mentioned uneven signal intensity distribution due to shading into consideration, shading correction for each RGB is performed. That is, in the present embodiment, shading correction for each RGB is performed on the first viewpoint image I 1 (k th viewpoint image I k ) using the corrected captured image I (j, i) as a reference image.
具体的には、図9のS1において制御部121は、まず、撮像画像Iと第1視点画像I1から有効画素を検出する(S1−1)。有効画素は、撮像画像Iにおいても、第1視点画像I1においても非飽和かつ非欠陥(非キズ)の画素である。具体的には、制御部121は、撮像画像Iと第1視点画像I1との対応する画素(画素I(j,i)および画素I1(j,i))について、いずれも有効画素であるか、少なくとも一方が有効画素でないかを判定する。そして、制御部121は、いずれも有効画素と判定されればV1(j,i)=1、少なくとも一方が有効画素でないと判定されればV1(j,i)=0とする。V1は、有効画素については1、無効画素については0の値を有する2値画像と見なすことができる。あるいはV1は、欠陥画素位置を0で示す画像と見なすこともできる。例えば、制御部121は、画素値が飽和判定閾値ISを超える場合には飽和画素、超えない場合は非飽和画素と判定することができる。ただし、視点画像に用いる飽和判定閾値ISkは、撮像画像に用いる飽和判定閾値IS以下とする。また、制御部121は、撮像素子107に欠陥画素として登録されている画素については欠陥画素、登録されていない画素は非欠陥画素と判定することができる。なお、これらの判定方法は単なる例示であり、ある画素が飽和画素か否かや、欠陥画素か否かは、公知の任意の方法で判定することができる。制御部121は、第k視点画像Ik(k≧2)についてシェーディング補正を行う場合も、同様にして有効画素を検出する。 More specifically, the control unit 121 in S1 of FIG. 9, first, detects the effective pixels from the captured image I and the first viewpoint image I 1 (S1-1). Effective pixels, in the captured image I, also in the first viewpoint image I 1 which is a pixel of the non-saturation and non-defective (non-scratch). Specifically, the control unit 121 is an effective pixel for each of the corresponding pixels (pixel I (j, i) and pixel I 1 (j, i)) of the captured image I and the first viewpoint image I 1. It is determined whether there are any pixels or at least one of them is not a valid pixel. Then, the control unit 121 sets V 1 (j, i) = 1 if all are determined to be valid pixels, and V 1 (j, i) = 0 if it is determined that at least one is not a valid pixel. V 1 can be regarded as a binary image having a value of 1 for valid pixels and 0 for invalid pixels. Alternatively, V 1 can also be regarded as an image indicating a defective pixel position as 0. For example, the control unit 121 can determine that the pixel is a saturated pixel when the pixel value exceeds the saturation determination threshold IS and a non-saturated pixel when the pixel value does not exceed the saturation determination threshold IS. However, the saturation determination threshold IS k used for the viewpoint image is less than or equal to the saturation determination threshold IS used for the captured image. Further, the control unit 121 can determine that a pixel registered as a defective pixel in the imaging element 107 is a defective pixel, and a pixel not registered is a non-defective pixel. Note that these determination methods are merely examples, and it can be determined whether a certain pixel is a saturated pixel or a defective pixel by any known method. The control unit 121 detects an effective pixel in the same manner when performing shading correction on the k-th viewpoint image I k (k ≧ 2).
本実施形態の撮像素子107では、各画素が有する複数の光電変換部のいずれかが飽和した場合、画素外ではなく、同一画素内の他の光電変換部(副画素)に飽和電荷が漏れこむように構成される。このような飽和電荷の漏れ込みを電荷クロストークと呼ぶ。同一画素内で電荷クロストークが発生すると、飽和した副画素(例:第2副画素202)と、飽和電荷が漏れこむ副画素(例:第1副画素201)のいずれも、入射光量に対する蓄積電荷量の線形関係が保たれない。そのため、電荷クロストークが生じた画素については、シェーディングを正しく検出できない。 In the image sensor 107 of the present embodiment, when any of the plurality of photoelectric conversion units included in each pixel is saturated, the saturation charge leaks to other photoelectric conversion units (sub-pixels) in the same pixel instead of outside the pixel. Are configured. Such leakage of saturated charge is called charge crosstalk. When charge crosstalk occurs in the same pixel, both of the saturated sub-pixel (for example, the second sub-pixel 202) and the sub-pixel for which the saturated charge leaks (for example, the first sub-pixel 201) The linear relationship of the amount of charge can not be maintained. Therefore, shading can not be correctly detected for pixels in which charge crosstalk has occurred.
撮影感度が高い場合よりも低い場合の方が、光電変換部に蓄積される電荷量が相対的に多く、電荷クロストークが相対的に生じやすい。したがって、本実施形態では、飽和画素の検出精度を向上するために、第1の撮影感度での撮像信号の飽和判定閾値ISを、第1の撮影感度より高い第2の撮影感度での撮像信号の飽和判定閾値IS以下とすることができる。視点画像に用いる飽和判定閾値ISkについても同様である。 The amount of charge accumulated in the photoelectric conversion portion is relatively large and the charge crosstalk is relatively likely to occur in the case where the imaging sensitivity is high and the case where the imaging sensitivity is low. Therefore, in the present embodiment, in order to improve the detection accuracy of the saturated pixel, the saturation determination threshold IS of the imaging signal at the first imaging sensitivity is set to the imaging signal at the second imaging sensitivity higher than the first imaging sensitivity. Or less than the saturation determination threshold IS. The same applies to the saturation determination threshold IS k used for the viewpoint image.
さらに、結像光学系の射出瞳距離が、第1の所定瞳距離より短い(もしくは、第2の所定瞳距離(>第1の所定瞳距離)より長い)場合、結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれによるシェーディングを生じる。この場合、像高が大きな周辺部の画素では、第1視点画像と第2視点画像のいずれか一方の強度が大きくなり、他方の強度が小さくなるため、電荷クロストークが生じやすい。したがって、本実施形態では、飽和画素の検出精度を向上するために、瞳ずれによるシェーディングが発生する場合の飽和判定閾値ISを、瞳ずれによるシェーディングが発生しない場合の飽和判定閾値IS以下にすることができる。瞳ずれによるシェーディングが発生しない場合とは、結像光学系の射出瞳距離が、第1の所定瞳距離以上、かつ、第2の所定瞳距離以下の場合である。視点画像に用いる飽和判定閾値ISkについても同様である。 Furthermore, when the exit pupil distance of the imaging optical system is shorter than the first predetermined pupil distance (or longer than the second predetermined pupil distance (> first predetermined pupil distance)), the exit pupil of the imaging optical system And shading due to pupil shift of the entrance pupil of the imaging device. In this case, in the peripheral pixels where the image height is large, the intensity of one of the first viewpoint image and the second viewpoint image is increased and the intensity of the other is decreased, so that charge crosstalk easily occurs. Therefore, in the present embodiment, in order to improve the detection accuracy of the saturated pixel, the saturation determination threshold IS in the case of occurrence of shading due to pupil displacement is made equal to or less than the saturation determination threshold IS in the case of no shading due to pupil displacement Can. The case where shading due to pupil shift does not occur is the case where the exit pupil distance of the imaging optical system is equal to or greater than the first predetermined pupil distance and equal to or less than the second predetermined pupil distance. The same applies to the saturation determination threshold IS k used for the viewpoint image.
ここで、図2に示したベイヤー配列の撮像画像Iは、ベイヤーパターンの各色(R、Gr、Gb、B)ごとに定義することができる。
すなわち、Rの撮像画像をRIは、
画素RI(2j2−1,2i2−1)=I(2j2−1,2i2−1)から構成される。
Grの撮像画像GrIは、
画素GrI(2j2−1,2i2)=I(2j2−1,2i2)から構成される。
Gbの撮像画像GrIは、
画素GbI(2j2,2i2−1)=I(2j2,2i2−1)から構成される。
Bの撮像画像BIは、
画素BI(2j2,2i2)=I(2j2,2i2)から構成される。
このとき、整数j2および整数i2は、それぞれ1≦j2≦NV/2、1≦i2≦NH/2である。
Here, the captured image I of the Bayer array shown in FIG. 2 can be defined for each color (R, Gr, Gb, B) of the Bayer pattern.
That is, RI is a captured image of R
Composed of pixels RI (2j 2 -1,2i 2 -1) = I (2j 2 -1,2i 2 -1).
The Gr captured image GrI is
It consists of pixels GrI (2j 2 -1, 2i 2 ) = I (2j 2 -1, 2i 2 ).
Gb captured image GrI
Composed of pixels GbI (2j 2, 2i 2 -1 ) = I (2j 2, 2i 2 -1).
The captured image BI of B is
It consists of pixels BI (2j 2 , 2i 2 ) = I (2j 2 , 2i 2 ).
At this time, the integer j 2 and the integer i 2 are 1 ≦ j 2 ≦ N V / 2 and 1 ≦ i 2 ≦ N H / 2, respectively.
同様に、図2に例示したベイヤー配列の第k視点画像Ikを、R、Gr、Gb、Bごとに取り扱う。
すなわち、Rの第k視点画像RIkは、
画素RIk(2j2−1,2i2−1)=Ik(2j2−1,2i2−1)から構成される。
Grの第k視点画像GrIk
画素GrIk(2j2−1,2i2)=Ik(2j2−1,2i2)から構成される。
Gbの第k視点画像GbIkは、
画素GbIk(2j2,2i2−1)=Ik(2j2,2i2−1)から構成される。
Bの第k視点画像BIkは、
画素BIk(2j2,2i2)=Ik(2j2,2i2)から構成される。
整数j2および整数i2は、それぞれ1≦j2≦NV/2、1≦i2≦NH/2である。
Similarly, the k-th viewpoint image I k of the Bayer array illustrated in FIG. 2 is handled for each of R, Gr, Gb, and B.
That is, the k-th viewpoint image RI k of R is
Composed of pixels RI k (2j 2 -1,2i 2 -1 ) = I k (2j 2 -1,2i 2 -1).
Gr's kth viewpoint image GrI k
It comprises pixels GrI k (2j 2 -1, 2i 2 ) = I k (2j 2 -1, 2i 2 ).
Gb kth viewpoint image GbI k is
It consists of pixels GbI k (2j 2 , 2i 2 -1) = I k (2j 2 , 2i 2 -1).
The k th viewpoint image BI k of B is
It consists of pixels BI k (2j 2 , 2i 2 ) = I k (2j 2 , 2i 2 ).
The integer j 2 and the integer i 2 are respectively 1 ≦ j 2 ≦ N V / 2 and 1 ≦ i 2 ≦ N H / 2.
[射影処理]
次に、図9に示すS1において、射影手段としての制御部121は、撮像画像RI、GrI、GbI、BIに基づく射影処理を行う(S1−2A)。具体的には、撮像画像RI、GrI、GbI、BIの各画素を、式(3A)から式(3D)に従って、射影方向に投影し、射影方向と直交する方向に複数の信号が並んだ1次元の射影信号を生成する。ここでは、射影方向を、瞳分割方向(x方向)と直交する方向(y方向)とする。これにより、画像のx方向における輝度変化に関する射影信号が得られる。なお、射影方向は他の方向であってもよい。これにより、制御部121は、撮像画像の射影信号Pを構成する各色の画素RP(2i2−1)、GrP(2i2)、GbP(2i2−1)、BP(2i2)を生成する。
[Projection processing]
Next, in S1 shown in FIG. 9, the control unit 121 as a projection unit performs projection processing based on the captured image RI, GrI, GbI, and BI (S1-2A). Specifically, each pixel of the captured image RI, GrI, GbI, and BI is projected in the projection direction according to the equations (3A) to (3D), and a plurality of signals are arranged in the direction orthogonal to the projection direction 1 Generate a dimensional projection signal. Here, the projection direction is a direction (y direction) orthogonal to the pupil division direction (x direction). As a result, a projection signal related to the change in luminance in the x direction of the image is obtained. The projection direction may be another direction. Thereby, the control unit 121 generates the pixels RP (2i 2 -1), GrP (2i 2 ), GbP (2i 2 -1), and BP (2i 2 ) of the respective colors constituting the projection signal P of the captured image. .
なお、飽和信号値や欠陥信号値には、撮像画像のRGB毎のシェーディングを正しく検出するための情報が含まれていない。そのため、制御部121は、撮像画像IとVkとの対応する画素の積を取ることにより、撮像画像Iの無効画素を除外してから射影処理を行う。この射影処理は、式(3A)〜(3D)上段の式の分子に相当する。そして、制御部121は、射影結果を、射影処理に用いた有効画素数で規格化する。この正規化処理は、式(3A)〜(3D)上段の式の分母に相当する。射影処理に用いた有効画素数が0の場合、制御部121は、式(3A)〜(3D)の下段に示すように、撮像画像の射影信号を0に設定する。さらに、制御部121は、撮像画像の射影信号がノイズの影響などで負信号となった場合も撮像画像の射影信号を0に設定する。 Note that the saturation signal value and the defect signal value do not include information for correctly detecting the shading for each RGB of the captured image. Therefore, the control unit 121 performs projection processing after excluding the invalid pixels of the captured image I by taking the product of the corresponding pixels of the captured image I and V k . This projection processing corresponds to the numerator of the upper equation of the equations (3A) to (3D). Then, the control unit 121 normalizes the projection result by the number of effective pixels used in the projection process. This normalization process corresponds to the denominator of the upper equation of equations (3A) to (3D). When the number of effective pixels used for the projection process is zero, the control unit 121 sets the projection signal of the captured image to zero as shown in the lower part of Expressions (3A) to (3D). Furthermore, the control unit 121 sets the projection signal of the captured image to 0 also when the projection signal of the captured image is a negative signal due to the influence of noise or the like.
同様に、S1−2Bで制御部121は、第k視点画像RIk、GrIk、GbIk、BIkの各画素を、式(3E)から式(3H)に従って、瞳分割方向と直交する方向(y方向)に射影する。これにより、制御部121は、第k視点画像の射影信号Pkを構成する各色の画素RPk(2i2−1)、GrPk(2i2)、GbPk(2i2−1)、BPk(2i2)を生成する。 Similarly, in step S1-2B, the control unit 121 causes the pixels of the k-th viewpoint images RI k , GrI k , GbI k , and BI k to be orthogonal to the pupil division direction according to equations (3E) to (3H). Project in (y direction). Thus, the control unit 121 causes the pixels RP k (2i 2 -1), GrP k (2i 2 ), GbP k (2i 2 -1), and BP k of the respective colors that constitute the projection signal P k of the k-th viewpoint image. Generate (2i 2 ).
制御部121は、上述の射影処理の後に、撮像画像の射影信号Pと第k視点画像の射影信号Pkを平滑化するためにローパスフィルタ処理を必要に応じて適用する。 The control unit 121 applies, as necessary, low-pass filter processing to smooth the projection signal P of the captured image and the projection signal P k of the k-th viewpoint image after the above-described projection processing.
S1ー3で制御部121は、S1−2Bで求めた、視点画像の射影信号を、シェーディングの補正値の算出に用いるか否かを判定する。制御部121は、視点画像について、射影方向に並んだ複数の画素ごと(すなわち、画素列ごと)に評価値を求める。そして、制御部121は、評価値と予め定められた閾値との比較結果に応じて、対応する射影信号を有効とするか無効とするか(シェーディング補正値の算出に用いるか用いないか)を判定する。 In step S1-3, the control unit 121 determines whether to use the projection signal of the viewpoint image obtained in step S1-2B for calculation of a shading correction value. The control unit 121 obtains an evaluation value for each of a plurality of pixels (that is, each pixel column) arranged in the projection direction for the viewpoint image. Then, in accordance with the comparison result of the evaluation value and the predetermined threshold value, the control unit 121 determines whether the corresponding projection signal is valid or invalid (whether or not to use for calculation of the shading correction value). judge.
信号のSN比を考慮して射影信号の有効性を判定するため、有効画素数と輝度との両方を考慮した評価値を用いる。一般に、信号のSN比は、複数の信号値を加算することによって向上し、例えば、信号値を4つ加算すれば、信号のSN比を2倍にすることができる。また、画像信号のSN比は輝度の1/2乗に比例する。そのため、信号値の加算を含む演算により評価値を求めることで、輝度が低く、したがってSN比が低い視点画像の信号の有効/無効を正確に判定することができる。射影信号の有効性を正確に判定することで、有効な(信頼性の高い)射影信号を用いてシェーディング補正値を算出できる。 In order to determine the effectiveness of the projection signal in consideration of the signal-to-noise ratio of the signal, an evaluation value in which both the number of effective pixels and the luminance are considered is used. In general, the signal-to-noise ratio of a signal is improved by adding a plurality of signal values. For example, by adding four signal values, it is possible to double the signal-to-noise ratio of the signal. Further, the SN ratio of the image signal is proportional to 1/2 of the luminance. Therefore, by obtaining the evaluation value by calculation including addition of signal values, it is possible to accurately determine the validity / invalidity of the signal of the viewpoint image with low luminance and therefore low SN ratio. By accurately determining the validity of the projection signal, it is possible to calculate a shading correction value using an effective (reliable) projection signal.
視点画像の射影信号の有効性判定は色成分(R、Gr、Gb、B)ごとに行う。例えば、第k視点画像の射影信号Pkを構成する赤色画素RPk(2i2−1)の有効性は、第k視点画像RIkから得られる評価値に基づいて判定する。 The validity determination of the projection signal of the viewpoint image is performed for each color component (R, Gr, Gb, B). For example, the validity of the red pixel RP k (2i 2 -1) that constitutes the projection signal P k of the k-th viewpoint image is determined based on the evaluation value obtained from the k-th viewpoint image RI k .
撮像画像Iと視点画像Ikとを比較した場合、視点画像Ikの方が輝度は小さい。これは、視点画像Ikの生成に用いる光電変換部の受光面の大きさが、撮像画像Iの生成に用いる光電変換部の受光面の大きさより小さいからである。そのため、本実施形態では、撮像画像よりも輝度が低く、したがってSN比が低い視点画像の射影信号についての有効性を判定する。また、撮像画像よりも輝度が低い視点画像についての閾値判定を正確に行うため、信号値を加算した評価値を生成し、閾値と比較する。 When the captured image I and the viewpoint image I k are compared, the luminance of the viewpoint image I k is smaller. This is because the size of the light receiving surface of the photoelectric conversion unit used to generate the viewpoint image I k is smaller than the size of the light receiving surface of the photoelectric conversion unit used to generate the captured image I. Therefore, in the present embodiment, the validity of the projection signal of the viewpoint image whose luminance is lower than that of the captured image, and therefore the SN ratio is low is determined. Further, in order to accurately perform threshold determination on a viewpoint image whose luminance is lower than that of a captured image, an evaluation value to which signal values are added is generated and compared with the threshold.
判定処理は、色成分(R、Gr、Gb、B)ごとに、同じ式に基づいて適用する。以下では、図12に示すフローチャートを用い、R成分に関する処理を代表的に説明するが、他の色成分についても同様に適用することができる。 The determination process is applied to each color component (R, Gr, Gb, B) based on the same equation. In the following, processing relating to the R component is representatively described using the flowchart shown in FIG. 12, but the same applies to other color components.
上述したように、Rの第k視点画像RIkは、
画素RIk(2j2−1,2i2−1)=Ik(2j2−1,2i2−1)から構成される。また、整数j2および整数i2は、それぞれ1≦j2≦NV/2、1≦i2≦NH/2である。
As described above, the k-th viewpoint image RI k of R is
Composed of pixels RI k (2j 2 -1,2i 2 -1 ) = I k (2j 2 -1,2i 2 -1). The integer j 2 and the integer i 2 are respectively 1 ≦ j 2 ≦ N V / 2 and 1 ≦ i 2 ≦ N H / 2.
閾値判定において制御部121は、まず、式(3I)により、i2列目の評価値Ei2を求める(S1301)。ここで、評価値Ei2は、欠陥画素位置に該当する画素の値を用いずに生成されるため、有効画素数に比例する。また、評価値Ei2は、画素値(輝度)の二乗累積値であるから、画素値(輝度)に比例する。したがって、評価値Ei2は、有効画素数および輝度を考慮した評価値である。また、このような評価値を用いることで、画像信号のSN比を考慮して射影信号の有効性を判定できる。
次に、制御部121は、式(3J)により、評価値Ei2と垂直方向の評価閾値Elimitとを比較する(S1302)。そして、制御部121は、評価値Ei2が評価閾値Elimitより大きい場合、S1−3で求めた射影信号RP(2i2−1)を有効と判定する(S1303)。一方、制御部121は、評価値Ei2が評価閾値Elimit以下である場合、S1−3で求めた射影信号RP(2i2−1)を無効と判定する(S1304)。制御部121は、無効と判定した射影信号については、その値が使用されないように値を0にしてもよい。 Next, the control unit 121, by the formula (3J), compares the evaluation value E i2 and vertical evaluation threshold E limit (S1302). Then, the control unit 121, when the evaluation value E i2 is larger than the rated threshold E limit, determines an effective projection signal RP (2i 2 -1) obtained in S1-3 (S1303). On the other hand, the control unit 121, when the evaluation value E i2 is equal to or less than the rated threshold E limit, is determined to be invalid the projection signal RP (2i 2 -1) obtained in S1-3 (S1304). The control unit 121 may set the value to 0 so that the value of the projection signal determined to be invalid is not used.
制御部121は、有効性判定を視差画像の全画素列について実行したか否かを判定し(S1305)、実行したと判定されれば処理を終了し、判定されなければ処理をS1301に戻して未判定の画素列に対する判定処理を実行する。制御部121は、このような評価値Eの算出、評価値Eと閾値Elimitとの比較による射影信号RPk(2i2−1)の有効性判定を、視差画像の画素列ごとに(iの値を変えながら)実行する。また、制御部121は、他の色成分であるGrPk(2i2)、GbPk(2i2−1)、BPk(2i2)についても同様に判定処理を適用する。 The control unit 121 determines whether or not the validity determination has been performed for all the pixel rows of the parallax image (S1305), and if it is determined that it has been executed, the processing ends, otherwise the processing returns to S1301. A determination process is performed on an undetermined pixel row. The control unit 121 determines the validity of the projection signal RP k (2i 2 −1) by calculating the evaluation value E and comparing the evaluation value E with the threshold value E limit for each pixel row of the parallax image (i To change the value of). The control unit 121 applies the determination process to other color components GrP k (2i 2 ), GbP k (2i 2 -1), and BP k (2i 2 ) in the same manner.
なお、式(3I)は評価値Eを算出するための1例であり、視点画像について、垂直方向の画素数を考慮して算出された他の任意の評価値を用いることができる。なお、式(3I)で得られる評価値Eは、固定パターンノイズを考慮していないため、固定パターンノイズを考慮した評価値とすることで、より正確な判定を行うことができる。具体的には、固定パターンノイズは輝度に依存しないため、式(3I)に固定値Offsetの項を追加した式(3K)を用いることにより、固定パターンノイズを考慮した評価値Eを求めることができる。 Equation (3I) is an example for calculating the evaluation value E, and another arbitrary evaluation value calculated in consideration of the number of pixels in the vertical direction can be used for the viewpoint image. In addition, since fixed pattern noise is not considered, the evaluation value E obtained by Formula (3I) can perform more exact determination by setting it as the evaluation value which considered fixed pattern noise. Specifically, since fixed pattern noise does not depend on luminance, it is possible to obtain an evaluation value E in consideration of fixed pattern noise by using equation (3K) obtained by adding the term of fixed value Offset to equation (3I). it can.
また、撮像画像Iや視差画像Ikは、画像処理負荷の低減やSN比の改善を目的として、S1−1における有効画素検出処理の実施前に加算や間引により画素数が削減されていることがある。特に、画素が加算されている場合、上述したように信号のSN比が向上しているため、評価値を、加算を考慮した閾値と比較することにより、射影信号の有効性を正確に判定することができる。例えば、S1−1における有効画素検出処理の前に、垂直または垂直方向の画素数が加算処理によって1/N(Nは2以上の整数)に削減されているとする。この場合、加算処理により、加算方向における画像信号のSN比がN1/2倍向上している。そのため、評価値を、補正した閾値Elimit/(N1/2)と比較するようにする。なお、画素が間引きされている場合は信号のSN比に変化はないため、閾値Eの補正は不要である。 In addition, the number of pixels of the captured image I and the parallax image I k is reduced by addition and thinning before performing effective pixel detection processing in S1-1 for the purpose of reducing the image processing load and improving the SN ratio. Sometimes. In particular, when the pixels are added, the signal-to-noise ratio of the signal is improved as described above, so the validity of the projection signal is accurately determined by comparing the evaluation value with the threshold considering the addition. be able to. For example, it is assumed that the number of pixels in the vertical or vertical direction is reduced to 1 / N (N is an integer of 2 or more) by addition processing before the effective pixel detection processing in S1-1. In this case, the SN ratio of the image signal in the addition direction is improved by N 1/2 times by the addition process. Therefore, the evaluation value is compared with the corrected threshold value E limit / (N 1/2 ). When the pixels are thinned out, there is no change in the signal-to-noise ratio of the signal, so that the correction of the threshold E is unnecessary.
本実施形態では射影処理において画像を画素列ごと(垂直方向)に射影し、水平方向の1次元画像(射影信号)を得ているため、閾値Eは画像の垂直方向における閾値である。一方、画像の水平方向にも閾値を設定することができる。例えば、図12に示した処理において有効と判定された射影信号の割合について閾値を設定することができる。射影信号の総数は水平方向の画素数に等しいため、有効と判定された射影信号の割合についての閾値は、水平方向における閾値である。例えば、色成分単位での有効性判定処理の結果、有効と判定された射影信号の割合もしくは数が閾値以下の場合、制御部121は、有効と判定された射影信号を含め、視点画像の射影信号を全て無効と判定する。この場合、後述するS1−4でシェーディング関数を生成するためのデータとして、信頼性の高いデータが十分な数得られなかったことになる。そのため、制御部121は、シェーディング関数の生成およびシェーディング関数を用いたシェーディング補正を行わない。つまり、水平方向における閾値は、シェーディング補正を行うか否かの判定閾値である。 In the present embodiment, the image is projected in pixel rows (vertical direction) in projection processing to obtain a horizontal one-dimensional image (projection signal), so the threshold E is a threshold in the vertical direction of the image. On the other hand, the threshold can also be set in the horizontal direction of the image. For example, a threshold can be set for the proportion of projection signals determined to be valid in the process shown in FIG. Since the total number of projection signals is equal to the number of pixels in the horizontal direction, the threshold for the proportion of projection signals determined to be valid is the threshold in the horizontal direction. For example, when the ratio or the number of projection signals determined to be effective is less than or equal to the threshold as a result of the effectiveness determination process in color component units, the control unit 121 projects the viewpoint image including the projection signals determined to be effective. Determine all signals as invalid. In this case, a sufficient number of data having high reliability can not be obtained as data for generating a shading function in S1-4 described later. Therefore, the control unit 121 does not perform generation of the shading function and shading correction using the shading function. That is, the threshold in the horizontal direction is a determination threshold whether to perform shading correction.
S1−1における有効画素検出は、飽和やキズの有無に基づくものであり、信号のSN比は考慮されていない。具体的には、画素の出力値が低いSN比によって真値からずれていても、出力値に基づいて有効性が判定される。一方、S1−3における射影信号の有効性判定は、射影信号がシェーディング補正値の算出に用いるのに適切あるか否かの判定であるため、低いSN比による真値からのずれを許容してしまうと、シェーディング補正の精度低下を招く。低いSN比によって真値からずれている射影信号は除外することにより、精度の良いシェーディング補正が実現できる。 The effective pixel detection in S1-1 is based on the presence or absence of saturation or a flaw, and the SN ratio of the signal is not considered. Specifically, even if the output value of the pixel deviates from the true value due to the low SN ratio, the validity is determined based on the output value. On the other hand, since the judgment of the validity of the projection signal in S1-3 is a judgment as to whether or not the projection signal is appropriate for use in the calculation of the shading correction value, allowing a deviation from the true value due to a low SN ratio. If so, the accuracy of shading correction may be reduced. By excluding the projection signal which is deviated from the true value due to the low SN ratio, accurate shading correction can be realized.
図13(A)および(B)は射影信号の具体例を示し、横軸は水平方向の画素位置、縦軸は信号強度である。す。図13(A)は、撮像画像の射影信号Pを構成する緑(G)成分、赤(R)、青(B)成分の値の例を示している。なお、G成分はGr成分とGb成分とをまとめて示しているため、水平方向の各画素位置に値が存在する。一方、R、B成分は1画素おきの位置に値を有するが、図では便宜上連続的に記載している。また、図13(B)は、図13(A)と同様に、第1視点画像の射影信号Pkを構成する緑(G)成分、赤(R)、青(B)成分の値の例を示している。各射影信号の信号強度は、被写体の色に応じた値を有する。従って、第k視点画像Ikのシェーディング補正を正確に行うためには、瞳ずれにより生じる第k視点画像IkのRGB成分間の光量のずれ(シェーディング成分)と、被写体の色に起因するRGB成分とを分離する必要がある。 FIGS. 13A and 13B show specific examples of projection signals, in which the horizontal axis is the pixel position in the horizontal direction, and the vertical axis is the signal intensity. The FIG. 13A shows an example of the values of the green (G) component, the red (R), and the blue (B) component that constitute the projection signal P of the captured image. In addition, since G component shows Gr component and Gb component collectively, a value exists in each horizontal pixel position. On the other hand, although the R and B components have values at every other pixel position, they are continuously described in the drawing for the sake of convenience. Further, FIG. 13B is an example of values of green (G) component, red (R) component, and blue (B) component constituting the projection signal P k of the first viewpoint image as in FIG. 13 (A). Is shown. The signal strength of each projection signal has a value corresponding to the color of the subject. Therefore, in order to perform shading correction of the k-th viewpoint image I k correctly, the amount of deviation between the RGB components of the k-th viewpoint image I k caused by the pupil deviation (shading component), RGB due to the color of the subject It is necessary to separate the ingredients.
図9のS1−4を実行する前に制御部121は、S1−3における有効性判定処理により、全ての色成分について、水平方向の閾値を超える割合または数の射影信号が有効と判定されているか否かを判定する。そして、水平方向の閾値を超える割合または数の射影信号が有効と判定されていない色成分が1つでもある場合には、S1−4以降の、シェーディング補正に関する処理は行わない。 Before performing S1-4 in FIG. 9, the control unit 121 determines that the ratio or number of projection signals exceeding the threshold in the horizontal direction is effective for all color components by the effectiveness determination process in S1-3. Determine if there is. Then, when there is even one color component for which the ratio or number of projection signals exceeding the threshold in the horizontal direction is not determined to be valid, the processing relating to the shading correction after S1-4 is not performed.
一方、全ての色成分について水平方向の閾値を超える割合または数の射影信号が有効と判定されていれば、制御部121はS1−4以降の処理を実行する。なお、以下の処理においては、全ての射影信号が有効と判定された場合を想定して説明するが、実際には、無効と判定された射影信号については処理をスキップする。 On the other hand, if it is determined that the ratio or the number of projection signals exceeding the threshold in the horizontal direction is valid for all color components, the control unit 121 executes the processing of S1-4 and thereafter. Although the following processing will be described on the assumption that all projection signals are determined to be valid, the processing is actually skipped for projection signals determined to be invalid.
S1−4において制御部121は、式(4A)から式(4D)に従って、撮像画像Iを基準とした相対的な第k視点画像IkのRGB毎のシェーディング信号RSk(2i2−1)、GrSk(2i2)、GbSk(2i2−1)、BSk(2i2)を算出する。なお、撮像素子における画素の受光量は、画素を分割した副画素の受光量より大きい必要があり、さらに、シェーディング成分の算出には、副画素の受光量が0より大きい必要がある。そのため、制御部121は、条件式RP(2i2−1)>RPk(2i2−1)>0を満たす場合、式(4A)に従って、第k視点画像のR成分RIkの射影信号RPk(2i2−1)と撮像画像のR成分RIの射影信号RP(2i2−1)との比(すなわち割合)を算出する。そして、制御部121は、算出した比に規格化のための瞳分割数NLFを乗算して、第k視点画像IkのR成分のシェーディング信号RSk(2i2−1)を生成する。これにより、被写体に起因するRの信号成分を相殺し、第k視点画像IkのRのシェーディング成分を分離することができる。一方、制御部121は、条件式RP(2i2−1)>RPk(2i2−1)>0を満たさない場合、第k視点画像IkのR成分のシェーディング信号RSk(2i2−1)を0に設定する。 In S1-4, the control unit 121 performs the shading signal RS k (2i 2 −1) for each RGB of the k-th viewpoint image I k relative to the captured image I according to Equations (4A) to (4D) , GrS k (2i 2 ), GbS k (2i 2 −1), and BS k (2i 2 ). The amount of light received by the pixel in the imaging device needs to be larger than the amount of light received by the sub-pixel obtained by dividing the pixel, and the amount of light received by the sub-pixel needs to be larger than 0 for calculation of the shading component. Therefore, when the control unit 121 satisfies the conditional expression RP (2i 2 -1)> RP k (2i 2 -1)> 0, the projection signal RP of the R component RI k of the k-th viewpoint image is satisfied according to equation (4A). The ratio (that is, the ratio) of k (2i 2 -1) and the projection signal RP (2i 2 -1) of the R component RI of the captured image is calculated. Then, the control unit 121 multiplies the calculated ratio by the pupil division number N LF for normalization to generate a shading signal RS k (2i 2 −1) of the R component of the k-th viewpoint image I k . As a result, it is possible to offset the R signal component caused by the subject and to separate the R shading component of the k-th viewpoint image I k . On the other hand, when the control unit 121 does not satisfy the conditional expression RP (2i 2 −1)> RP k (2i 2 −1)> 0, the shading signal RS k (2i 2 −) of the R component of the k th viewpoint image I k Set 1) to 0.
同様に、他の色成分におけるシェーディング信号を算出する。第k視点画像IkのGr成分については、条件式GrP(2i2)>GrPk(2i2)>0を満たす場合、式(4B)に従って第k視点画像のGr成分の射影信号GrPk(2i2)と、撮像画像のGr成分の射影信号GrP(2i2)との比を算出する。そして、制御部121は、算出した比に規格化のため瞳分割数NLFを乗算して、第k視点画像IkのGr成分のシェーディング信号GrSk(2i2)を生成する。これにより、被写体に起因するGrの信号成分を相殺し、第k視点画像IkのGr成分のシェーディング成分を分離することができる。また、制御部121は、条件式GrP(2i2)>GrPk(2i2)>0を満たさない場合、第k視点画像IkのGr成分のシェーディング信号GrSk(2i2)を0に設定する。 Similarly, shading signals for other color components are calculated. With regard to the Gr component of the k-th viewpoint image I k , when the conditional expression GrP (2i 2 )> GrP k (2i 2 )> 0 is satisfied, the projection signal GrP k of the Gr component of the k-th viewpoint image and 2i 2), calculates the ratio of the projection-back signals GrP (2i 2) of Gr component of the captured image. Then, the control unit 121 multiplies the calculated ratio by the number of pupil divisions N LF for normalization to generate a shading signal GrS k (2i 2 ) of the Gr component of the k-th viewpoint image I k . As a result, it is possible to offset the Gr signal component caused by the subject and to separate the shading component of the Gr component of the k-th viewpoint image I k . The control unit 121 sets the shading signal GrS k (2i 2 ) of the Gr component of the k-th viewpoint image I k to 0 when the conditional expression GrP (2i 2 )> GrP k (2i 2 )> 0 is not satisfied. Do.
同様に、式(4C)及び(4D)に従って、第k視点画像IkのGb成分のシェーディング信号GbSk(2i2−1)及び第k視点画像IkのB成分のシェーディング信号BSk(2i2)を生成する。 Similarly, equation (4C) and in accordance with (4D), the shading signals BS k of the B component of the shading signals GbS k (2i 2 -1) and a k-viewpoint image I k of Gb component of the k viewpoint image I k (2i 2 ) Generate.
なお、シェーディング補正精度を高精度に行うために、有効なシェーディング信号が十分存在する場合にのみシェーディング補正を行うようにしてもよい。例えば、RSk(2i2−1)>0、GrSk(2i2)>0、GbSk(2i2−1)>0、BSk(2i2)>0を満たす有効なシェーディング信号が所定数以上である場合に、シェーディング補正を行うようにすればよい。 Note that, in order to perform the shading correction accuracy with high accuracy, the shading correction may be performed only when there are sufficient effective shading signals. For example, predetermined number of effective shading signals satisfying RS k (2i 2 -1)> 0, GrS k (2i 2 )> 0, GbS k (2i 2 -1)> 0, BS k (2i 2 )> 0 In the above case, shading correction may be performed.
また、制御部121は、式(5A)から式(5D)に従って、第k視点画像IkのRGB毎のシェーディング関数RSFk(2i2−1)、GrSFk(2i2)、GbSFk(2i2−1)、BSFk(2i2)を算出する。これらのシェーディング関数は、例えば瞳分割方向(x方向)の位置変数に対する滑らかなNSF次元の多項式関数である。また、上述した、RSk(2i2−1)>0、GrSk(2i2)>0、GbSk(2i2−1)>0、BSk(2i2)>0を満たす有効なシェーディング信号を、これらのシェーディング関数に入力するデータ点とする。 Further, the control unit 121 controls the shading functions RSF k (2i 2 −1), GrSF k (2i 2 ), and GbSF k (2i) of each of the k-th viewpoint images I k according to Equations (5A) to (5D). 2 -1) and BSF k (2i 2 ) are calculated. These shading functions are, for example, polynomial functions in a smooth NSF dimension with respect to position variables in the pupil division direction (x direction). In addition, effective shading signals that satisfy RS k (2i 2 −1)> 0, GrS k (2i 2 )> 0, GbS k (2i 2 −1)> 0, and BS k (2i 2 )> 0 described above Be the data points to be input to these shading functions.
制御部121は、これらデータ点を用いて、例えば最小二乗法によりパラメーターフィッティングを行い、式(5A)から式(5D)の各シェーディング関数の係数RSCk(μ)、GrSCk(μ)、GbSCk(μ)、BSCk(μ)を算出する。このようにして、撮像画像を基準とした相対的な第k視点画像IkのRGB毎のシェーディング関数RSFk(2i2−1)、GrSFk(2i2)、GbSFk(2i2−1)、BSFk(2i2)を生成することができる。シェーディング関数を用いた統計処理により、x方向の位置に応じた統計的なシェーディングの発生傾向に基づいてシェーディング信号を調整することができるため、滑らかなシェーディング補正を行うことができる。 The control unit 121 performs parameter fitting by, for example, the least squares method using these data points, and calculates the coefficients RSC k (μ), GrSC k (μ), GbSC of each shading function of Equations (5A) to (5D). Calculate k (μ) and BSC k (μ). In this manner, the shading functions RSF k (2i 2 −1), GrSF k (2i 2 ), and GbSF k (2i 2 −1) for each RGB of the k-th viewpoint image I k relative to the captured image , BSF k (2i 2 ) can be generated. Since the shading signal can be adjusted on the basis of the statistical shading occurrence tendency according to the position in the x direction by the statistical processing using the shading function, smooth shading correction can be performed.
シェーディング関数RSFk、GrSFk、GbSFk、BSFkを、瞳分割方向(x方向)に反転した関数を、それぞれ、R[RSFk]、R[GrSFk]、R[GbSFk]、R[BSFk]とする。所定許容値をε(0<ε<1)として、1−ε≦RSFk+R[RSFk]≦1+ε、1−ε≦GrSFk+R[GrSFk]≦1+ε、1−ε≦GbSFk+R[GbSFk]≦1+ε、1−ε≦BSFk+R[BSFk]≦1+εの各条件式が、各位置で、全て満たされる場合、検出されたシェーディング関数は適正であると判定し、式(6A)から式(6D)の処理を行う。それ以外の場合、検出されたシェーディング関数は不適正であると判定し、RSFk≡1、GrSFk≡1、GbSFk≡1、BSFk≡1とし、必要に応じて、例外処理を行う。 The functions obtained by inverting the shading functions RSF k , GrSF k , GbSF k , and BSF k in the pupil division direction (x direction) are R [RSF k ], R [GrSF k ], R [GbSF k ], R [ BSF k ]. Assuming that the predetermined allowable value is ε (0 <ε <1), 1−ε ≦ RSF k + R [RSF k ] ≦ 1 + ε, 1−ε ≦ GrSF k + R [GrSF k ] ≦ 1 + ε, 1−ε ≦ GbSF k + R [ If each conditional expression of GbSF k ] ≦ 1 + ε and 1−ε ≦ BSF k + R [BSF k ] ≦ 1 + ε is satisfied at each position, it is judged that the detected shading function is appropriate, and the expression (6A Through equation (6D). In other cases, it is determined that the detected shading function is inappropriate, RSF k ≡ 1, GrSF k ≡ 1, GbSF k 、 1, BSF k例外 1, and exception processing is performed as necessary.
図13(C)に、撮像画像Iを基準とした相対的な第1視点画像I1のRGB毎のシェーディング関数RSF1(R)、GrSF1(G)、GbSF1(G)、BSF1(B)の例を示す。図13(B)に示した第1視点画像の射影信号と、図13(A)に示した撮像画像の射影信号とには、被写体の色に起因した成分と、シェーディング成分とが含まれている。本実施形態では、第1視点画像の射影信号と撮像画像の射影信号の比を求めることによって被写体の色成分を相殺し、射影信号から分離したシェーディング信号に基づいてシェーディング関数を生成する。そのため、第1視点画像I1について、精度のよい、滑らかなシェーディング関数をRGB成分ごとに生成することができる。 13C, the shading functions RSF 1 (R), GrSF 1 (G), GbSF 1 (G), and BSF 1 (for each RGB) of the first viewpoint image I 1 relative to the captured image I are shown. An example of B) is shown. The projection signal of the first viewpoint image shown in FIG. 13 (B) and the projection signal of the captured image shown in FIG. 13 (A) include a component caused by the color of the subject and a shading component. There is. In this embodiment, the color component of the subject is canceled by obtaining the ratio of the projection signal of the first viewpoint image and the projection signal of the captured image, and a shading function is generated based on the shading signal separated from the projection signal. Therefore, the first viewpoint image I 1, it is possible to generate a good accuracy, a smooth shading function for each RGB component.
なお、上述の説明では、シェーディング関数を多項式関数を用いて生成した。しかし、これに限定されることはなく、シェーディングの特性に応じて他の関数を用いてシェーディング関数を生成してもよい。 In the above description, the shading function is generated using a polynomial function. However, the present invention is not limited to this, and other functions may be used to generate a shading function according to the characteristics of shading.
S1−5において、制御部121は、第k視点画像Ik(j,i)に対して、式(6A)から式(6D)に従ってシェーディング補正(輝度補正)を適用する。具体的には、制御部121は、第k視点画像Ik(j,i)の色成分ごとに、対応するシェーディング関数を用いてシェーディング補正処理を適用する。以下、シェーディング補正後の第k視点画像Ikを第k視点(第1修正)画像M1Ikと呼ぶ。 In S1-5, the control unit 121 applies shading correction (brightness correction) to the k-th viewpoint image I k (j, i) according to Expressions (6A) to (6D). Specifically, the control unit 121 applies shading correction processing to each of the color components of the k-th viewpoint image I k (j, i) using a corresponding shading function. Hereinafter, the k-th viewpoint image I k after the shading correction is referred to as a k-th viewpoint (first correction) image M 1 I k .
ここで、ベイヤー配列の第k視点(第1修正)画像M1Ikを、R、Gr、Gb、Bごとに定義する。すなわち、Rの第k視点(第1修正)画像をRM1Ik(2j2−1、2i2−1)=M1Ik(2j2−1、2i2−1)、Grの第k視点(第1修正)画像をGrM1Ik(2j2−1、2i2)=M1Ik(2j2−1、2i2)とする。また、Gbの第k視点(第1修正)画像をGbM1Ik(2j2、2i2−1)=M1Ik(2j2、2i2−1)、Bの第k視点(第1修正)画像をBM1Ik(2j2、2i2)=M1Ik(2j2、2i2)とする。必要に応じて、シェーディング補正後の第k視点(第1修正)画像M1Ik(j,i)を出力画像としてもよい。 Here, the k-th viewpoint (first correction) image M 1 I k of the Bayer array is defined for each of R, Gr, Gb, and B. That is, R k th viewpoint (first correction) image is RM 1 I k ( 2 j 2 -1, 2 i 2 -1) = M 1 I k ( 2 j 2 -1, 2 i 2 -1), Gr k Let the viewpoint (first correction) image be GrM 1 I k (2j 2 -1, 2i 2 ) = M 1 I k (2j 2 -1, 2i 2 ). In addition, the Gb k-th viewpoint (first correction) image is represented by GbM 1 I k (2j 2 , 2i 2 -1) = M 1 I k (2j 2 , 2i 2 -1), and the B-th k-th viewpoint (first Correction) Let the image be BM 1 I k (2j 2 , 2i 2 ) = M 1 I k (2j 2 , 2i 2 ). As necessary, the k-th viewpoint (first correction) image M 1 I k (j, i) after the shading correction may be used as an output image.
このように本実施形態では、撮像画像と視点画像の射影信号を用い、被写体の色成分による信号変化を相殺することにより、RGBごとのシェーディング関数(すなわち瞳ずれによって生じる光量のずれの大きさと位置との関係)を求めるようにした。この際、視点画像の射影信号の信頼性を判定し、信頼性の高い射影信号を用いてシェーディング関数を生成するため、精度の良いシェーディング関数が得られる。補正量取得手段としての制御部121は、シェーディング関数値の逆数をシェーディング補正量(輝度補正量)として生成する。そして、補正手段としての制御部121は、輝度補正量に基づいて視点画像の輝度を補正するシェーディング補正処理を行う。したがって、シェーディング関数の精度の向上により、シェーディング補正の精度も向上する。 As described above, in the present embodiment, by using the projection signals of the captured image and the viewpoint image to offset the signal change due to the color component of the subject, the shading function for each RGB Relationship with). At this time, since the reliability of the projection signal of the viewpoint image is determined and the shading function is generated using the highly reliable projection signal, the shading function with high accuracy can be obtained. The control unit 121 as a correction amount acquisition unit generates the reciprocal of the shading function value as a shading correction amount (brightness correction amount). Then, the control unit 121 as a correction unit performs a shading correction process of correcting the brightness of the viewpoint image based on the brightness correction amount. Therefore, by improving the accuracy of the shading function, the accuracy of the shading correction also improves.
ここで、図14(A)〜図14(C)を参照して、図9のS1に示した第1視点画像I1(j,i)のRGBごとのシェーディング補正処理の効果を説明する。まず、図14(A)は、本実施形態の撮像画像I(デモザイキング後)の例であり、画質品位が良好な撮像画像の例を示している。また、図14(B)は、本実施形態のシェーディング補正前の第1視点画像I1(デモザイキング後)の例を示している。すなわち、上述した結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれによりRGBごとのシェーディングが生じ、図14(B)に示す第1視点画像I1(j,i)では右側の周辺像高において輝度の低下(及びRGB比の変調)が生じている。更に図14(C)は、本実施形態のシェーディング補正後の第1視点(第1修正)画像M1I1(デモザイキング後)の例を示している。すなわち、上述したRGBごとのシェーディング補正により、輝度の低下(及びRGB比の変調)が修正され、撮像画像と同様に、画質品位の良好なシェーディング補正後の第1視点(第1修正)画像M1I1(j,i)が生成される。 Here, with reference to FIGS. 14A to 14C, the effect of the shading correction process for each of the first viewpoint image I 1 (j, i) shown in S1 of FIG. 9 will be described. First, FIG. 14A shows an example of a captured image I (after demosaicing) of the present embodiment, and shows an example of a captured image with high image quality. Further, FIG. 14B shows an example of the first viewpoint image I 1 (after demosaicing) before the shading correction of the present embodiment. That is, shading occurs for each of RGB due to the pupil shift of the exit pupil of the imaging optical system and the entrance pupil of the imaging device described above, and the first viewpoint image I 1 (j, i) shown in FIG. A decrease in luminance (and modulation of the RGB ratio) occurs at the image height. Further, FIG. 14C shows an example of a first viewpoint (first correction) image M 1 I 1 (after demosaicing) after shading correction according to the present embodiment. That is, the reduction in luminance (and modulation of the RGB ratio) is corrected by the above-described shading correction for each RGB, and the first viewpoint (first correction) image M after shading correction with good image quality and quality is the same as in the captured image. 1 I 1 (j, i) is generated.
(視点画像の欠陥補正)
次に、図9のS2で行う、視点画像に対する欠陥補正処理について説明する。本実施形態では、制御部121は、撮像画像Iに基づいて、シェーディング補正後の第k視点(第1修正)画像M1Ikの欠陥補正を行う。本実施形態では、k=1の場合を例に説明する。
(Defect correction of viewpoint image)
Next, defect correction processing for a viewpoint image performed in S2 of FIG. 9 will be described. In the present embodiment, the control unit 121 performs defect correction of the kth viewpoint (first correction) image M 1 I k after shading correction based on the captured image I. In the present embodiment, the case of k = 1 will be described as an example.
撮像素子の回路構成や駆動方式により、転送ゲートの短絡などに起因して、撮像画像Iは正常であるものの、第k視点画像Ik(第1視点画像I1)のごく一部分な信号の欠陥が生じ、点欠陥や線欠陥となる場合がある。このような場合、必要に応じて、量産工程等で検査された点欠陥情報や線欠陥情報を、例えば画像処理回路125等に事前に記録し、記録された点欠陥情報や線欠陥情報を用いて第k視点画像Ik(第1視点画像I1)の欠陥補正処理を行うことができる。また、必要に応じて、第k視点画像Ik(第1視点画像I1)をリアルタイムに検査して点欠陥判定や線欠陥判定を行うことができる。 Although the captured image I is normal due to a short circuit or the like of the transfer gate due to the circuit configuration of the imaging device and the driving method, a defect in a very small part of the k th viewpoint image I k (first viewpoint image I 1 ) May occur, resulting in point defects and line defects. In such a case, if necessary, point defect information and line defect information inspected in a mass production process or the like may be recorded in advance in, for example, the image processing circuit 125 or the like, and the recorded point defect information or line defect information may be used. Thus, defect correction processing of the k-th viewpoint image I k (first viewpoint image I 1 ) can be performed. In addition, point defect determination and line defect determination can be performed by inspecting the k-th viewpoint image I k (first viewpoint image I 1 ) in real time as needed.
以下、S2における欠陥補正処理の例では、第k視点画像Ikには奇数行2jD−1もしくは偶数行2jDの水平方向(x方向)のライン状の線欠陥がある場合であって、撮像画像Iには当該奇数行もしくは偶数行の線欠陥がない場合を例に説明する。 Hereinafter, in the example of the defect correction process in S2, the k-th viewpoint image I k has a linear line defect in the horizontal direction (x direction) in the odd-numbered row 2j D −1 or the even-numbered row 2j D. The case where there is no line defect in the odd-numbered row or even-numbered row in the captured image I will be described as an example.
S2−1において、制御部121は、正常な撮像画像Iを参照画像として用いて、第k視点(第1修正)画像M1Ikの欠陥補正を行う。すなわち、制御部121は、欠陥と判定されていない位置の第k視点(第1修正)画像M1Ikの信号値と、欠陥と判定されていない位置の撮像画像Iの信号値とを比較する。但し、この比較を行う際には、瞳ずれにより生じた第k視点画像IkのRGBごとのシェーディング成分の影響を取り除いたうえで、第k視点画像Ikと撮像画像Iとで、被写体が有するRGBごとの信号成分を正確に比較することが必要である。そのため、S1において生成された第k視点(第1修正)画像M1Ikを用いて、撮像画像Iと同等のシェーディング状態となった第k視点画像を用いる。すなわち、本ステップでは、撮像画像Iを参照画像として用いながら、シェーディング補正された第k視点(第1修正)画像M1Ikに対して高精度な欠陥補正を行う。 In S2-1, the control unit 121 performs defect correction of the k-th viewpoint (first correction) image M 1 I k using the normal captured image I as a reference image. That is, the control unit 121 compares the signal value of the kth viewpoint (first corrected) image M 1 I k at a position not determined to be a defect with the signal value of the captured image I at a position not determined to be a defect. Do. However, when performing this comparison, after removing the influence of the shading component for each RGB of the k-th viewpoint image I k generated by the pupil shift, the subject is the k-th viewpoint image I k and the captured image I It is necessary to exactly compare the signal components for each of the RGB that it has. Therefore, using the k-th viewpoint (first correction) image M 1 I k generated in S1, the k-th viewpoint image in a shading state equivalent to the captured image I is used. That is, in this step, defect correction with high accuracy is performed on the shading-corrected k th viewpoint (first correction) image M 1 I k using the captured image I as a reference image.
制御部121は、シェーディング補正後の第k視点(第1修正)画像M1Ik(j,i)のごく一部で欠陥と判定された信号に対して、撮像画像Iの正常信号と、第k視点(第1修正)画像M1Ikの正常信号とを用いる。なお、欠陥補正処理により生成される画像を第k視点(第2修正)画像M2Ik(j,i)とする。ここで、ベイヤー配列の第k視点(第2修正)画像M2Ikを、R、Gr、Gb、Bごとに定義する。すなわち、Rの第k視点(第2修正)画像をRM2Ik(2j2−1、2i2−1)=M2Ik(2j2−1、2i2−1)、Grの第k視点(第2修正)画像をGrM2Ik(2j2−1、2i2)=M2Ik(2j2−1、2i2)とする。また、Gbの第k視点(第2修正)画像をGbM2Ik(2j2、2i2−1)=M2Ik(2j2、2i2−1)、Bの第k視点(第2修正)画像をBM2Ik(2j2、2i2)=M2Ik(2j2、2i2)とする。 The control unit 121 transmits a normal signal of the captured image I to a signal determined as a defect in a very small part of the k-th viewpoint (first correction) image M 1 I k (j, i) after the shading correction. The normal signal of the k th viewpoint (first correction) image M 1 I k is used. An image generated by the defect correction process is a k-th viewpoint (second correction) image M 2 I k (j, i). Here, the k-th viewpoint (second correction) image M 2 I k of the Bayer array is defined for each of R, Gr, Gb, and B. That is, R k th viewpoint (second correction) image is RM 2 I k ( 2 j 2 -1, 2 i 2 -1) = M 2 I k ( 2 j 2 -1, 2 i 2 -1), Gr k The viewpoint (second correction) image is set to GrM 2 I k (2j 2 -1, 2i 2 ) = M 2 I k (2j 2 -1, 2i 2 ). In addition, the Gb k-th viewpoint (second correction) image is represented by GbM 2 I k (2j 2 , 2i 2 -1) = M 2 I k (2j 2 , 2i 2 -1) and the B-th k-th viewpoint (second Correction) Let the image be BM 2 I k (2j 2 , 2i 2 ) = M 2 I k (2j 2 , 2i 2 ).
制御部121は、第k視点(第1修正)画像M1IkのRの第1位置(2jD−1、2iD−1)が欠陥と判定された場合、式(7A)に従う演算を行って、第1位置における第k視点(第2修正)画像RM2Ik(2jD−1、2iD−1)を生成する。式(7A)の演算には、第1位置の撮像画像RI(2jD−1、2iD−1)と、欠陥と判定されていないRの第2位置の第k視点(第1修正)画像RM1Ikと、第2位置の撮像画像RIとを用いる。 Control unit 121, when the first position of the R of the k-th viewpoint (first modification) image M 1 I k (2j D -1,2i D -1) is determined as a defect, the operation according to the formula (7A) go and generates a k-th viewpoint in the first position (second correction) image RM 2 I k (2j D -1,2i D -1). The calculation of the equation (7A), a captured image RI of the first position (2j D -1,2i D -1), the k viewpoint (first modification) of the second position of the R which are not determined as defective image The RM 1 I k and the captured image RI at the second position are used.
また、第k視点(第1修正)画像M1IkのGrの第1位置(2jD−1、2iD)が欠陥と判定された場合、式(7B)に従う演算を行い、第1位置における欠陥補正後の第k視点(第2修正)画像GrM2Ik(2jD−1、2iD)を生成する。さらに、第k視点(第1修正)画像M1IkのGb及びBについても同様に、それぞれ式(7C)及び式(7D)に従って欠陥補正後の視点画像を生成する。 Also, if it is determined that the first position (2j D -1, 2i D ) of Gr of the k-th viewpoint (first correction) image M 1 I k is a defect, calculation according to equation (7B) is performed, and the first position The second correction image GrM 2 I k (2j D −1, 2i D ) is generated after the defect correction in. Furthermore, similarly, with regard to Gb and B of the k-th viewpoint (first correction) image M 1 I k , viewpoint images after defect correction are generated according to Equations (7C) and (7D), respectively.
欠陥と判定されていない大部分の位置(j,i)では、第k視点(第2修正)画像M2Ik(j,i)が第k視点(第1修正)画像M1Ik(j,i)と同一(又は略同一)の信号値、すなわちM2Ik(j,i)=M1Ik(j,i)である。なお、必要に応じて、欠陥補正後の第k視点(第2修正)画像M2Ik(j,i)を出力画像としてもよい。 At most positions (j, i) not determined as defects, the k-th viewpoint (second correction) image M 2 I k (j, i) is the k-th viewpoint (first correction) image M 1 I k ( The same (or substantially the same) signal value as j, i), that is, M 2 I k (j, i) = M 1 I k (j, i). Note that, as necessary, the k-th viewpoint (second correction) image M 2 I k (j, i) after defect correction may be used as an output image.
さらに、図15(A)および図15(B)を参照して、上述した欠陥補正処理の効果を説明する。図15(A)は、上述した欠陥補正前の第1視点(第1修正)画像M1I1の例を示す。なお、本画像は、シェーディング補正処理およびデモザイキング処理が施されている。この例は、第1視点(第1修正)画像M1I1(j,i)の中央部に、水平方向(x方向)のライン状の線欠陥が生じている場合を示している。一方、図15(B)は、上述した欠陥補正後の第1視点(第2修正)画像M2I1(シェーディング補正後、デモザイキング後)の例を示している。正常な撮像画像Iに基づく欠陥補正により、水平方向(x方向)のライン状の線欠陥が修正され、撮像画像と同様に、画質品位が良好になっている。 Further, the effects of the above-described defect correction processing will be described with reference to FIGS. 15 (A) and 15 (B). FIG. 15A illustrates an example of the first viewpoint (first correction) image M 1 I 1 before the above-described defect correction. The main image is subjected to shading correction processing and demosaicing processing. This example shows the case where a line-shaped line defect in the horizontal direction (x direction) is generated at the central portion of the first viewpoint (first corrected) image M 1 I 1 (j, i). On the other hand, FIG. 15B shows an example of the first viewpoint (second correction) image M 2 I 1 (after demosaicing, after demosaicing) after the above-described defect correction. By the defect correction based on the normal captured image I, the line-like line defect in the horizontal direction (x direction) is corrected, and the image quality is good as in the captured image.
本実施形態では、欠陥と判定された第1位置における視点画像の信号値を、第1位置における撮像画像の信号値と、欠陥と判定されていない第2位置における視点画像および撮像画像の信号値とに基づいて補正する。この際、シェーディング補正(輝度補正)された視点画像の信号値を用いるようにしたので、視点画像の補正精度を高めることができる。 In the present embodiment, the signal value of the viewpoint image at the first position determined to be a defect, the signal value of the captured image at the first position, and the signal values of the viewpoint image and the captured image at the second position not determined to be a defect Make corrections based on At this time, since the signal value of the viewpoint image subjected to shading correction (brightness correction) is used, the correction accuracy of the viewpoint image can be enhanced.
さらに、制御部121は、S2−2において、欠陥補正後の第k視点(第2修正)画像M2Ik(j,i)に対して、式(8A)から式(8D)に従ったシェーディング処理を行い、第k視点(第3修正)画像M3Ik(j,i)を生成する。ここで、ベイヤー配列の第k視点(第3修正)画像M3Ikを、R、Gr、Gb、Bごとに定義する。すなわち、Rの第k視点(第3修正)画像をRM3Ik(2j2−1、2i2−1)=M3Ik(2j2−1、2i2−1)、Grの第k視点(第3修正)画像をGrM3Ik(2j2−1、2i2)=M3Ik(2j2−1、2i2)とする。また、Gbの第k視点(第3修正)画像をGbM3Ik(2j2、2i2−1)=M3Ik(2j2、2i2−1)、Bの第k視点(第3修正)画像をBM3Ik(2j2、2i2)=M3Ik(2j2、2i2)とする。 Furthermore, in step S2-2, the control unit 121 follows the equations (8A) to (8D) with respect to the defect-corrected k-th (second) image M 2 I k (j, i). Shading processing is performed to generate a k-th ( third ) corrected image M 3 I k (j, i). Here, the k-th viewpoint (third correction) image M 3 I k of the Bayer array is defined for each of R, Gr, Gb, and B. That is, the k th viewpoint (third correction) image of R is RM 3 I k ( 2 j 2 -1, 2 i 2 -1) = M 3 I k ( 2 j 2 -1, 2 i 2 -1), Gr k Let the viewpoint (third correction) image be GrM 3 I k (2j 2 -1, 2i 2 ) = M 3 I k (2j 2 -1, 2i 2 ). In addition, the Gb k-th viewpoint (third correction) image is represented by GbM 3 I k (2j 2 , 2i 2 -1) = M 3 I k (2j 2 , 2i 2 -1), and the B-th k-th viewpoint (third Correction) Let the image be BM 3 I k (2j 2 , 2i 2 ) = M 3 I k (2j 2 , 2i 2 ).
S3において、撮像画像I(j,i)と、第k視点(第3修正)画像M3Ik(j,i)に対して、飽和信号処理を行う。本実施形態では、k=1、NLF=2である場合を例に説明する。 In S3, saturation signal processing is performed on the captured image I (j, i) and the k-th viewpoint (third corrected) image M 3 I k (j, i). In the present embodiment, the case where k = 1 and N LF = 2 will be described as an example.
まず、S3−1において、制御部121は、撮像画像I(j,i)に対する飽和信号処理を行う。すなわち、式(9)に従い、撮像信号の最大値をImaxとする飽和信号処理を行って、修正撮像画像MI(j,i)を生成する。ここで、撮像信号の最大値Imaxと、撮像信号の飽和判定閾値ISは、Imax≧ISを満たす。 First, in S3-1, the control unit 121 performs saturation signal processing on the captured image I (j, i). That is, according to the equation (9), saturation signal processing is performed with the maximum value of the imaging signal as Imax to generate a corrected captured image MI (j, i). Here, the maximum value Imax of the imaging signal and the saturation determination threshold IS of the imaging signal satisfy Imax ≧ IS.
次に、S3−2において、制御部121は、第k視点(第3修正)画像M3Ik(j,i)に対する飽和信号処理を行う。すなわち、式(10)に従い、ベイヤー配列のシェーディング関数をSFk(j,i)としたシェーディング状態に合わせた飽和信号処理を行い、第k視点(第4修正)画像M4Ik(j,i)を生成する。ここで、ベイヤー配列のシェーディング関数SFk(j,i)を、式(5A)から式(5D)により、R、Gr、Gb、Bごとに生成されたシェーディング関数RSFk(2i2−1)、GrSFk(2i2)、GbSFk(2i2−1)、BSFk(2i2)から、SFk(2j2−1、2i2−1)=RSFk(2i2−1)、SFk(2j2−1、2i2)=GrSFk(2i2)、SFk(2j2、2i2−1)=GbSFk(2i2−1)、SFk(2j2、2i2)=BSFk(2i2)とする。 Next, in step S3-2, the control unit 121 performs saturation signal processing on the k-th viewpoint (third corrected) image M 3 I k (j, i). That is, saturation signal processing is performed according to the shading state in which the shading function of the Bayer array is SF k (j, i) according to the equation (10), and the k th viewpoint (fourth correction) image M 4 I k (j, i) Generate. Here, the shading function RSF k (2i 2 −1) generated for each of R, Gr, Gb, and B by the shading function SF k (j, i) of the Bayer array is expressed by Expression (5A) to Expression (5D) , GrSF k (2i 2), GbSF k (2i 2 -1), the BSF k (2i 2), SF k (2j 2 -1,2i 2 -1) = RSF k (2i 2 -1), SF k (2j 2 -1, 2i 2 ) = GrSF k (2i 2 ), SF k (2j 2 , 2i 2 -1) = GbSF k (2i 2 -1), SF k (2j 2 , 2i 2 ) = BSF k (2i 2 )
次に、S4−1において、制御部121は、S3−1で生成された修正撮像画像MI(j,i)と、S3−2で生成された第1視点(第4修正)画像M4I1(j,i)から、式(11)に従って第2視点画像I2(j,i)を生成する。 Next, in S4-1, the control unit 121 causes the corrected captured image MI (j, i) generated in S3-1 and the first viewpoint (fourth correction) image M 4 I generated in S3-2. From 1 (j, i), a second viewpoint image I 2 (j, i) is generated according to equation (11).
なお、撮像素子の駆動方式やA/D変換の回路構成によっては、第1視点(第3修正)画像M3I1(j,i)の飽和時の最大信号値が、撮像画像I(j,i)の飽和時の最大信号値Imaxと、同一の最大信号値となる場合がある。このような場合に、飽和信号処理を行うことなく、式(11)を適用して撮像画像から第1視点(第3修正)画像を減算すると、生成される第2視点画像において飽和信号値となるべきところが誤った信号値0となる場合がある。このような動作を防止するため、S3では、撮像画像I(j,i)と第k視点(第3修正)画像M3Ik(j,i)に対して予めシェーディング状態に合わせた飽和信号処理を行う。このようにして、飽和信号処理後の修正撮像画像MI(j,i)と第1視点(第4修正)画像M4I1(j,i)を生成する。S4−1では、式(11)に従って第2視点画像I2(j,i)を生成することにより、より正しい飽和信号値に対応した第2視点画像I2を生成することができる。 Note that the maximum signal value at the time of saturation of the first viewpoint (third correction) image M 3 I 1 (j, i) depends on the driving method of the imaging device and the circuit configuration of A / D conversion. , I) may become the same maximum signal value as the maximum signal value Imax at the time of saturation. In such a case, when the first viewpoint (third correction) image is subtracted from the captured image by applying the equation (11) without performing the saturation signal processing, a saturation signal value is generated in the second viewpoint image to be generated. What should be done may be a false signal value of zero. In order to prevent such an operation, in S3, a saturated signal previously adjusted to the shading state for the captured image I (j, i) and the k-th viewpoint (third correction) image M 3 I k (j, i) Do the processing. Thus, the corrected captured image MI (j, i) after the saturation signal processing and the first viewpoint (fourth corrected) image M 4 I 1 (j, i) are generated. In S4-1, by generating the second viewpoint image I 2 (j, i) according to Equation (11), it is possible to generate a second viewpoint image I 2 corresponding to a more correct saturation signal value.
S5では、制御部121は、第1視点(第4修正)画像M4I1(j,i)と、第2視点画像I2(j,i)に対して、それぞれシェーディング補正を行う。S5−1では、第1視点(第4修正)画像M4I1(j,i)に対して、式(5A)から式(5D)に従って生成済みのシェーディング関数RSF1、GrSF1、GbSF1、BSF1を適用する。そして、式(6A)から式(6D)に従って、シェーディング補正処理を行う。なお、このとき第1視点(第5修正)画像M5I1(j,i)が生成される。 In S5, the control unit 121 performs shading correction on the first viewpoint (fourth corrected) image M 4 I 1 (j, i) and the second viewpoint image I 2 (j, i). In S5-1, the shading functions RSF 1 , GrSF 1 , GbSF 1 that have been generated according to Equations (5A) to (5D) for the first viewpoint (fourth corrected) image M 4 I 1 (j, i) Apply BSF 1 . Then, the shading correction process is performed according to the equations (6A) to (6D). At this time, the first viewpoint (fifth correction) image M 5 I 1 (j, i) is generated.
次に、S5−2において、制御部121は、第2視点画像I2(j,i)に対して、式(3A)から式(6D)と同様に、修正撮像画像MI(j,i)に基づくシェーディング補正処理を行って、第2視点(第5修正)画像M5I2(j,i)を生成する。なお、第2視点画像I2の射影信号についても、第1視点画像I1の射影信号と同様に有効性判定を行い、信頼性の高い射影信号を用いてシェーディング関数を生成する。 Next, in S5-2, the control unit 121 applies the modified captured image MI (j, i) to the second viewpoint image I 2 (j, i) in the same manner as in the equations (3A) to (6D). Shading correction processing is performed to generate a second viewpoint (fifth correction) image M 5 I 2 (j, i). Here, also for the second viewpoint projection signal of the image I 2, similarly to the projection signal of the first viewpoint image I 1 performs validity determination, generates a shading function with reliable projection signal.
次に、S6では、制御部121は、第1視点(第5修正)画像M5I1(j,i)と、第2視点(第5修正)画像M5I2(j,i)に対して、それぞれ飽和信号処理を行う。S6−1では、第1視点(第5修正)画像M5I1(j,i)に対して、式(12)に従って飽和信号処理を行い、修正第1視点画像MI1(j,i)を生成する。一方、S6−2では、第2視点(第5修正)画像M5I2(j,i)に対して、式(12)に従って飽和信号処理を行い、修正第2視点画像MI2(j,i)を生成する。ここで、第k視点画像の最大値Imax/NLFと、第k視点画像の飽和判定閾値ISkは、Imax/NLF≧ISkを満たす。 Next, in S6, the control unit 121 sets the first viewpoint (fifth correction) image M 5 I 1 (j, i) and the second viewpoint (fifth correction) image M 5 I 2 (j, i) On the other hand, saturation signal processing is performed respectively. In S6-1, saturation signal processing is performed on the first viewpoint (fifth corrected) image M 5 I 1 (j, i) according to equation (12), and the corrected first viewpoint image MI 1 (j, i) Generate On the other hand, in S6-2, saturation signal processing is performed on the second viewpoint (fifth corrected) image M 5 I 2 (j, i) according to equation (12), and the corrected second viewpoint image MI 2 (j, i) Generate. Here, the maximum value Imax / N LF k-th viewpoint image, the saturation determination threshold value IS k of the k viewpoint image satisfies Imax / N LF ≧ IS k.
以下、図16(A)および図16(B)を参照して、S5に示した第2視点画像I2(j,i)に対するRGBごとのシェーディング補正処理の効果について説明する。図16(A)は、シェーディング補正前の第2視点画像I2(デモザイキング後)の例を示している。この例では、結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれによってRGBごとのシェーディングが生じているため、第2視点画像I2(j,i)の左側では、輝度の低下(およびRGB比の変調)が生じている。一方、図16(B)は、本実施形態に係るシェーディング補正後の修正第2視点画像MI2(デモザイキング後)の例を示している。この例では、撮像画像に基づいたRGBごとのシェーディング補正により、輝度の低下(およびRGB比の変調)が修正され、撮像画像と同様に、画質品位が良好な修正第2視点画像MI2(j,i)が生成されている。 Hereinafter, with reference to FIGS. 16A and 16B, the effect of the shading correction process for each of the RGB with respect to the second viewpoint image I 2 (j, i) shown in S5 will be described. FIG. 16A shows an example of the second viewpoint image I 2 (after demosaicing) before the shading correction. In this example, since the shading for each of RGB occurs due to the pupil shift of the exit pupil of the imaging optical system and the entrance pupil of the imaging device, the luminance decreases on the left side of the second viewpoint image I 2 (j, i) And modulation of the RGB ratio). On the other hand, FIG. 16B shows an example of a corrected second viewpoint image MI 2 (after demosaicing) after shading correction according to the present embodiment. In this example, the reduction in luminance (and the modulation of the RGB ratio) is corrected by the shading correction for each RGB based on the captured image, and the corrected second viewpoint image MI 2 (j (j , I) are generated.
最後に、制御部121は、修正第1視点画像MI1(j,i)および修正第2視点画像MI2(j,i)のそれぞれを出力する。あるいは、制御部121は、修正第1視点画像MI1(j,i)および修正第2視点画像MI2(j,i)を1枚に合成した合成画像を出力する。 Finally, the control unit 121 outputs each of the corrected first viewpoint image MI 1 (j, i) and the corrected second viewpoint image MI 2 (j, i). Alternatively, the control unit 121 outputs a combined image in which the corrected first viewpoint image MI 1 (j, i) and the corrected second viewpoint image MI 2 (j, i) are combined into one.
このように、本実施形態では、第1視点画像および第2視点画像に対し、撮像画像と視点画像とを用いて生成したシェーディング関数に基づくシェーディング補正を適用するようにした。その際、視点画像の射影信号に対して信頼性判定を行い、信頼性の高い射影信号を用いてシェーディング関数を生成することにより、精度の良いシェーディング関数を生成することができ、視点画像に対するシェーディング補正の精度を高めることができる。 As described above, in the present embodiment, the shading correction based on the shading function generated using the captured image and the viewpoint image is applied to the first viewpoint image and the second viewpoint image. At that time, by performing the reliability determination on the projection signal of the viewpoint image and generating the shading function using the highly reliable projection signal, it is possible to generate the shading function with high accuracy, and the shading on the viewpoint image The accuracy of the correction can be increased.
(位相差方式の焦点検出処理)
次に、第1視点画像と第2視点画像(第1〜第NLF視点画像)から、第1視点画像と第2視点画像の相関(信号の一致度)に基づき、位相差方式によりデフォーカス量を検出する焦点検出処理について説明する。なお、以下の説明では、制御部121が処理を実行する例を説明するが、画像処理回路125が実行してもよい。
(Focus detection process of phase difference method)
Next, from the first viewpoint image and the second viewpoint image (first to Nth LF viewpoint images), defocusing is performed by the phase difference method based on the correlation (degree of signal coincidence) of the first viewpoint image and the second viewpoint image. The focus detection process for detecting an amount will be described. In the following description, an example in which the control unit 121 executes a process will be described, but the image processing circuit 125 may execute it.
まず、制御部121は、ベイヤー配列のRGB信号である第k視点画像Ik(k=1〜NLF)から、位置(j,i)ごとに、各色RGBの色重心を一致させて、第k視点輝度信号Ykを、式(13)に従って生成する。 First, from the k-th viewpoint image Ik (k = 1 to N LF ), which is a RGB signal of Bayer arrangement, the control unit 121 matches the color centers of RGB of each color for each position (j, i). The viewpoint luminance signal Yk is generated according to equation (13).
次に、制御部121は、式(14)に従って、第k視点輝度信号Yk(k=1〜NLF)のシェーディング補正量Sk(i)を、瞳分割方向(x方向)の位置iに対する滑らかなNS次の多項式関数として算出する。撮像素子107の光学特性(第k副画素ごとの瞳強度分布)と、結像光学系の光学特性(絞り値F、射出瞳距離Dl)に基づき、予め、各係数SCk(μ|F、Dl)を算出し、不図示のROM等へ保存しておく。 Next, the control unit 121 sets the shading correction amount S k (i) of the k-th viewpoint luminance signal Y k (k = 1 to N LF ) to the position i in the pupil division direction (x direction) according to equation (14). It is calculated as a smooth N S-order polynomial function. Each coefficient SC k (μ | F, based on the optical characteristic of the image sensor 107 (pupil intensity distribution for each k th sub-pixel) and the optical characteristic of the imaging optical system (diaphragm value F, exit pupil distance D1) Calculate Dl) and save it in a ROM not shown.
さらに、制御部121は、第k視点輝度信号Yk(j,i)に対して、式(15)に従って、シェーディング補正量Sk(i)を用いたシェーディング補正処理を行い、第k修正視点輝度信号MYk(j,i)を生成する。 Furthermore, the control unit 121 performs a shading correction process on the kth viewpoint luminance signal Yk (j, i) using the shading correction amount S k (i) according to the equation (15) Generate signal MYk (j, i).
制御部121は、生成された第1修正視点輝度信号MY1に対して、瞳分割方向(水平方向)に、1次元バンドパスフィルター処理を行い、第1焦点検出信号dYAを生成する。同様に、第2修正視点輝度信号MY2に対して、瞳分割方向(水平方向)に、1次元バンドパスフィルター処理を行い、第2焦点検出信号dYBを生成する。なお、1次元バンドパスフィルターとしては、例えば、1次微分型フィルター[1、5、8、8、8、8、5、1、−1、−5、−8、−8、−8、−8、−5、−1]などを用いることができる。必要に応じて、1次元バンドパスフィルターの通過帯域を調整してもよい。 Control unit 121, to the first modification viewpoint luminance signal MY 1 produced, in the pupil division direction (horizontal direction), the one-dimensional band-pass filter process to generate a first focus detection signal Dya. Similarly, the second modified viewpoint luminance signal MY 2, the pupil division direction (horizontal direction), the one-dimensional band-pass filter process to generate a second focus detection signal DYB. In addition, as a one-dimensional band pass filter, for example, first derivative filters [1, 5, 8, 8, 8, 8, 5, 1 -1, -5, -8, -8, -8,- 8, -5, -1] and the like can be used. If necessary, the pass band of the one-dimensional band pass filter may be adjusted.
次に、制御部121は、第1焦点検出信号dYAと第2焦点検出信号dYBを、相対的に瞳分割方向(水平方向)にシフトさせて、信号の一致度を表す相関量を算出し、算出した相関量に基づいて像ずれ量MDISを生成する。 Next, the control unit 121 relatively shifts the first focus detection signal dYA and the second focus detection signal dYB in the pupil division direction (horizontal direction) to calculate a correlation amount representing the degree of signal coincidence. The image shift amount M DIS is generated based on the calculated correlation amount.
例えば、焦点検出位置(jAF、iAF)を中心として、垂直方向j2番目、瞳分割方向である水平方向i2番目の第1焦点検出信号をdYA(jAF+j2、iAF+i2)、第2焦点検出信号をdYB(jAF+j2、iAF+i2)とする。但し、j2は−n2≦j2≦n2、i2は−m2≦i2≦m2である。さらに、シフト量をs(−ns≦s≦ns)とすると、各位置(jAF,iAF)での相関量COREVEN(jAF,iAF、s)および相関量CORODD(jAF,iAF、s)は、それぞれ式(16A)および式(16B)により算出することができる。 For example, focus detection position (j AF, i AF) around a second vertical j, horizontal i 2 th first focus detection signal dYA a pupil division direction (j AF + j 2, i AF + i 2 And the second focus detection signal is dYB (j AF + j 2 , i AF + i 2 ). However, j 2 is −n 2 ≦ j 2 ≦ n 2 , and i 2 is −m 2 ≦ i 2 ≦ m 2 . Furthermore, assuming that the shift amount is s (−ns s s n s ), the correlation amount COR EVEN (j AF , i AF , s) at each position (j AF , i AF ) and the correlation amount COR ODD (j AF 1 , i AF , s) can be calculated by Equation (16A) and Equation (16B), respectively.
なお、相関量CORODD(jAF,iAF、s)は、相関量COREVEN(jAF,iAF、s)に対して、第1焦点検出信号dYAと第2焦点検出信号dYBのシフト量を半位相−1シフトずらした相関量である。 The correlation amount COR ODD (j AF , i AF , s) is a shift amount between the first focus detection signal dYA and the second focus detection signal dYB with respect to the correlation amount COR EVEN (j AF , i AF , s) By a half phase minus one shift.
制御部121は、相関量COREVEN(jAF,iAF、s)と相関量CORODD(jAF,iAF、s)から、それぞれ、サブピクセル演算を行って、相関量が最小値となる実数値のシフト量を算出する。さらに、算出したシフト量の平均値を算出し、焦点検出位置(jAF、iAF)における像ずれ量Dis(jAF、iAF)を検出する。 The control unit 121 performs the sub-pixel calculation from the correlation amount COR EVEN (j AF , i AF , s) and the correlation amount COR ODD (j AF , i AF , s), and the correlation amount becomes the minimum value. Calculate the shift amount of real numbers. Furthermore, an average value of the calculated shift amount, focus detection position (j AF, i AF) image shift in weight Dis (j AF, i AF) detected.
次に、制御部121は、像ずれ量からデフォーカス量への変換係数Kを、焦点検出領域の像高位置ごとに像ずれ量Dis(jAF、iAF)に乗算し、各焦点検出位置(jAF、iAF)におけるデフォーカス量MDef(jAF、iAF)を検出する。なお、変換係数Kは、例えば、撮像素子の光学特性(第k副画素ごとの瞳強度分布)およびレンズ情報(結像光学系の絞り値F、射出瞳距離Dlなど)に応じて算出し、不図示のROMへ保存しておく。 Next, the control unit 121 multiplies the image shift amount Dis (j AF , i AF ) for each image height position of the focus detection area by converting the image shift amount K from the image shift amount to the defocus amount, and detects each focus detection position (j AF, i AF) defocus amount M Def (j AF, i AF ) in detecting the. The conversion coefficient K is calculated according to, for example, the optical characteristics of the image pickup element (pupil intensity distribution for each k th subpixel) and lens information (the aperture value F of the imaging optical system, the exit pupil distance Dl, etc.) Save to ROM not shown.
最後に、制御部121は、焦点検出位置(jAF、iAF)で検出されたデフォーカス量MDef(jAF、iAF)に応じて合焦位置にレンズを駆動して、焦点検出処理を終了する。 Finally, the control unit 121 drives the lens to the in-focus position according to the defocus amount M Def (j AF , i AF ) detected at the focus detection position (j AF , i AF ) to perform focus detection processing. Finish.
第1視点画像と第2視点画像(複数の視点画像)を用いて、自動焦点検出を行う場合、応答性に優れたリアルタイム処理の自動焦点検出を行うために、高速なシェーディング補正が必要となる場合がある。そのため、本実施形態では、自動焦点検出を行う場合には、不図示のROM等に保存されている、予め算出されたシェーディング補正関連データを用いて高速にシェーディング補正を行うようにしてもよい。このようにすれば、良好な信号品質の位相差方式の焦点検出信号を用いることができ、精度が高く、応答性に優れた自動焦点検出を実現することができる。なお、シェーディング補正関連データは、撮像素子の光学特性(第k副画素ごとの瞳強度分布)と結像光学系の光学特性(絞り値F、射出瞳距離Dl)とに基づき算出することができる。この場合、自動焦点検出を行う際には、特定の視点画像(例えば第1視点画像)についてのみシェーディング補正を適用し、より高速な自動焦点検出を行うようにしてもよい。 When performing automatic focus detection using the first viewpoint image and the second viewpoint image (a plurality of viewpoint images), high-speed shading correction is required to perform automatic focus detection in real time processing with excellent responsiveness. There is a case. Therefore, in the present embodiment, when automatic focus detection is performed, shading correction may be performed at high speed using shading correction related data calculated in advance and stored in a ROM (not shown) or the like. In this way, it is possible to use a phase difference type focus detection signal of good signal quality, and it is possible to realize automatic focus detection with high accuracy and excellent response. The shading correction related data can be calculated based on the optical characteristic of the image pickup element (pupil intensity distribution for each k th subpixel) and the optical characteristic of the imaging optical system (aperture value F, exit pupil distance Dl) . In this case, when automatic focus detection is performed, shading correction may be applied only to a specific viewpoint image (for example, a first viewpoint image) to perform automatic focus detection at higher speed.
本実施形態は、画質品位が良好な視点画像、もしくは、これらの合成画像を画像出力する際は、撮像画像に基づいて、高精度なRGB毎のシェーディング補正を行う。一方、優れた応答性が要求されるリアルタイム処理の自動焦点検出の際は、シェーディング補正方法を切り換え、予め、算出され、記録媒体に保存されたシェーディング補正関連データによる高速なシェーディング補正を行う例を説明した。これにより、画質品位が良好な視点画像の画像出力と、応答性に優れた高精度な自動焦点検出を、両立することができる。 In the present embodiment, when outputting a viewpoint image having a high image quality or a composite image of these, an accurate shading correction for each RGB is performed based on a captured image. On the other hand, in the case of automatic focus detection in real-time processing where excellent responsiveness is required, an example of switching shading correction methods and performing high-speed shading correction using shading correction related data calculated in advance and stored on a recording medium explained. As a result, it is possible to achieve both image output of a viewpoint image with high image quality and high-accuracy automatic focus detection with excellent responsiveness.
以上説明したように、単位画素内の光電変換部を分割した構造の撮像素子から得られるLFデータに基づいて撮像画像と視点画像を生成し、これらの画像に基づき視点画像に対するシェーディング(光量分布の偏り)を補正するようにした。さらに、シェーディング補正のなされた視点画像を用いて欠陥画素を補正するようにした。このようにすることで、良好な画質品位の視点画像を生成することができる。換言すれば、LFデータを用いる場合に、生成される視点画像の光量の変動を低減することができるようになる。 As described above, the captured image and the viewpoint image are generated on the basis of the LF data obtained from the imaging device having a structure in which the photoelectric conversion unit in the unit pixel is divided, and shading on the viewpoint image Bias) was corrected. Furthermore, defective pixels are corrected using a viewpoint image that has been subjected to shading correction. By doing this, it is possible to generate a viewpoint image of good image quality. In other words, when using the LF data, it is possible to reduce the fluctuation of the light amount of the generated viewpoint image.
本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。 The present invention supplies a program that implements one or more functions of the above-described embodiments to a system or apparatus via a network or storage medium, and one or more processors in a computer of the system or apparatus read and execute the program. Can also be realized. It can also be implemented by a circuit (eg, an ASIC) that implements one or more functions.
107…撮像素子、121…制御部、125…画像処理回路 107: Imaging device, 121: Control unit, 125: Image processing circuit
Claims (11)
前記視点画像の輝度補正量を、前記視点画像および前記撮像画像を用いて取得する補正量取得手段と、
前記輝度補正量に基づいて前記視点画像の輝度を補正する補正手段と、
を有する画像処理装置であって、
前記補正量取得手段は、
前記撮像画像および前記視点画像それぞれの射影信号を生成する射影手段と、
前記視点画像の射影信号の有効性を判定する判定手段と、
前記視点画像の射影信号のうち、前記判定手段に有効と判定された射影信号と、前記撮像画像の射影信号とを用いて前記輝度補正量を生成する生成手段と、
を有することを特徴とする画像処理装置。 Among the pupil regions of the imaging optical system, viewpoint images generated from signals obtained by partial photoelectric conversion units of a plurality of photoelectric conversion units that receive light beams passing through different partial regions, and all photoelectric conversion units Image acquisition means for acquiring a captured image generated from the signal obtained by
Correction amount acquisition means for acquiring the luminance correction amount of the viewpoint image using the viewpoint image and the captured image;
Correction means for correcting the brightness of the viewpoint image based on the brightness correction amount;
An image processing apparatus having
The correction amount acquisition unit
Projection means for generating projection signals of the captured image and the viewpoint image;
A determination unit that determines the validity of the projection signal of the viewpoint image;
Generation means for generating the luminance correction amount using a projection signal determined to be effective by the determination means among projection signals of the viewpoint image, and a projection signal of the captured image;
An image processing apparatus comprising:
前記判定手段は、前記視点画像の前記射影方向に並んだ複数の画素の値に基づく評価値を、閾値と比較することにより、該信号の有効性を判定する、
ことを特徴とする請求項1に記載の画像処理装置。 The projection unit projects the captured image and the viewpoint image in a predetermined projection direction to generate a one-dimensional projection signal.
The determination means determines the validity of the signal by comparing an evaluation value based on the values of a plurality of pixels aligned in the projection direction of the viewpoint image with a threshold.
The image processing apparatus according to claim 1,
前記複数の光電変換部を備わる画素が複数配列された撮像素子と、
を有することを特徴とする撮像装置。 An image processing apparatus according to any one of claims 1 to 8.
An imaging device in which a plurality of pixels including the plurality of photoelectric conversion units are arranged;
An imaging apparatus characterized by having:
結像光学系の瞳領域のうち、異なる部分領域を通過する光束を受光する複数の光電変換部の、一部の光電変換部で得られる信号から生成される視点画像と、全部の光電変換部で得られる信号から生成される撮像画像とを取得する画像取得工程と、
前記視点画像の輝度補正量を、前記視点画像および前記撮像画像を用いて取得する補正量取得工程と、
前記輝度補正量に基づいて前記視点画像の輝度を補正する補正工程と、
を有し、
前記補正量取得工程は、
前記撮像画像および前記視点画像それぞれの射影信号を生成する射影工程と、
前記視点画像の射影信号の有効性を判定する判定工程と、
前記視点画像の射影信号のうち、前記判定工程で有効と判定された射影信号と、前記撮像画像の射影信号とを用いて前記輝度補正量を生成する生成工程と、
を有することを特徴とする画像処理方法。 An image processing method performed by an image processing apparatus, comprising:
Among the pupil regions of the imaging optical system, viewpoint images generated from signals obtained by partial photoelectric conversion units of a plurality of photoelectric conversion units that receive light beams passing through different partial regions, and all photoelectric conversion units An image acquisition step of acquiring a captured image generated from a signal obtained by
A correction amount acquisition step of acquiring a luminance correction amount of the viewpoint image using the viewpoint image and the captured image;
Correcting the luminance of the viewpoint image based on the luminance correction amount;
Have
In the correction amount acquisition process,
A projection step of generating projection signals of the captured image and the viewpoint image;
A determination step of determining the validity of the projection signal of the viewpoint image;
A generation step of generating the luminance correction amount using a projection signal determined to be effective in the determination step among projection signals of the viewpoint image and a projection signal of the captured image;
An image processing method comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2017246404A JP7001461B2 (en) | 2017-12-22 | 2017-12-22 | Image processing device and image processing method, and image pickup device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2017246404A JP7001461B2 (en) | 2017-12-22 | 2017-12-22 | Image processing device and image processing method, and image pickup device |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2019114912A true JP2019114912A (en) | 2019-07-11 |
JP7001461B2 JP7001461B2 (en) | 2022-01-19 |
Family
ID=67223858
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2017246404A Active JP7001461B2 (en) | 2017-12-22 | 2017-12-22 | Image processing device and image processing method, and image pickup device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP7001461B2 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022158010A1 (en) * | 2021-01-22 | 2022-07-28 | 株式会社ロジック・アンド・デザイン | Image processing method |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017220724A (en) * | 2016-06-03 | 2017-12-14 | キヤノン株式会社 | Image processing apparatus, imaging device, image processing method, and program |
-
2017
- 2017-12-22 JP JP2017246404A patent/JP7001461B2/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017220724A (en) * | 2016-06-03 | 2017-12-14 | キヤノン株式会社 | Image processing apparatus, imaging device, image processing method, and program |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022158010A1 (en) * | 2021-01-22 | 2022-07-28 | 株式会社ロジック・アンド・デザイン | Image processing method |
Also Published As
Publication number | Publication date |
---|---|
JP7001461B2 (en) | 2022-01-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107465866B (en) | Image processing apparatus and method, imaging apparatus, and computer-readable storage medium | |
US9438786B2 (en) | Focus adjustment apparatus, focus adjustment method and program, and imaging apparatus | |
JP6239857B2 (en) | Imaging apparatus and control method thereof | |
JP7057397B2 (en) | Image processing device, image pickup device, image processing method, program, and storage medium | |
JP6376974B2 (en) | Imaging apparatus and imaging system | |
EP3584621B1 (en) | Focus detection device, focus detection method, and focus detection program | |
US20170257583A1 (en) | Image processing device and control method thereof | |
JP6700986B2 (en) | Image processing device, imaging device, image processing method, and program | |
JP6254843B2 (en) | Image processing apparatus and control method thereof | |
JP2017032646A (en) | Imaging apparatus and control method thereof | |
JP2015210285A (en) | Imaging device, manufacturing method of the same, program thereof and recording medium | |
JP7001461B2 (en) | Image processing device and image processing method, and image pickup device | |
JP6735621B2 (en) | Image processing apparatus, control method thereof, program, and imaging apparatus | |
US10200622B2 (en) | Image processing method, image processing apparatus, and imaging apparatus | |
CN113596431B (en) | Image processing apparatus, image capturing apparatus, image processing method, and storage medium | |
JP2020057017A (en) | Image-capturing device and method for controlling the same | |
JP2018116267A (en) | Focus detection device and method, and imaging device | |
JP2019219499A (en) | Controller, imaging apparatus, control method, program, and storage medium | |
JP2016009024A (en) | Focus detector, control method of the same, and imaging apparatus | |
JP2020067489A (en) | Imaging apparatus and control method for the same | |
JP2018200480A (en) | Imaging device and imaging system | |
JP2019071591A (en) | Imaging apparatus and method for controlling the same |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20201214 |
|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20210103 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20210113 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20211012 |
|
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: 20211126 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20211224 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 7001461 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |