JP6643102B2 - Image processing apparatus and image processing method - Google Patents

Image processing apparatus and image processing method Download PDF

Info

Publication number
JP6643102B2
JP6643102B2 JP2016010388A JP2016010388A JP6643102B2 JP 6643102 B2 JP6643102 B2 JP 6643102B2 JP 2016010388 A JP2016010388 A JP 2016010388A JP 2016010388 A JP2016010388 A JP 2016010388A JP 6643102 B2 JP6643102 B2 JP 6643102B2
Authority
JP
Japan
Prior art keywords
correction
image
application value
value
sharpness
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2016010388A
Other languages
Japanese (ja)
Other versions
JP2017130869A (en
Inventor
菊地 智昭
智昭 菊地
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP2016010388A priority Critical patent/JP6643102B2/en
Publication of JP2017130869A publication Critical patent/JP2017130869A/en
Application granted granted Critical
Publication of JP6643102B2 publication Critical patent/JP6643102B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Studio Devices (AREA)
  • Focusing (AREA)
  • Automatic Focus Adjustment (AREA)
  • Image Processing (AREA)

Description

本発明は、画像処理装置及び画像処理方法に関する。   The present invention relates to an image processing device and an image processing method.

近時では、撮影レンズの射出瞳を複数の領域に瞳分割し、分割された瞳領域に応じた複数の画像、即ち、互いに視差を有する一組の視差画像を取得することができる撮像装置が提案されている。   In recent years, an imaging device that can divide the exit pupil of a photographing lens into a plurality of regions and obtain a plurality of images corresponding to the divided pupil regions, that is, a set of parallax images having parallax with each other is known. Proposed.

特許文献1では、1つの画素に対して1つのマイクロレンズと複数の光電変換部とが形成され、かかる画素が2次元的に配列されている撮像素子を備えた撮像装置が開示されている。1つの画素内に配された複数の光電変換部は、撮影レンズの射出瞳の異なる瞳部分領域を通過する光束を1つのマイクロレンズを介して受光するように構成されており、これにより瞳分割が行われている。このような撮像素子を用いて撮影を行うことによって、分割された瞳部分領域に応じた複数の視差画像を得ることができる。特許文献2には、複数の光電変換部からの信号を加算することによって撮像画像を生成し得ることが開示されている。互いに視差を有する複数の画像を含む一組の視差画像は、光強度の空間分布および角度分布の情報であるLight Field(LF)データと等価である。また、特許文献3には、互いに視差を有する複数の画像を含む一組の視差画像からデフォーカス量の分布を算出することが開示されている。非特許文献1には、取得されたLFデータを用いて撮像面とは異なる仮想結像面における画像を合成することによって、撮影後に撮像画像の合焦位置を変更するリフォーカス技術が開示されている。   Patent Literature 1 discloses an imaging device including an imaging element in which one microlens and a plurality of photoelectric conversion units are formed for one pixel, and the pixels are two-dimensionally arranged. The plurality of photoelectric conversion units arranged in one pixel are configured to receive a light beam passing through different pupil partial regions of the exit pupil of the photographing lens through one microlens, thereby performing pupil division. Has been done. By performing photographing using such an image sensor, a plurality of parallax images corresponding to the divided pupil partial regions can be obtained. Patent Document 2 discloses that a captured image can be generated by adding signals from a plurality of photoelectric conversion units. A set of parallax images including a plurality of images having parallax with each other is equivalent to Light Field (LF) data which is information on a spatial distribution and an angular distribution of light intensity. Patent Document 3 discloses calculating a distribution of a defocus amount from a set of parallax images including a plurality of images having parallax with each other. Non-Patent Literature 1 discloses a refocus technique for changing an in-focus position of a captured image after shooting by combining images on a virtual imaging plane different from the imaging plane using acquired LF data. I have.

米国特許第4410804号公報U.S. Pat. No. 4,410,804 特開2001−083407号公報JP 2001-083407 A 特開2015−119416号公報JP 2015-119416 A

Ren Ng, et. Al., “Light Field Photography with a Hand-held Plenoptic Camera”, Stanford Tech Report CTSR 2005-02, pp. 1-11 (2005)Ren Ng, et.Al., “Light Field Photography with a Hand-held Plenoptic Camera”, Stanford Tech Report CTSR 2005-02, pp. 1-11 (2005)

しかしながら、従来の技術では、良好なリフォーカス画像を得るための調整作業には大きな手間がかかっていた。
本発明の目的は、良好なリフォーカス画像を生成するための手間を軽減し得る画像処理装置及び画像処理方法を提供することにある。
However, in the related art, the adjustment work for obtaining a good refocus image requires a great deal of trouble.
An object of the present invention is to provide an image processing apparatus and an image processing method that can reduce the trouble for generating a good refocused image.

実施形態の一観点によれば、互いに視差を有する複数の視差画像に対して、前記複数の視差画像間の差を強調するための補正処理を行う補正処理手段と、前記補正処理が行われた前記複数の視差画像を合成することによって、所定の結像面において結像したリフォーカス画像を生成するリフォーカス処理手段と、前記リフォーカス画像の鮮鋭度を調整するためのシャープネス処理を行うシャープネス処理手段と、前記補正処理において適用される補正適用値と、前記シャープネス処理において適用されるシャープネス適用値とを、前記リフォーカス画像に対する調整を行うためにユーザによって入力される調整値に基づいて統括的に調整する調整手段とを有することを特徴とする画像処理装置が提供される。   According to one aspect of the embodiment, a plurality of parallax images having parallax with each other, a correction processing unit that performs a correction process for enhancing a difference between the plurality of parallax images, and the correction process is performed. Refocus processing means for generating a refocus image formed on a predetermined image plane by combining the plurality of parallax images, and sharpness processing for performing sharpness processing for adjusting the sharpness of the refocus image Means, a correction application value applied in the correction process, and a sharpness application value applied in the sharpness process, based on an adjustment value input by a user for performing adjustment on the refocused image. An image processing apparatus comprising: an adjustment unit that adjusts the image processing.

本発明によれば、良好なリフォーカス画像を生成するための手間を軽減し得る画像処理装置及び画像処理方法を提供することができる。   According to the present invention, it is possible to provide an image processing apparatus and an image processing method that can reduce the trouble for generating a good refocused image.

第1実施形態による画像処理装置の構成の概略を示すブロック図である。FIG. 2 is a block diagram illustrating a schematic configuration of the image processing apparatus according to the first embodiment. 撮像素子の画素配置を示す平面図である。FIG. 2 is a plan view illustrating a pixel arrangement of an image sensor. 撮像光学系の射出瞳を通過する光束と単位画素との関係を示す模式図である。FIG. 3 is a schematic diagram illustrating a relationship between a light beam passing through an exit pupil of an imaging optical system and a unit pixel. 撮像素子の単位画素を示す回路図である。FIG. 3 is a circuit diagram illustrating a unit pixel of the imaging element. 第1実施形態による画像処理装置に備えられている各種処理手段を模式的に示す図である。FIG. 2 is a diagram schematically illustrating various processing units provided in the image processing apparatus according to the first embodiment. 第1実施形態による画像処理装置によって行われる補正処理を示す概念図である。FIG. 3 is a conceptual diagram illustrating a correction process performed by the image processing device according to the first embodiment. 第1実施形態による画像処理装置によって行われる補正処理の例を示す図である。FIG. 4 is a diagram illustrating an example of a correction process performed by the image processing device according to the first embodiment. 第1実施形態による画像処理装置によって行われる画像処理の例を示す概念図である。FIG. 3 is a conceptual diagram illustrating an example of image processing performed by the image processing device according to the first embodiment. 第1実施形態による画像処理装置において用いられるユーザインターフェースの例を示す図である。FIG. 3 is a diagram illustrating an example of a user interface used in the image processing device according to the first embodiment. 第1実施形態による画像処理装置の動作を示すフローチャートである。5 is a flowchart illustrating an operation of the image processing apparatus according to the first embodiment. 補正適用値kを決定する際に用いられるテーブルの例を示す図である。FIG. 9 is a diagram illustrating an example of a table used when determining a correction application value k. 第2実施形態による画像処理装置に備えられている各種処理手段を模式的に示す図である。It is a figure which shows typically the various processing means with which the image processing apparatus by 2nd Embodiment was provided. 補正適用値kを決定する際に用いられるテーブルの例を示す図である。FIG. 9 is a diagram illustrating an example of a table used when determining a correction application value k. 第2実施形態による画像処理装置の動作を示すフローチャートである。9 is a flowchart illustrating an operation of the image processing apparatus according to the second embodiment.

以下に、本発明の好ましい実施の形態を、添付の図面に基づいて詳細に説明する。
なお、以下に説明する実施の形態は、本発明を実現するための手段の一例であり、本発明が適用される装置の構成や各種条件によって適宜修正又は変更されてもよい。また、各実施の形態を適宜組み合せることも可能である。
Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings.
The embodiment described below is an example of means for realizing the present invention, and may be appropriately modified or changed depending on the configuration of an apparatus to which the present invention is applied and various conditions. Further, the respective embodiments can be appropriately combined.

[第1実施形態]
第1実施形態による画像処理装置及び画像処理方法について図面を用いて説明する。図1は、本実施形態による画像処理装置の構成の概略を示すブロック図である。
[First Embodiment]
An image processing apparatus and an image processing method according to the first embodiment will be described with reference to the drawings. FIG. 1 is a block diagram schematically illustrating the configuration of the image processing apparatus according to the present embodiment.

本実施形態による画像処理装置106は、CPU100と、表示用メモリ101と、メモリ102と、記憶部103と、入力部104と、表示部105とを有している。CPU100は、記憶部103に記憶されたオペレーティングシステム(OS)や画像処理アプリケーションプログラムをメモリ102に展開し、実行する。これにより、画像処理装置106の全体の動作が制御され、画像処理装置106によって各種処理が実行される。画像処理装置106としては、例えば、一般的なパーソナルコンピュータを用いることができる。なお、画像処理装置106は、一般的なパーソナルコンピュータに限定されるものではなく、撮像機能を有していてもよい。撮像機能を有する画像処理装置106としては、例えばデジタルカメラ等が挙げられる。   The image processing apparatus 106 according to the present embodiment includes a CPU 100, a display memory 101, a memory 102, a storage unit 103, an input unit 104, and a display unit 105. The CPU 100 loads an operating system (OS) or an image processing application program stored in the storage unit 103 into the memory 102 and executes the program. As a result, the overall operation of the image processing device 106 is controlled, and various processes are executed by the image processing device 106. As the image processing device 106, for example, a general personal computer can be used. Note that the image processing device 106 is not limited to a general personal computer, and may have an imaging function. As the image processing device 106 having an imaging function, for example, a digital camera or the like can be given.

記憶部103としては、例えば、ハードディスクドライブ等が用いられる。メモリ102は、例えば、RAM(Random Access Memory)等の揮発性メモリや、ROM(Read Only Memory)等の不揮発性メモリを含む。なお、OSや画像処理アプリケーションプログラムは、記憶部103に記憶されているのではなく、メモリ102に記憶されていてもよい。   As the storage unit 103, for example, a hard disk drive or the like is used. The memory 102 includes, for example, a volatile memory such as a RAM (Random Access Memory) and a non-volatile memory such as a ROM (Read Only Memory). Note that the OS and the image processing application program may not be stored in the storage unit 103 but may be stored in the memory 102.

記憶部103には、画像データ(画像ファイル)が格納される。CPU100は、補正対象となる画像データを記憶部103から読み出して表示用メモリ101に展開し、表示用メモリ101に展開した画像を表示部105に表示する。表示部105としては、例えば、液晶ディスプレイやCRT等が挙げられる。
ユーザ(操作者)は、キーボードやマウス等の入力部104を介して画像処理装置106に対して操作を行う。例えば、記憶部103から読み出された画像データに対して、後述するような補正処理やシャープネス処理が行われる。補正処理やシャープネス処理が行われた後の画像データは、表示部105に表示され、記憶部103にも格納される。
The storage unit 103 stores image data (image files). The CPU 100 reads the image data to be corrected from the storage unit 103 and expands the image data in the display memory 101, and displays the image expanded in the display memory 101 on the display unit 105. Examples of the display unit 105 include a liquid crystal display and a CRT.
A user (operator) operates the image processing device 106 via the input unit 104 such as a keyboard and a mouse. For example, a correction process and a sharpness process, which will be described later, are performed on the image data read from the storage unit 103. The image data after the correction processing and the sharpness processing are performed are displayed on the display unit 105 and stored in the storage unit 103.

かかる画像データは、例えば、デジタルカメラ等の撮像装置を用いて撮影することによって得られた画像データである。より具体的には、かかる画像データは、互いに視差を有する複数の視差画像、即ち、一組の視差画像を取得することが可能なデジタルカメラを用いて撮影することによって得られた画像データである。なお、視差画像とは、ある画像に対して視差を有している画像のことである。かかる画像データは、例えば、以下のような撮像素子250を有するデジタルカメラを用いて取得することができる。図2は、撮像素子250の画素配置を示す平面図である。   Such image data is, for example, image data obtained by shooting using an imaging device such as a digital camera. More specifically, such image data is a plurality of parallax images having parallax with each other, that is, image data obtained by photographing using a digital camera capable of acquiring a set of parallax images. . Note that a parallax image is an image having parallax with respect to a certain image. Such image data can be acquired using, for example, a digital camera having the following image sensor 250. FIG. 2 is a plan view showing a pixel arrangement of the image sensor 250.

図2に示すように、撮像素子250には、単位画素251が2次元状(行列状)に複数配列されており、各々の単位画素251上には、R(Red)、G(Green)、B(Blue)のカラーフィルタが例えばベイヤー配列で配置されている。単位画素251は、1つの画素を構成している。各々の単位画素251内には、分割画素(副画素)aと、分割画素(副画素)bとがそれぞれ配置されている。分割画素a、bには、フォトダイオード(光電変換部)252a,252bがそれぞれ設けられている。分割画素a、bからの各々の出力信号は、互いに視差を有している。なお、分割画素bの出力信号の値は、例えば、分割画素a,bの出力信号の加算値から分割画素aの出力信号の値を減算することによって算出される。なお、ここでは、1つの単位画素251が2つの分割画素a,bによって構成されている場合、即ち、1つの単位画素251が2つに分割されている場合を例に説明したが、これに限定されるものではない。1つの単位画素251が例えば3つ以上の分割画素によって構成されていてもよい。   As illustrated in FIG. 2, a plurality of unit pixels 251 are two-dimensionally (in a matrix) arranged in the image sensor 250, and R (Red), G (Green), B (Blue) color filters are arranged, for example, in a Bayer arrangement. The unit pixel 251 forms one pixel. Within each unit pixel 251, a divided pixel (sub-pixel) a and a divided pixel (sub-pixel) b are arranged. The divided pixels a and b are provided with photodiodes (photoelectric conversion units) 252a and 252b, respectively. Output signals from the divided pixels a and b have parallax with each other. The value of the output signal of the divided pixel b is calculated, for example, by subtracting the value of the output signal of the divided pixel a from the sum of the output signals of the divided pixels a and b. Here, the case where one unit pixel 251 is composed of two divided pixels a and b, that is, the case where one unit pixel 251 is divided into two has been described as an example. It is not limited. One unit pixel 251 may be composed of, for example, three or more divided pixels.

次に、撮像光学系と単位画素251との関係について図3を用いて説明する。図3は、撮像光学系の射出瞳253を通過する光束と単位画素251との関係を示す模式図である。図3に示すように、カラーフィルタ254及びマイクロレンズ255が、単位画素251上、即ち、フォトダイオード252a、252b上にそれぞれ形成されている。撮像光学系の射出瞳253を通過する光束の中心と光軸256とが一致している。射出瞳253を通過した光束は、光軸256を中心として単位画素251に入射する。   Next, the relationship between the imaging optical system and the unit pixel 251 will be described with reference to FIG. FIG. 3 is a schematic diagram illustrating the relationship between a light beam passing through the exit pupil 253 of the imaging optical system and the unit pixel 251. As shown in FIG. 3, the color filter 254 and the micro lens 255 are formed on the unit pixel 251, that is, on the photodiodes 252a and 252b. The center of the light beam passing through the exit pupil 253 of the imaging optical system coincides with the optical axis 256. The light beam that has passed through the exit pupil 253 enters the unit pixel 251 around the optical axis 256.

撮像光学系の射出瞳253には、第1の瞳領域257と、第1の瞳領域257とは異なる第2の瞳領域258とが位置している。第1の瞳領域257を通過する光束は、マイクロレンズ255を介して、分割画素a、即ち、フォトダイオード252aによって受光される。一方、第2の瞳領域258を通過する光束は、マイクロレンズ255を介して、分割画素b、即ち、フォトダイオード252bによって受光される。このように、分割画素a、bは、撮像光学系の射出瞳253の別個の瞳領域257,258からの光をそれぞれ受光する。このため、分割画素aの出力信号と分割画素bの出力信号とは、互いに視差を有している。   In the exit pupil 253 of the imaging optical system, a first pupil region 257 and a second pupil region 258 different from the first pupil region 257 are located. The light beam passing through the first pupil region 257 is received by the divided pixel a, that is, the photodiode 252a, via the micro lens 255. On the other hand, a light beam passing through the second pupil region 258 is received by the divided pixel b, that is, the photodiode 252b, via the micro lens 255. As described above, the divided pixels a and b receive light from the separate pupil regions 257 and 258 of the exit pupil 253 of the imaging optical system, respectively. Therefore, the output signal of the divided pixel a and the output signal of the divided pixel b have a parallax.

図4は、撮像素子250の単位画素251を示す回路図である。分割画素a、bにそれぞれ設けられたフォトダイオード252a、252bは、入射される光(光学像)を光電変換し、露光量に応じた電荷を蓄積する。転送スイッチ259a、259bのゲートに印加される信号txa、txbをHighレベルに設定することにより、フォトダイオード252a、252bに蓄積されているそれぞれの電荷がフローティングディフュージョン部260に転送される。フローティングディフュージョン部260は、増幅トランジスタ261のゲートに接続されており、増幅トランジスタ261のゲートの電位は、フォトダイオード252a、252bから転送された電荷量に応じた電位となる。増幅トランジスタ261のドレインは、電源電位Vddに接続されている。増幅トランジスタ261の出力は、垂直出力線(図示せず)を介して電流源(図示せず)に接続されている。増幅トランジスタ261と電流源とによって、ソースフォロワ回路が構成されている。   FIG. 4 is a circuit diagram showing the unit pixel 251 of the image sensor 250. The photodiodes 252a and 252b provided in the divided pixels a and b, respectively, photoelectrically convert incident light (optical image) and accumulate charges corresponding to the exposure amount. By setting the signals txa and txb applied to the gates of the transfer switches 259a and 259b to High level, the respective charges accumulated in the photodiodes 252a and 252b are transferred to the floating diffusion unit 260. The floating diffusion section 260 is connected to the gate of the amplification transistor 261, and the potential of the gate of the amplification transistor 261 is a potential corresponding to the amount of charge transferred from the photodiodes 252 a and 252 b. The drain of the amplification transistor 261 is connected to the power supply potential Vdd. The output of the amplification transistor 261 is connected to a current source (not shown) via a vertical output line (not shown). A source follower circuit is configured by the amplification transistor 261 and the current source.

フローティングディフュージョン部260をリセットするためのリセットスイッチ(リセットトランジスタ)262のドレインは、電源電位Vddに接続されている。リセットスイッチ262のゲートに印加される信号resをHighレベルに設定することにより、フローティングディフュージョン部260がリセットされる。フォトダイオード252a、252bの電荷をリセットする場合には、信号resと信号txa、txbとを同時にHighレベルに設定することにより、転送スイッチ(転送ゲート)259a、259bとリセットスイッチ262の両方をオンにする。そして、フローティングディフュージョン部260を経由して、フォトダイオード252a、252bのリセットを行う。選択スイッチ(選択トランジスタ)263のゲートに印加される信号selをHighレベルに設定することにより、増幅トランジスタ261のゲートの電位に応じた画素信号が単位画素251の出力voutに出力される。   The drain of a reset switch (reset transistor) 262 for resetting the floating diffusion 260 is connected to the power supply potential Vdd. By setting the signal res applied to the gate of the reset switch 262 to High level, the floating diffusion unit 260 is reset. When resetting the charges of the photodiodes 252a and 252b, both the transfer switches (transfer gates) 259a and 259b and the reset switch 262 are turned on by simultaneously setting the signal res and the signals txa and txb to High level. I do. Then, the photodiodes 252a and 252b are reset via the floating diffusion unit 260. By setting the signal sel applied to the gate of the selection switch (selection transistor) 263 to High level, a pixel signal corresponding to the potential of the gate of the amplification transistor 261 is output to the output vout of the unit pixel 251.

撮像素子250にマトリクス状に配列された単位画素251の各々の分割画素(第1の分割画素)aの出力信号の集合体によって、第1の画像信号(A像信号)が構成される。また、撮像素子250にマトリクス状に配列された単位画素251の各々の分割画素(第2の分割画素)252bの出力信号の集合体によって、第2の画像信号(B像信号)が構成される。なお、上述したように、分割画素bの出力信号の値は、例えば、分割画素a,bの出力信号の加算値から分割画素aの出力信号の値を減算することによって算出される。   A first image signal (A-image signal) is formed by an aggregate of output signals of each divided pixel (first divided pixel) a of the unit pixels 251 arranged in a matrix on the image sensor 250. Also, a second image signal (B image signal) is configured by an aggregate of output signals of each divided pixel (second divided pixel) 252b of the unit pixels 251 arranged in a matrix on the image sensor 250. . As described above, the value of the output signal of the divided pixel b is calculated by, for example, subtracting the value of the output signal of the divided pixel a from the sum of the output signals of the divided pixels a and b.

図5は、本実施形態による画像処理装置106に備えられている各種処理手段を模式的に示す図である。図5に示すように、本実施形態による画像処理装置106は、画像入力手段200と、画像解析手段201と、画像表示手段202と、画質調整手段203とを備えている。更に、本実施形態による画像処理装置106は、補正処理手段204と、補正適用値決定手段205と、リフォーカス処理手段206と、シャープネス処理手段207とを備えている。図5に示す各種処理手段は、以下のようにして実現される。即ち、記憶部103に記憶された所定の画像処理アプリケーションプログラム等を、CPU100がメモリ102に展開し、実行する。そして、画像処理装置106に備えられている各部がCPU100からの指令に基づいて所定の動作を行う。こうして、図5に示す各種処理手段が実現される。換言すれば、かかる画像処理アプリケーションプログラムは、CPU100を図5に示すような各種処理手段として機能させる。   FIG. 5 is a diagram schematically illustrating various processing units provided in the image processing apparatus 106 according to the present embodiment. As shown in FIG. 5, the image processing apparatus 106 according to the present embodiment includes an image input unit 200, an image analysis unit 201, an image display unit 202, and an image quality adjustment unit 203. Further, the image processing apparatus 106 according to the present embodiment includes a correction processing unit 204, a correction applied value determination unit 205, a refocus processing unit 206, and a sharpness processing unit 207. Various processing means shown in FIG. 5 are realized as follows. That is, the CPU 100 loads the predetermined image processing application program and the like stored in the storage unit 103 into the memory 102 and executes the program. Each unit provided in the image processing device 106 performs a predetermined operation based on a command from the CPU 100. In this way, various processing means shown in FIG. 5 are realized. In other words, the image processing application program causes the CPU 100 to function as various processing units as shown in FIG.

画像入力手段200は、記憶部103から画像データを読み出し、読み出した画像データをメモリ102に展開する。画像解析手段201は、メモリ102に展開された画像データを解析する。具体的には、画像解析手段201は、例えば、第1の画像若しくは第2の画像における各種分布情報を取得する。各種分布情報としては、コントラスト分布、輝度分布、空間周波数分布等が挙げられる。これら各種分布情報は、補正適用値決定手段205が補正適用値を決定する際に用いられる。補正適用値決定手段205によって行われる補正適用値の決定の詳細については、後述することとする。補正処理手段204は、補正適用値決定手段205によって決定された補正適用値に基づいて補正処理を行う。補正処理手段204によって行われる補正処理の詳細については、後述することとする。   The image input unit 200 reads image data from the storage unit 103 and expands the read image data in the memory 102. The image analysis unit 201 analyzes the image data developed in the memory 102. Specifically, the image analysis means 201 acquires, for example, various distribution information in the first image or the second image. Examples of various distribution information include a contrast distribution, a luminance distribution, and a spatial frequency distribution. These various types of distribution information are used when the correction application value determination unit 205 determines a correction application value. The details of the determination of the correction application value performed by the correction application value determination unit 205 will be described later. The correction processing unit 204 performs a correction process based on the correction application value determined by the correction application value determination unit 205. The details of the correction processing performed by the correction processing unit 204 will be described later.

リフォーカス処理手段206は、補正処理が施された複数の視差画像に対して、ピント位置を異ならせるリフォーカス処理を行う。換言すれば、リフォーカス処理手段206は、補正処理が施された複数の視差画像に対して、撮像時の結像面とは異なる仮想的な結像面(焦点面、リフォーカス面)において結像された画像を生成するリフォーカス処理を行う。リフォーカス処理は、例えば、各々の視差画像を相対的にシフトさせるとともに加算するシフト加算による合成処理によって行われる。具体的には、ユーザによってピント位置の調整が行われ、ピント位置の変動量に基づいてシフト量が決定され、決定されたシフト量に基づいて視差画像が相対的にシフトされるとともに加算される。なお、ユーザによって結像面が設定され、設定された結像面に対応するようにシフト量が決定されてもよい。また、シフト量がユーザによって直接設定されるようにしてもよい。リフォーカス処理によって得られたリフォーカス画像は、画像表示手段202によって表示部105に表示される。画像表示手段(表示制御手段)202は、リフォーカス画像を表示部105に表示するとともに、リフォーカス画像に対しての調整を行うためのユーザインターフェース601(図9参照)を表示部105に表示する。かかるユーザインターフェース601としては、ユーザによって入力される調整値と、当該調整値の調整可能範囲幅とを示す調整バーが用いられる。ユーザインターフェース601は、補正処理において適用される補正適用値kと、シャープネス処理において適用されるシャープネス適用値gとを、ユーザによって入力される調整値Giに基づいて統括的に調整するためのものである。ユーザによって入力される調整値Giは、例えば、1次元の値である。画質調整手段(調整手段)203は、補正処理において適用される補正適用値kと、シャープネス処理において適用されるシャープネス適用値gとを、ユーザによって入力される調整値Giに基づいて統括的に調整する。画質調整手段203は、補正適用値決定手段205によって決定された補正適用値kに応じた値k′をユーザによって入力された調整値Giが超えた場合には、補正適用値kに応じた値k′と調整値Giとの差分に基づいてシャープネス適用値gを決定する。また、画質調整手段203は、補正適用値決定手段205によって決定された補正適用値kに応じた値k′をユーザによって入力された調整値Giが下回った場合には、ユーザによって入力された調整値Giに基づいて補正適用値kを調整する。この場合、補正処理手段204は、画質調整手段203によって調整された補正適用値kに基づいて補正処理を行う。画質調整手段203は、シャープネス適用値gを決定するシャープネス適用値決定手段として機能し得る。また、画質調整手段203は、補正適用値決定手段205によって決定された補正適用値kを調整する補正適用値調整手段としても機能し得る。シャープネス処理手段207は、画質調整手段203により決定されたシャープネス適用値に基づいて、リフォーカス画像に対してシャープネス処理を実行する。   The refocus processing unit 206 performs a refocus process on the plurality of parallax images that have been subjected to the correction process so that the focus positions are different. In other words, the refocus processing unit 206 forms the plurality of parallax images subjected to the correction processing on a virtual imaging plane (focal plane, refocus plane) different from the imaging plane at the time of imaging. A refocus process for generating an image is performed. The refocusing process is performed by, for example, a combining process by shift addition in which each parallax image is relatively shifted and added. Specifically, the focus position is adjusted by the user, the shift amount is determined based on the variation amount of the focus position, and the parallax images are relatively shifted and added based on the determined shift amount. . Note that an imaging plane may be set by the user, and the shift amount may be determined so as to correspond to the set imaging plane. Further, the shift amount may be directly set by the user. The refocused image obtained by the refocusing process is displayed on the display unit 105 by the image display unit 202. The image display unit (display control unit) 202 displays the refocused image on the display unit 105, and displays a user interface 601 (see FIG. 9) for adjusting the refocused image on the display unit 105. . As the user interface 601, an adjustment bar indicating an adjustment value input by a user and an adjustable range width of the adjustment value is used. The user interface 601 comprehensively adjusts a correction application value k applied in the correction processing and a sharpness application value g applied in the sharpness processing based on an adjustment value Gi input by the user. is there. The adjustment value Gi input by the user is, for example, a one-dimensional value. The image quality adjustment unit (adjustment unit) 203 comprehensively adjusts the correction application value k applied in the correction process and the sharpness application value g applied in the sharpness process based on the adjustment value Gi input by the user. I do. When the adjustment value Gi input by the user exceeds the value k ′ corresponding to the correction application value k determined by the correction application value determination unit 205, the image quality adjustment unit 203 sets a value corresponding to the correction application value k. The sharpness application value g is determined based on the difference between k ′ and the adjustment value Gi. When the adjustment value Gi input by the user falls below a value k ′ corresponding to the correction application value k determined by the correction application value determining unit 205, the image quality adjustment unit 203 adjusts the adjustment input by the user. The correction application value k is adjusted based on the value Gi. In this case, the correction processing unit 204 performs a correction process based on the correction application value k adjusted by the image quality adjustment unit 203. The image quality adjustment unit 203 can function as a sharpness application value determination unit that determines the sharpness application value g. Further, the image quality adjustment unit 203 can also function as a correction application value adjustment unit that adjusts the correction application value k determined by the correction application value determination unit 205. The sharpness processing unit 207 performs a sharpness process on the refocused image based on the sharpness application value determined by the image quality adjustment unit 203.

なお、ユーザによって入力された調整値Giが補正適用値決定手段205によって決定された補正適用値kを超えるか否かに拘わらず、ユーザによって入力される調整値Giに基づいて補正適用値kが画質調整手段203によって調整されるようにしてもよい。例えば、補正適用値決定手段205によって決定された補正適用値kに応じた値k′よりも小さい調整値Giをユーザが入力した場合には、当該調整値Giよりも小さい値に対応するように補正適用値kを調整してもよい。例えば、補正適用値kとシャープネス適用値gとのバランスが確保されるように、補正適用値kが調整される。この場合には、調整値Giを小さくするに伴って、補正適用値kが小さくなることとなる。また、補正適用値決定手段205によって決定された補正適用値kに応じた値k′に対して著しく大きい調整値Giがユーザによって入力された場合には、以下のようにしてもよい。即ち、かかる場合には、補正適用値決定手段205によって決定された補正適用値kに応じた値k′よりも大きい値に対応するように補正適用値kを調整してもよい。例えば、補正適用値kとシャープネス適用値gとのバランスが確保されるように、補正適用値kが調整される。この場合には、調整値Giを大きくするに伴って、補正適用値kが大きくなることとなる。補正処理手段204は、画質調整手段203によって調整された補正適用値kに基づいて補正処理を行う。   Regardless of whether or not the adjustment value Gi input by the user exceeds the correction application value k determined by the correction application value determination means 205, the correction application value k is determined based on the adjustment value Gi input by the user. The image quality may be adjusted by the image quality adjusting unit 203. For example, when the user inputs an adjustment value Gi smaller than the value k ′ corresponding to the correction application value k determined by the correction application value determination unit 205, the adjustment value Gi is set to correspond to a value smaller than the adjustment value Gi. The correction application value k may be adjusted. For example, the correction application value k is adjusted so that the balance between the correction application value k and the sharpness application value g is ensured. In this case, as the adjustment value Gi decreases, the correction application value k decreases. When the user inputs an adjustment value Gi that is significantly larger than the value k ′ corresponding to the correction application value k determined by the correction application value determination unit 205, the following may be performed. That is, in such a case, the correction application value k may be adjusted so as to correspond to a value larger than the value k ′ corresponding to the correction application value k determined by the correction application value determination unit 205. For example, the correction application value k is adjusted so that the balance between the correction application value k and the sharpness application value g is ensured. In this case, as the adjustment value Gi increases, the correction application value k increases. The correction processing unit 204 performs a correction process based on the correction application value k adjusted by the image quality adjustment unit 203.

本実施形態による画像処理装置106によって行われる補正処理の概要について図6を用いて説明する。図6は、本実施形態による画像処理装置によって行われる補正処理を示す概念図である。図6に示すように、画像ファイル(画像データ)300には、第1の画像データ(A像データ)302と、画像データ(A+B像データ)301とが含まれている。第1の画像データ302は、第1の画像信号(A像信号)によって得られた画像データである。画像データ301は、第1の画像信号(A像信号)と第2の画像信号(B像信号)との加算信号によって得られたデータである。また、図6においては図示しないが、画像ファイル300は、画像データ301及び第1の画像データ302に関連付けられた付帯情報を更に含んでいる。付帯情報としては、撮像時における撮像装置の各種設定情報等が挙げられる。具体的には、付帯情報として、絞り値、焦点距離、ISO感度等が挙げられる。画像ファイル300は、例えば記憶部103に記録されており、適宜読み出されてメモリ102等に展開される。
画像データ(A+B像データ)301から第1の画像データ(A像データ)302を減算することによって、第2の画像信号(B像信号)に対応する第2の画像データ(B像データ)303が生成される。
An overview of the correction processing performed by the image processing apparatus 106 according to the present embodiment will be described with reference to FIG. FIG. 6 is a conceptual diagram illustrating a correction process performed by the image processing apparatus according to the present embodiment. As shown in FIG. 6, the image file (image data) 300 includes first image data (A image data) 302 and image data (A + B image data) 301. The first image data 302 is image data obtained by a first image signal (A image signal). The image data 301 is data obtained by adding a first image signal (A image signal) and a second image signal (B image signal). Although not shown in FIG. 6, the image file 300 further includes supplementary information associated with the image data 301 and the first image data 302. Examples of the supplementary information include various setting information of the imaging device at the time of imaging. Specifically, the additional information includes an aperture value, a focal length, an ISO sensitivity, and the like. The image file 300 is recorded in, for example, the storage unit 103, and is appropriately read and expanded in the memory 102 or the like.
By subtracting the first image data (A image data) 302 from the image data (A + B image data) 301, the second image data (B image data) 303 corresponding to the second image signal (B image signal) is obtained. Is generated.

画像データ301及び第1の画像データ302は、図2乃至図4を用いて上述したような撮像素子250を用いて取得される。図2乃至図4を用いて上述したような撮像素子250によって実現される瞳分割においては、回折ボケ、即ち、光学的クロストークが生じるため、なだらかな瞳分割となる。なだらかな瞳分割によって得られる一組の視差画像に含まれる複数の画像(視差画像)の各々においては、瞳領域257,258に対応する実効的なF値が十分に大きくないため、実効的な焦点深度が十分に深くならない。このため、本実施形態では、瞳分割における光学的クロストークの影響を低減し、複数の視差画像間における光学的な分離度を高め、複数の視差画像間における差を強調するための補正処理を行う。このような補正処理を、本明細書中においては分離強調処理と称することもある。かかる補正処理、即ち、分離強調処理は、一組の視差画像に含まれる複数の画像間における差を画素毎に拡大することによって行われる。具体的には、補正処理手段204が、補正適用値決定手段205によって決定された補正適用値に基づいて、一組の視差画像に対して補正処理を行う。かかる補正処理を一組の視差画像に対して行うことによって、補正後の一組の視差画像が得られる。補正後の一組の視差画像は、第1の修正画像(第1の修正画像信号、A′像信号)306と第2の修正画像(第2の修正画像信号、B′像信号)305とを含む。   The image data 301 and the first image data 302 are obtained by using the image sensor 250 as described above with reference to FIGS. In the pupil division realized by the image sensor 250 as described above with reference to FIGS. 2 to 4, since diffraction blur, that is, optical crosstalk occurs, the pupil division becomes gentle. In each of a plurality of images (parallax images) included in a set of parallax images obtained by gentle pupil division, the effective F-number corresponding to pupil regions 257 and 258 is not sufficiently large, so that an effective The depth of focus is not deep enough. For this reason, in the present embodiment, a correction process for reducing the influence of optical crosstalk in pupil division, increasing the degree of optical separation between a plurality of parallax images, and emphasizing the difference between a plurality of parallax images is performed. Do. Such correction processing may be referred to as separation enhancement processing in this specification. Such correction processing, that is, separation enhancement processing, is performed by enlarging the difference between a plurality of images included in a set of parallax images for each pixel. Specifically, the correction processing unit 204 performs a correction process on a set of parallax images based on the correction application value determined by the correction application value determination unit 205. By performing such correction processing on a set of parallax images, a set of corrected parallax images is obtained. The set of parallax images after the correction are a first corrected image (first corrected image signal, A ′ image signal) 306, a second corrected image (second corrected image signal, B ′ image signal) 305, including.

かかる補正処理は、以下のようにして行われる。即ち、第1の画像データ302における各画素のデータA(j,i)と第2の画像データ303における各画素のデータB(j,i)とに対して、以下のような式(1)〜式(6)によって表される補正処理が行われる。このような補正処理により、第1の修正画像データ306における各画素のデータA’(j,i)と第2の修正画像データ305における各画素のデータB’(j,i)とが生成される。ここで、kは、かかる補正処理における補正の度合いを示す補正適用値を示す実数であり、0≦k≦1である。αは実数であり、0≦α≦1である。(j,i)は座標を示している。 Such a correction process is performed as follows. That is, the data A 0 (j, i) of each pixel in the first image data 302 and the data B 0 (j, i) of each pixel in the second image data 303 are expressed by the following equation ( The correction processing represented by 1) to (6) is performed. Through such correction processing, data A ′ (j, i) of each pixel in the first corrected image data 306 and data B ′ (j, i) of each pixel in the second corrected image data 305 are generated. You. Here, k is a real number indicating a correction application value indicating a degree of correction in the correction processing, and 0 ≦ k ≦ 1. α is a real number and 0 ≦ α ≦ 1. (J, i) indicates coordinates.

Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102
Figure 0006643102

図7は、本実施形態による画像処理装置によって行われる補正処理の例を示す図である。第1の画像信号(A像信号)は二点鎖線によって示されており、第2の画像信号(B像信号)は破線によって示されている。第1の修正画像信号(A′像信号)は太い実線によって示されており、第2の修正画像信号(B′像信号)は細い実線によって示されている。図7に示すように、第1の画像信号(A像信号)と第2の画像信号(B像信号)との間の差が大きかった箇所においては、第1の修正画像信号(A′像信号)と第2の修正画像信号(B′像信号)との間の差は拡大される。一方、第1の画像信号(A像信号)と第2の画像信号(B像信号)との間の差が小さかった箇所においては、第1の修正画像信号(A′像信号)と第2の修正画像信号(B′像信号)との間の差はあまり変化しない。従って、このような補正処理を行うことによって、一組の視差画像における差が強調されることとなる。   FIG. 7 is a diagram illustrating an example of a correction process performed by the image processing apparatus according to the present embodiment. The first image signal (A image signal) is indicated by a two-dot chain line, and the second image signal (B image signal) is indicated by a broken line. The first modified image signal (A 'image signal) is indicated by a thick solid line, and the second modified image signal (B' image signal) is indicated by a thin solid line. As shown in FIG. 7, in a portion where the difference between the first image signal (A image signal) and the second image signal (B image signal) is large, the first modified image signal (A ′ image signal) Signal) and the second modified image signal (B 'image signal). On the other hand, in a portion where the difference between the first image signal (A image signal) and the second image signal (B image signal) is small, the first modified image signal (A 'image signal) and the second Of the corrected image signal (B ′ image signal) does not change much. Therefore, by performing such a correction process, a difference between a pair of parallax images is emphasized.

式(1)〜式(6)における補正適用値kの値を大きくすると、補正処理における補正の度合いが強くなる。そうすると、一組の修正後の視差画像における視差、即ち、第1の修正画像データ306と第2の修正画像データ305との間の視差が明確になる。また、第1の修正画像データ306と第2の修正画像データ305のそれぞれにおける実効的なF値が大きくなり、第1の修正画像データ306と第2の修正画像データ305のそれぞれにおける実効的な焦点深度が深くなる。一方、補正処理における補正の度合いを過度に強くすると、修正後の一組の視差画像においてノイズが増加し、S/Nの低下を招いてしまう。従って、補正処理の度合いを示す補正適用値kは、適度な大きさに設定することが好ましい。補正処理手段204は、補正適用値決定手段205によって決定された適度な補正適用値kに基づいて補正処理を行う。これにより、S/Nの低下を防止しつつ、十分なリフォーカス効果を得ることが可能となる。   When the value of the correction application value k in Expressions (1) to (6) is increased, the degree of correction in the correction processing increases. Then, the parallax in a set of corrected parallax images, that is, the parallax between the first corrected image data 306 and the second corrected image data 305 becomes clear. Further, the effective F value of each of the first modified image data 306 and the second modified image data 305 is increased, and the effective F value of each of the first modified image data 306 and the second modified image data 305 is increased. The depth of focus increases. On the other hand, if the degree of correction in the correction processing is excessively increased, noise increases in a set of parallax images after correction, which causes a decrease in S / N. Therefore, it is preferable that the correction application value k indicating the degree of the correction processing be set to an appropriate magnitude. The correction processing unit 204 performs a correction process based on the appropriate correction application value k determined by the correction application value determination unit 205. This makes it possible to obtain a sufficient refocusing effect while preventing a reduction in S / N.

画像のうちのコントラストが比較的高い箇所は、補正処理における補正度合いを比較的強めにすることが好ましい一方、画像のうちのコントラストが比較的低い箇所は、補正処理における補正度合いをあまり強くしないことが好ましい。また、画像のうちの輝度が比較的高い箇所は、補正処理における補正度合いを比較的強めにすることが好ましい一方、画像のうちの輝度が比較的低い箇所は、補正処理における補正度合いをあまり強くしないことが好ましい。また、画像のうちの高周波成分が比較的多い箇所は、補正処理における補正度合いを比較的強めにすることが好ましい一方、画像のうちの高周波数成分が比較的少ない箇所は、補正処理における補正度合いをあまり強くしないことが好ましい。従って、適度な補正適用値kを決定するためには、これらの要素を加味することが好ましい。そこで、本実施形態では、補正適用値決定手段205は、コントラスト分布、輝度分布、及び、空間周波数分布のうちの少なくともいずれかに基づいて、適度な補正適用値kを決定する。なお、コントラスト分布、輝度分布、及び、空間周波数分布のいずれかのみに基づいて補正適用値kを決定してもよいし、こららの要素を適宜組合せることによって補正適用値kを決定してもよい。   It is preferable that the degree of correction in the correction processing is relatively high in a part of the image where the contrast is relatively high, while the degree of correction in the correction processing is not so strong in a part of the image where the contrast is relatively low. Is preferred. In addition, it is preferable that the correction degree in the correction process is relatively high in a portion of the image where the luminance is relatively high, while the correction degree in the correction process is too strong in a portion of the image where the luminance is relatively low. Preferably not. Further, it is preferable to make the degree of correction in the correction process relatively high in a portion where the high frequency component is relatively large in the image, while it is preferable to set the degree of correction in the correction process in a portion where the high frequency component is relatively small in the image. Is preferably not so strong. Therefore, in order to determine an appropriate correction application value k, it is preferable to take these factors into account. Therefore, in the present embodiment, the correction applied value determining unit 205 determines an appropriate correction applied value k based on at least one of the contrast distribution, the luminance distribution, and the spatial frequency distribution. The correction application value k may be determined based on only one of the contrast distribution, the luminance distribution, and the spatial frequency distribution, or the correction application value k may be determined by appropriately combining these elements. Is also good.

図8は、本実施形態による画像処理装置によって行われる画像処理の例を示す概念図である。図8に示すように、リフォーカス処理手段206は、第1の修正画像データ306と第2の修正画像データ305とから成る一組の修正後の視差画像に対して、リフォーカス処理を行う。リフォーカス処理においては、上述したように、例えばシフト加算による合成処理が用いられる。このようなリフォーカス処理によって、リフォーカス画像501が生成される。こうして生成されたリフォーカス画像501に対して、リフォーカス画像501の鮮鋭度を調整するためのシャープネス処理がシャープネス処理手段207によって行われる。こうして、シャープネス処理が行われたリフォーカス画像502、即ち、最終的なリフォーカス画像502が得られる。   FIG. 8 is a conceptual diagram illustrating an example of image processing performed by the image processing apparatus according to the present embodiment. As illustrated in FIG. 8, the refocus processing unit 206 performs a refocus process on a pair of corrected parallax images including the first corrected image data 306 and the second corrected image data 305. In the refocusing process, as described above, for example, a combining process by shift addition is used. By such a refocusing process, a refocused image 501 is generated. Sharpness processing for adjusting the sharpness of the refocused image 501 is performed by the sharpness processing unit 207 on the refocused image 501 thus generated. Thus, a refocused image 502 on which the sharpness processing has been performed, that is, a final refocused image 502 is obtained.

図9は、本実施形態による画像処理装置において用いられるユーザインターフェースの例を示す図である。図9に示すように、ユーザインターフェース601としては、例えば、調整スライダが用いられている。k′は、補正処理における補正適用値kに応じた値を示している。k′は、上述した補正適用値kに所定の値を乗じることによって得られる。Giは、リフォーカス画像に対する調整を行うためにユーザによって入力される調整値(指示値)を示している。かかる調整値Giの設定は、スライダ602の位置をユーザが調整することによって行われる。   FIG. 9 is a diagram illustrating an example of a user interface used in the image processing apparatus according to the present embodiment. As shown in FIG. 9, for example, an adjustment slider is used as the user interface 601. k ′ indicates a value corresponding to the correction application value k in the correction processing. k ′ is obtained by multiplying the correction application value k by a predetermined value. Gi indicates an adjustment value (instruction value) input by the user for performing adjustment on the refocused image. The setting of the adjustment value Gi is performed by the user adjusting the position of the slider 602.

本実施形態による画像処理装置では、リフォーカス画像に対する調整を行うためにユーザによって入力される調整値Giと、補正処理における補正適用値kとに基づいて、シャープネス適用値gが決定される。具体的には、リフォーカス画像に対する調整を行うためにユーザによって入力される調整値Giが、補正適用値に応じた値k′を超えた場合には、補正適用値に応じた値k′と調整値Giとの差分に応じた値が、シャープネス適用値gとして決定される。以下の式(7)は、調整値Giと、補正適用値に応じた値k′と、シャープネス適用値gとの関係を示している。
g=Gi−k′ ・・・(7)
In the image processing apparatus according to the present embodiment, the sharpness application value g is determined based on the adjustment value Gi input by the user for performing the adjustment on the refocused image and the correction application value k in the correction processing. Specifically, when the adjustment value Gi input by the user for performing the adjustment on the refocus image exceeds the value k ′ corresponding to the correction application value, the adjustment value Gi ′ is changed to the value k ′ corresponding to the correction application value. A value corresponding to the difference from the adjustment value Gi is determined as the sharpness application value g. The following equation (7) shows the relationship between the adjustment value Gi, the value k ′ corresponding to the correction application value, and the sharpness application value g.
g = Gi-k '(7)

本実施形態において、図9に示すようなユーザインターフェース601を用いて調整作業が行われるようにしているのは、以下のような理由によるものである。即ち、補正適用値kをユーザが適正な値に調整し、更に、シャープネス適用値gをユーザが適正な値に調整する場合には、これら一連の作業において大きな手間がかかる。一方、本実施形態のように、ユーザによって入力される調整値Giと、補正適応値に応じたk′とに基づいて、シャープネス適用値gを決定するようにすれば、ユーザの手間は調整値Giの入力のみとなる。即ち、図9に示すようなユーザインターフェース601を用いれば、良好なリフォーカス画像を生成するための手間を軽減することができる。このような理由により、本実施形態では、図9に示すようなユーザインターフェース601を用いて調整作業が行われるようにしている。   In the present embodiment, the adjustment work is performed using the user interface 601 as shown in FIG. 9 for the following reason. That is, when the user adjusts the correction application value k to an appropriate value and further adjusts the sharpness application value g to an appropriate value, a great deal of time is required in a series of these operations. On the other hand, if the sharpness application value g is determined based on the adjustment value Gi input by the user and k ′ corresponding to the correction adaptation value as in the present embodiment, the user's labor is reduced. Only Gi is input. That is, if the user interface 601 as shown in FIG. 9 is used, the labor for generating a good refocus image can be reduced. For this reason, in the present embodiment, the adjustment work is performed using the user interface 601 as shown in FIG.

図10は、本実施形態による画像処理装置の動作を示すフローチャートである。まず、ステップS700では、CPU100が記憶部103から画像ファイル300を読み出す。具体的には、画像データ301と第1の画像データ302とを含む画像ファイル300が、記憶部103から読み出される。CPU100は、画像データ301から第1の画像データ302を減算することによって、第2の画像データ303を生成する。   FIG. 10 is a flowchart illustrating the operation of the image processing apparatus according to the present embodiment. First, in step S700, the CPU 100 reads the image file 300 from the storage unit 103. Specifically, the image file 300 including the image data 301 and the first image data 302 is read from the storage unit 103. The CPU 100 generates the second image data 303 by subtracting the first image data 302 from the image data 301.

ステップS710では、画像解析手段201が、第1の画像データ302と第2の画像データ303とのうちのいずれかに対して画像解析を行う。これにより、例えば、コントラスト分布、輝度分布、空間周波数分布等の各種分布情報が取得される。   In step S710, the image analysis unit 201 performs an image analysis on one of the first image data 302 and the second image data 303. Thereby, for example, various distribution information such as a contrast distribution, a luminance distribution, and a spatial frequency distribution are obtained.

ステップS720では、リフォーカス画像に対する調整がユーザインターフェース601を介してユーザによって行われる。ユーザインターフェース601は、上述したように、表示部105に表示される。リフォーカス画像に対する調整の量を指示するための調整値Giは、上述したように、ユーザがスライダ602の位置を調整することによって設定される。なお、補正処理やシャープネス処理等の一連の処理が実行された後の最終的なリフォーカス画像が、表示部105に表示されるようにすることが好ましい。ユーザは、表示部105に表示された最終的なリフォーカス画像を確認しながら、調整作業を行うことができる。   In step S720, adjustment to the refocused image is performed by the user via the user interface 601. The user interface 601 is displayed on the display unit 105 as described above. The adjustment value Gi for designating the amount of adjustment for the refocused image is set by the user adjusting the position of the slider 602 as described above. It is preferable that the final refocused image after a series of processing such as correction processing and sharpness processing is executed be displayed on the display unit 105. The user can perform the adjustment work while checking the final refocused image displayed on the display unit 105.

ステップS730では、補正適用値決定手段205が、ステップS710において行われた画像解析の結果に基づいて、補正処理における補正適用値kを決定する。図11は、補正適用値kを決定する際に用いられるテーブルの例を示す図である。図11に示すように、テーブルには、コントラストと、輝度と、空間周波数と、調整係数との関係が示されている。補正適用値の標準値ksに対して、図11に示すような調整係数を乗算することによって、適切な補正適用値kが求められる。コントラストや輝度や空間周波数は、画像中の各箇所において異なっているため、適切な補正適用値は各箇所において異なる。従って、互いに異なる複数の補正適用値が求められることとなる。ここでは、各箇所に対してそれぞれ得られた複数の補正適用値のうちの最大値を、画像全体に対して補正処理を行うための補正適用値kとして決定する。なお、画像全体に対して補正処理を行うための補正適用値kは、各箇所に対してそれぞれ得られた補正適用値のうちの最大値に限定されるものではない。   In step S730, the correction application value determination unit 205 determines a correction application value k in the correction processing based on the result of the image analysis performed in step S710. FIG. 11 is a diagram illustrating an example of a table used when determining the correction application value k. As shown in FIG. 11, the table shows the relationship among contrast, luminance, spatial frequency, and adjustment coefficient. By multiplying the standard value ks of the correction application value by an adjustment coefficient as shown in FIG. 11, an appropriate correction application value k is obtained. Since the contrast, the brightness, and the spatial frequency are different at each location in the image, the appropriate correction application value is different at each location. Therefore, a plurality of different correction application values are obtained. Here, the maximum value of the plurality of correction application values obtained for each location is determined as the correction application value k for performing the correction process on the entire image. Note that the correction application value k for performing the correction process on the entire image is not limited to the maximum value among the correction application values obtained for each location.

ステップS740では、補正処理手段204が補正適用値kを用いて補正処理を実行し、これにより、第1の修正画像データ306と第2の修正画像データ305とが生成される。
ステップS750では、リフォーカス処理手段206が、補正処理が施された一組の視差画像に対してリフォーカス処理を実行し、これにより、リフォーカス画像501が生成される。即ち、所望の位置に合焦するようにフォーカス位置が調整されたリフォーカス画像、即ち、再構成画像が得られる。
In step S740, the correction processing unit 204 performs a correction process using the correction application value k, and thereby the first corrected image data 306 and the second corrected image data 305 are generated.
In step S750, the refocus processing unit 206 executes the refocus processing on the pair of parallax images that have been subjected to the correction processing, thereby generating the refocus image 501. That is, a refocused image in which the focus position is adjusted so as to focus on a desired position, that is, a reconstructed image is obtained.

ステップ760では、画質調整手段203が、ステップS720において入力された調整値Giと、ステップS730において決定された補正適用値kに応じた値k′とに基づいて、シャープネス適用値gを決定する。補正適用値に応じた値k′は、上述したように、補正適用値kに所定の値を乗じることによって得られる。シャープネス適用値gは、上述した式(7)に基づいて求められる。
ステップS770では、シャープネス処理手段207が、シャープネス適用値gに基づく量のシャープネス処理をリフォーカス画像501に対して行い、これにより、最終的なリフォーカス画像502が生成される。
このように、本実施形態では、良好なリフォーカス画像を生成するための手間を軽減することができる。
In step 760, the image quality adjustment unit 203 determines the sharpness application value g based on the adjustment value Gi input in step S720 and the value k 'corresponding to the correction application value k determined in step S730. The value k ′ corresponding to the correction application value is obtained by multiplying the correction application value k by a predetermined value, as described above. The sharpness application value g is obtained based on the above-described equation (7).
In step S770, the sharpness processing unit 207 performs the amount of sharpness processing on the refocus image 501 based on the sharpness application value g, thereby generating a final refocus image 502.
As described above, in the present embodiment, it is possible to reduce the labor for generating a good refocus image.

[第2実施形態]
第2実施形態による画像処理装置について図面を用いて説明する。図1乃至図11に示す第1実施形態による画像処理装置及び画像処理方法と同一の構成要素には、同一の符号を付して説明を省略または簡潔にする。
本実施形態による画像処理装置は、画像ファイル300に付帯されている付帯情報に基づいて補正処理における補正適用値kを決定するものである。
[Second embodiment]
An image processing apparatus according to a second embodiment will be described with reference to the drawings. The same components as those of the image processing apparatus and the image processing method according to the first embodiment shown in FIGS. 1 to 11 are denoted by the same reference numerals, and description thereof will be omitted or simplified.
The image processing apparatus according to the present embodiment determines the correction application value k in the correction processing based on the additional information attached to the image file 300.

本実施形態による画像処理装置の全体的な構成は、図1を用いて上述した画像処理装置と同様である。図12は、本実施形態による画像処理装置に備えられている各種処理手段を模式的に示す図である。図12に示すように、本実施形態による画像処理装置106は、画像入力手段200と、付帯情報取得手段801と、画像表示手段202と、画質調整手段203とを備えている。また、本実施形態による画像処理装置106は、補正処理手段204と、補正適用値決定手段205と、リフォーカス処理手段206と、シャープネス処理手段207とを備えている。図8に示す各種処理手段は、以下のようにして実現される。即ち、記憶部103に記憶された所定の画像処理アプリケーションプログラム等を、CPU100がメモリ102に展開し、実行する。そして、画像処理装置106に備えられている各部がCPU100からの指令に基づいて所定の動作を行う。こうして、図8に示す各種処理手段が実現される。換言すれば、かかる画像処理アプリケーションプログラムは、CPU100を図8に示すような各種処理手段として機能させる。   The overall configuration of the image processing apparatus according to the present embodiment is the same as the image processing apparatus described above with reference to FIG. FIG. 12 is a diagram schematically illustrating various processing units provided in the image processing apparatus according to the present embodiment. As shown in FIG. 12, the image processing apparatus 106 according to the present embodiment includes an image input unit 200, an incidental information acquisition unit 801, an image display unit 202, and an image quality adjustment unit 203. The image processing apparatus 106 according to the present embodiment includes a correction processing unit 204, a correction applied value determination unit 205, a refocus processing unit 206, and a sharpness processing unit 207. Various processing means shown in FIG. 8 are realized as follows. That is, the CPU 100 loads the predetermined image processing application program and the like stored in the storage unit 103 into the memory 102 and executes the program. Each unit provided in the image processing device 106 performs a predetermined operation based on a command from the CPU 100. Thus, the various processing means shown in FIG. 8 are realized. In other words, the image processing application program causes the CPU 100 to function as various processing units as shown in FIG.

画像入力手段200は、記憶部103から画像ファイル300を読み出し、読み出した画像ファイル300をメモリ102に展開する。付帯情報取得手段801は、メモリ102に展開された画像ファイル300を解析することにより、レンズ情報、焦点距離、ISO感度等の付帯情報を取得する。補正適用値決定手段205は、付帯情報取得手段801によって取得されたこれらの付帯情報に基づいて、補正処理における補正適用値kを決定する。こうして決定された補正適用値kを用いて、補正処理手段204が一組の視差画像に対して補正処理を実行する。補正処理が施された一組の視差画像に対して、リフォーカス処理手段206がリフォーカス処理を行うことにより、リフォーカス画像を生成する。こうして生成されたリフォーカス画像が、画像表示手段202によって表示部105に表示される。画質調整手段203は、ユーザインターフェース601における調整値Giと、補正処理における補正適用値kとに基づいて、シャープネス処理におけるシャープネス適用値gとを決定する。シャープネス処理手段207は、画質調整手段203により決定されたシャープネス適用値gに基づいて、リフォーカス画像に対してシャープネス処理を実行する。   The image input unit 200 reads the image file 300 from the storage unit 103, and expands the read image file 300 in the memory 102. The incidental information acquiring unit 801 acquires incidental information such as lens information, focal length, and ISO sensitivity by analyzing the image file 300 expanded in the memory 102. The correction application value determination unit 205 determines a correction application value k in the correction process based on the supplementary information acquired by the supplementary information acquisition unit 801. Using the correction application value k thus determined, the correction processing unit 204 performs a correction process on a set of parallax images. The refocus processing unit 206 performs a refocus process on a set of parallax images subjected to the correction process, thereby generating a refocus image. The refocus image thus generated is displayed on the display unit 105 by the image display unit 202. The image quality adjustment unit 203 determines a sharpness application value g in the sharpness processing based on the adjustment value Gi in the user interface 601 and the correction application value k in the correction processing. The sharpness processing unit 207 performs a sharpness process on the refocused image based on the sharpness application value g determined by the image quality adjustment unit 203.

画像を取得した際の絞り値が大きいほど、被写界深度が深くなり、リフォーカス効果が弱くなる。このため、画像を取得した際の絞り値が比較的大きい場合には、補正処理における補正度合いを比較的強めに設定することが好ましい。一方、画像を取得した際の絞り値が比較的小さい場合には、補正処理における補正度合いをあまり強くしなくてもリフォーカスの効果が十分に得られる。従って、画像を取得した際の絞り値が比較的小さい場合には、補正処理における補正度合いを比較的弱めに設定することが好ましい。   The larger the aperture value at the time of acquiring an image, the deeper the depth of field and the weaker the refocus effect. Therefore, when the aperture value at the time of acquiring the image is relatively large, it is preferable to set the degree of correction in the correction processing to be relatively high. On the other hand, when the aperture value at the time of acquiring the image is relatively small, the refocusing effect can be sufficiently obtained without increasing the degree of correction in the correction processing. Therefore, when the aperture value at the time of acquiring the image is relatively small, it is preferable to set the degree of correction in the correction processing to be relatively weak.

また、画像を取得した際の焦点距離が大きいほど、即ち、望遠側になるほど、被写界深度が浅くなる。即ち、画像を取得した際の焦点距離が比較的大きい場合には、補正処理における補正度合いをあまり強く設定しなくてもリフォーカスの効果が十分に得られる。このため、画像を取得した際の焦点距離が比較的大きい場合には、補正処理における補正度合いを弱めに設定することが好ましい。一方、画像を取得した際の焦点距離が比較的小さい場合には、補正処理における補正度合いを強めに設定することが好ましい。   Further, the depth of field becomes shallower as the focal length when the image is acquired, that is, as it is on the telephoto side. That is, when the focal length at the time of acquiring an image is relatively large, the refocusing effect can be sufficiently obtained without setting the degree of correction in the correction processing too high. For this reason, when the focal length at the time of acquiring an image is relatively large, it is preferable to set the degree of correction in the correction processing to be relatively low. On the other hand, when the focal length when the image is obtained is relatively small, it is preferable to set the degree of correction in the correction processing to be relatively high.

また、画像を取得した際のISO感度が高いほど、S/N比が悪化し、ノイズが多くなってしまう。従って、画像を取得した際のISO感度が比較的大きい場合には、補正処理における補正度合いを弱めに設定することが好ましい。一方、画像を取得した際のISO感度が比較的小さい場合には、補正処理における補正度合いを強めに設定しても特段の弊害がない。
従って、これらの情報を総合的に判断して、補正適用値kを決定することが好ましい。そこで、本実施形態では、補正適用値決定手段205は、絞り値、焦点距離、及び、ISO感度に基づいて、適度な補正適用値kを決定する。
Also, the higher the ISO sensitivity at the time of acquiring an image, the worse the S / N ratio and the more noise. Therefore, when the ISO sensitivity at the time of acquiring an image is relatively large, it is preferable to set the degree of correction in the correction processing to be relatively low. On the other hand, when the ISO sensitivity at the time of acquiring an image is relatively small, there is no particular adverse effect even if the degree of correction in the correction processing is set to be relatively high.
Therefore, it is preferable to determine the correction application value k by comprehensively judging such information. Therefore, in the present embodiment, the correction application value determination unit 205 determines an appropriate correction application value k based on the aperture value, the focal length, and the ISO sensitivity.

図13は、補正適用値kを算出する際に用いられるテーブルの例を示す図である。図13(a)に示すテーブルには、絞り値と、焦点距離と、ISO感度と、調整係数との関係が示されている。各項目に対応する調整係数の加算平均によって、補正係数が求められる。
例えば、絞り値F2.8、焦点距離200mm、ISO感度800で撮影した画像の場合には、各項目の調整係数はいずれも1.0であるため、これらの調整係数の加算値は3.0であり、これらの調整係数の加算平均値は1.0である。従って、補正係数は、1.0となる。補正適用値の標準値ksに、こうして得られた補正係数を乗算することによって、補正適用値kが求められる。
FIG. 13 is a diagram illustrating an example of a table used when calculating the correction application value k. The table shown in FIG. 13A shows the relationship among the aperture value, the focal length, the ISO sensitivity, and the adjustment coefficient. A correction coefficient is obtained by averaging the adjustment coefficients corresponding to each item.
For example, in the case of an image photographed with an aperture value of F2.8, a focal length of 200 mm, and an ISO sensitivity of 800, the adjustment coefficient of each item is 1.0, and the sum of these adjustment coefficients is 3.0. And the average value of these adjustment coefficients is 1.0. Therefore, the correction coefficient is 1.0. The correction application value k is obtained by multiplying the standard value ks of the correction application value by the correction coefficient thus obtained.

なお、ここでは、加算平均によって補正係数を求める場合を例に説明したが、これに限定されるものではない。例えば、各項目の重要度に応じた重み付けをした加重平均によって補正係数を求めるようにしてもよい。
また、ここでは、補正適用値の標準値ksに補正係数を乗算することによって、補正適用値kを求める場合を例に説明したが、これに限定されるものではない。例えば、図13(b)に示すようなテーブルを用いるようにしてもよい。図13(b)に示すテーブルには、絞り値と、焦点距離と、ISO感度と、補正適用値kとの関係が示されている。このようなテーブルを用いて、補正適用値kを決定するようにしてもよい。
Here, the case where the correction coefficient is obtained by averaging has been described as an example, but the present invention is not limited to this. For example, the correction coefficient may be obtained by a weighted average weighted according to the importance of each item.
Further, here, the case where the correction application value k is obtained by multiplying the standard value ks of the correction application value by the correction coefficient has been described as an example, but the invention is not limited thereto. For example, a table as shown in FIG. 13B may be used. The table shown in FIG. 13B shows the relationship among the aperture value, the focal length, the ISO sensitivity, and the correction application value k. The correction application value k may be determined using such a table.

図14は、本実施形態による画像処理装置の動作を示すフローチャートである。
まず、ステップS900は、図10を用いて上述した第1実施形態におけるステップS700と同様であるため説明を省略する。
ステップS910では、付帯情報取得手段801が、メモリ102に展開された画像ファイル300を解析することにより、レンズ情報、焦点距離、ISO感度等の付帯情報を取得する。
ステップS920は、図10を用いて上述した第1実施形態におけるステップS720と同様であるため説明を省略する。
FIG. 14 is a flowchart illustrating the operation of the image processing apparatus according to the present embodiment.
First, step S900 is the same as step S700 in the first embodiment described above with reference to FIG.
In step S910, the incidental information acquisition unit 801 acquires incidental information such as lens information, focal length, and ISO sensitivity by analyzing the image file 300 expanded in the memory 102.
Step S920 is the same as step S720 in the first embodiment described above with reference to FIG.

ステップS930では、補正適用値決定手段205が、ステップS910において行われた画像解析の結果に基づいて、補正処理における補正適用値kを決定する。即ち、補正適用値決定手段205が、上述したように、付帯情報取得手段801によって取得された付帯情報に基づいて、補正処理における補正適用値kを決定する。
ステップS940〜ステップS970は、図10を用いて上述した第1実施形態におけるステップS740〜ステップS770と同様であるため説明を省略する。
このように、画像ファイル300に付帯されている付帯情報に基づいて補正適用値kを決定するようにしてもよい。
In step S930, the correction application value determination unit 205 determines a correction application value k in the correction processing based on the result of the image analysis performed in step S910. That is, the correction application value determination unit 205 determines the correction application value k in the correction process based on the additional information acquired by the additional information acquisition unit 801 as described above.
Steps S940 to S970 are the same as steps S740 to S770 in the first embodiment described above with reference to FIG.
In this manner, the correction application value k may be determined based on the supplementary information attached to the image file 300.

[第3実施形態]
第3実施形態による画像処理装置について図面を用いて説明する。図1乃至図14に示す第1又は第2実施形態による画像処理装置と同一の構成要素には、同一の符号を付して説明を省略または簡潔にする。
本実施形態による画像処理装置は、合焦位置からのずれ量に基づいてシャープネス処理を行うものである。
[Third embodiment]
An image processing apparatus according to a third embodiment will be described with reference to the drawings. The same components as those of the image processing apparatus according to the first or second embodiment shown in FIGS. 1 to 14 are denoted by the same reference numerals, and description thereof will be omitted or simplified.
The image processing apparatus according to the present embodiment performs a sharpness process based on a shift amount from a focus position.

合焦位置(ピント面)からのずれ量が小さい箇所に対してはシャープネス処理を十分に行う一方、合焦位置からのずれ量が大きい箇所に対してはシャープネス処理を弱くすると、強いリフォーカスの効果を得ることができる。そこで、本実施形態では、合焦位置からのずれ量に応じてシャープネス処理を行う。   If sharpness processing is sufficiently performed for a position with a small amount of deviation from the focus position (focus plane), while sharpness processing is weakened for a position with a large deviation from the focus position, a strong refocus The effect can be obtained. Therefore, in the present embodiment, sharpness processing is performed according to the amount of deviation from the in-focus position.

合焦位置からのずれ量を示す情報としては、デフォーカスマップを用いることができる。デフォーカスマップは、画像の各画素のピントが合焦位置(ピント面)からどれだけずれているかを示すデータである。かかるデフォーカスマップは、公知の手法によって生成することが可能である。例えば、オートフォーカス機能を作動させつつ撮影する場合には、ピントが合った領域におけるデフォーカス量を0とするデフォーカスマップを撮影の際に撮像装置によって取得することができる。撮影の際に撮像装置によって取得されたデフォーカスマップは、付帯情報の一つとして画像ファイル300に含められる。なお、デフォーカスマップは、一組の視差画像を構成する第1の画像と第2の画像との間の像ずれ量に基づいて生成することも可能である。画像解析手段201は、複数の画像を含む一組の視差画像に基づいてデフォーカスマップを生成するデフォーカスマップ生成手段として機能し得る。   A defocus map can be used as the information indicating the amount of deviation from the in-focus position. The defocus map is data indicating how much each pixel of the image is out of focus from the in-focus position (focus plane). Such a defocus map can be generated by a known method. For example, when shooting while activating the autofocus function, a defocus map that sets the defocus amount to 0 in an in-focus area can be acquired by the imaging apparatus at the time of shooting. The defocus map acquired by the imaging device at the time of shooting is included in the image file 300 as one of the additional information. Note that the defocus map can also be generated based on the amount of image shift between the first image and the second image that form a set of parallax images. The image analysis unit 201 can function as a defocus map generation unit that generates a defocus map based on a set of parallax images including a plurality of images.

このようなデフォーカスマップを用いることにより、ピント面(合焦位置)からのずれ量を把握することができる。例えば、ピント面からの距離が所定値以内である領域と、ピント面からの距離が所定値を超える領域とを識別することができる。そして、例えば、ピント面からの距離が所定値以内である領域に対してのみ、シャープネス適用値gを用いたシャープネス処理を行うようにする。   By using such a defocus map, it is possible to grasp the amount of deviation from the focus plane (focus position). For example, an area whose distance from the focus plane is within a predetermined value and an area whose distance from the focus plane exceeds a predetermined value can be identified. Then, for example, the sharpness processing using the sharpness application value g is performed only on an area whose distance from the focus plane is within a predetermined value.

なお、ここでは、ピント面からの距離が所定値以内である領域に対してのみシャープネス処理を行う場合を例に説明したが、これに限定されるものではない。例えば、ピント面からの距離が所定値を超える領域に対しては、ピント面から離れるほど小さくなるようなシャープネス適用値を用いてシャープネス処理を行うようにしてもよい。一方、ピント面からの距離が所定値以内である領域に対しては、ピント面に近づくほど大きくなるようなシャープネス適用値を用いてシャープネス処理を行うようにしてもよい。このような処理を行うことにより、ピント面からの距離が所定値以内である領域におけるシャープネスの効果をより高めてもよい。   Here, a case has been described as an example where the sharpness processing is performed only on an area whose distance from the focus plane is within a predetermined value, but the present invention is not limited to this. For example, for an area whose distance from the focus plane exceeds a predetermined value, the sharpness processing may be performed using a sharpness application value that becomes smaller as the distance from the focus plane increases. On the other hand, for an area whose distance from the focus plane is within a predetermined value, the sharpness processing may be performed using a sharpness application value that increases as the distance from the focus plane increases. By performing such processing, the effect of sharpness in a region where the distance from the focus plane is within a predetermined value may be further enhanced.

このように、本実施形態によれば、ピントが合っている領域に対してのみ十分なシャープネス処理が選択的に適用されるため、リフォーカス効果をより際立たせることができる。
以上、本発明をその好適な実施形態に基づいて詳述してきたが、本発明はこれら特定の実施形態に限られるものではなく、この発明の要旨を逸脱しない範囲の様々な形態も本発明に含まれる。例えば、上述の実施形態の一部を適宜組み合わせてもよい。
As described above, according to the present embodiment, a sufficient sharpness process is selectively applied only to an in-focus area, so that the refocus effect can be made more prominent.
As described above, the present invention has been described in detail based on the preferred embodiments. However, the present invention is not limited to these specific embodiments, and various forms that do not depart from the gist of the present invention are also included in the present invention. included. For example, some of the above-described embodiments may be appropriately combined.

(その他の実施形態)
本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。
(Other embodiments)
The present invention supplies a program for realizing one or more functions of the above-described embodiments to a system or an apparatus via a network or a storage medium, and one or more processors in a computer of the system or the apparatus read and execute the program. This processing can be realized. Further, it can also be realized by a circuit (for example, an ASIC) that realizes one or more functions.

100…CPU
101…表示用メモリ
102…メモリ
103…記憶部
104…入力部
105…表示部
200…画像入力手段
201…画像解析手段
202…画像表示手段
203…画質調整手段
204…補正処理手段
205…補正適用値決定手段
206…リフォーカス処理手段
207…シャープネス処理手段
300…画像ファイル
301…画像データ
302…第1の画像データ
303…第2の画像データ
305…第2の修正画像
306…第1の修正画像
501…リフォーカス画像
502…最終的なリフォーカス画像
601…ユーザインターフェース
100 ... CPU
101 display memory 102 memory 103 storage unit 104 input unit 105 display unit 200 image input unit 201 image analysis unit 202 image display unit 203 image quality adjustment unit 204 correction processing unit 205 correction applied value Determining means 206 refocus processing means 207 sharpness processing means 300 image file 301 image data 302 first image data 303 second image data 305 second corrected image 306 first corrected image 501 ... Refocused image 502 ... Final refocused image 601 ... User interface

Claims (18)

互いに視差を有する複数の視差画像に対して、前記複数の視差画像間の差を強調するための補正処理を行う補正処理手段と、
前記補正処理が行われた前記複数の視差画像を合成することによって、所定の結像面において結像したリフォーカス画像を生成するリフォーカス処理手段と、
前記リフォーカス画像の鮮鋭度を調整するためのシャープネス処理を行うシャープネス処理手段と、
前記補正処理において適用される補正適用値と、前記シャープネス処理において適用されるシャープネス適用値とを、前記リフォーカス画像に対する調整を行うためにユーザによって入力される調整値に基づいて統括的に調整する調整手段と
を有することを特徴とする画像処理装置。
For a plurality of parallax images having a parallax with each other, a correction processing unit that performs a correction process for enhancing a difference between the plurality of parallax images,
Refocus processing means for generating a refocus image formed on a predetermined image plane by combining the plurality of parallax images subjected to the correction processing,
Sharpness processing means for performing a sharpness process for adjusting the sharpness of the refocused image,
A correction application value applied in the correction processing and a sharpness application value applied in the sharpness processing are collectively adjusted based on an adjustment value input by a user to perform adjustment on the refocused image. An image processing apparatus comprising: an adjustment unit.
前記ユーザによって入力される前記調整値は1次元の値である
ことを特徴とする請求項1に記載の画像処理装置。
The image processing apparatus according to claim 1, wherein the adjustment value input by the user is a one-dimensional value.
前記ユーザによって入力される前記調整値と、前記調整値の調整可能範囲幅とを示す調整バーの表示を行う表示制御手段を更に有する
ことを特徴とする請求項1又は2に記載の画像処理装置。
The image processing apparatus according to claim 1, further comprising a display control unit configured to display an adjustment bar indicating the adjustment value input by the user and an adjustable range width of the adjustment value. .
前記補正適用値を決定する補正適用値決定手段を更に有し、
前記調整手段は、前記補正適用値決定手段によって決定された前記補正適用値に応じた値を前記調整値が超えた場合に、前記補正適用値に対応する前記値と前記調整値との差分に基づいて前記シャープネス適用値を決定する
ことを特徴とする請求項1乃至3のいずれか1項に記載の画像処理装置。
The apparatus further includes a correction application value determination unit that determines the correction application value,
The adjustment unit, when the adjustment value exceeds a value corresponding to the correction application value determined by the correction application value determination unit, the difference between the value corresponding to the correction application value and the adjustment value The image processing apparatus according to any one of claims 1 to 3, wherein the sharpness application value is determined based on the value.
前記補正適用値を決定する補正適用値決定手段を更に有し、
前記調整手段は、前記補正適用値決定手段によって決定された前記補正適用値に応じた値を前記調整値が下回った場合に、前記調整値に基づいて前記補正適用値を調整し、
前記補正処理手段は、前記調整手段によって調整された前記補正適用値に基づいて前記補正処理を行う
ことを特徴とする請求項1乃至3のいずれか1項に記載の画像処理装置。
The apparatus further includes a correction application value determination unit that determines the correction application value,
The adjustment unit adjusts the correction application value based on the adjustment value when the adjustment value falls below a value corresponding to the correction application value determined by the correction application value determination unit,
The image processing apparatus according to claim 1, wherein the correction processing unit performs the correction processing based on the correction application value adjusted by the adjustment unit.
前記補正適用値を決定する補正適用値決定手段を更に有し、
前記調整手段は、前記補正適用値決定手段によって決定された前記補正適用値を前記調整値に基づいて調整し、
前記補正処理手段は、前記調整手段によって調整された前記補正適用値に基づいて前記補正処理を行う
ことを特徴とする請求項1乃至3のいずれか1項に記載の画像処理装置。
The apparatus further includes a correction application value determination unit that determines the correction application value,
The adjustment unit adjusts the correction application value determined by the correction application value determination unit based on the adjustment value,
The image processing apparatus according to claim 1, wherein the correction processing unit performs the correction processing based on the correction application value adjusted by the adjustment unit.
前記補正適用値決定手段は、前記視差画像におけるコントラスト分布、前記視差画像における輝度分布、及び、前記視差画像における空間周波数分布のうちの少なくともいずれかに基づいて、前記補正適用値を決定する
ことを特徴とする請求項4乃至6のいずれか1項に記載の画像処理装置。
The correction application value determination unit determines the correction application value based on at least one of a contrast distribution in the parallax image, a luminance distribution in the parallax image, and a spatial frequency distribution in the parallax image. The image processing apparatus according to claim 4, wherein:
前記補正適用値決定手段は、前記視差画像に関連付けられた情報に基づいて、前記補正適用値を決定する
ことを特徴とする請求項4乃至6のいずれか1項に記載の画像処理装置。
The image processing apparatus according to any one of claims 4 to 6, wherein the correction application value determination unit determines the correction application value based on information associated with the parallax image.
前記視差画像に関連付けられた前記情報は、絞り値を含み、
前記補正適用値決定手段は、前記絞り値に基づいて前記補正適用値を決定する
ことを特徴とする請求項8に記載の画像処理装置。
The information associated with the parallax image includes an aperture value,
The image processing apparatus according to claim 8, wherein the correction application value determination unit determines the correction application value based on the aperture value.
前記視差画像に関連付けられた前記情報は、焦点距離を含み、
前記補正適用値決定手段は、前記焦点距離に基づいて前記補正適用値を決定する
ことを特徴とする請求項8に記載の画像処理装置。
The information associated with the parallax image includes a focal length,
The image processing apparatus according to claim 8, wherein the correction application value determining unit determines the correction application value based on the focal length.
前記視差画像に関連付けられた前記情報は、ISO感度を含み、
前記補正適用値決定手段は、前記ISO感度に基づいて前記補正適用値を決定する
ことを特徴とする請求項8に記載の画像処理装置。
The information associated with the parallax image includes an ISO sensitivity;
The image processing apparatus according to claim 8, wherein the correction application value determination unit determines the correction application value based on the ISO sensitivity.
前記シャープネス処理手段は、合焦位置からのずれ量に基づいて前記シャープネス処理を行う
ことを特徴とする請求項1乃至11のいずれか1項に記載の画像処理装置。
The image processing apparatus according to claim 1, wherein the sharpness processing unit performs the sharpness processing based on a shift amount from a focus position.
前記シャープネス処理手段は、前記合焦位置からの前記ずれ量を示すデフォーカスマップに基づいて前記シャープネス処理を行う
ことを特徴とする請求項12に記載の画像処理装置。
The image processing apparatus according to claim 12, wherein the sharpness processing unit performs the sharpness processing based on a defocus map indicating the shift amount from the in-focus position.
前記デフォーカスマップは、前記複数の視差画像を撮影によって取得した際に生成されたデフォーカスマップである
ことを特徴とする請求項13に記載の画像処理装置。
The image processing apparatus according to claim 13, wherein the defocus map is a defocus map generated when the plurality of parallax images are acquired by photographing.
前記複数の視差画像に基づいて前記デフォーカスマップを生成するデフォーカスマップ生成手段を更に有する
ことを特徴とする請求項14に記載の画像処理装置。
The image processing apparatus according to claim 14, further comprising a defocus map generating unit configured to generate the defocus map based on the plurality of parallax images.
前記視差画像は、撮像光学系の射出瞳のうちの互いに異なる複数の瞳領域をそれぞれ通過する光束をそれぞれ受光する複数の分割画素を含む単位画素が複数配列され、複数の前記単位画素の各々に対応するように複数のマイクロレンズが配された撮像素子を用いて取得された視差画像である
ことを特徴とする請求項1乃至15のいずれか1項に記載の画像処理装置。
In the parallax image, a plurality of unit pixels including a plurality of divided pixels that respectively receive light fluxes respectively passing through a plurality of different pupil regions of the exit pupil of the imaging optical system are arranged, and each of the plurality of unit pixels is The image processing apparatus according to any one of claims 1 to 15, wherein the image processing apparatus is a parallax image acquired using an imaging element in which a plurality of microlenses are arranged so as to correspond to the parallax image.
互いに視差を有する複数の視差画像間の差を強調するための補正処理において適用される補正適用値と、前記補正処理が行われた前記複数の視差画像を合成することによって得られるリフォーカス画像の鮮鋭度を調整するためのシャープネス処理において適用されるシャープネス適用値とを、前記リフォーカス画像に対する調整を行うためにユーザによって入力される調整値に基づいて統括的に調整するステップと、
前記複数の視差画像に対して、前記補正適用値に基づいて前記補正処理を行うステップと、
前記補正処理が行われた前記視差画像を合成することによって、所定の結像面において結像した前記リフォーカス画像を生成するステップと、
前記リフォーカス画像に対して、前記シャープネス適用値に基づいて前記シャープネス処理を行うステップと
を有することを特徴とすることを特徴とする画像処理方法。
A correction application value applied in a correction process for enhancing a difference between a plurality of parallax images having parallax with each other, and a refocus image obtained by combining the plurality of parallax images subjected to the correction process. A sharpness application value applied in a sharpness process for adjusting sharpness, and a step of comprehensively adjusting based on an adjustment value input by a user to perform adjustment on the refocused image,
Performing the correction process on the plurality of parallax images based on the correction application value;
Generating the refocus image formed on a predetermined image plane by combining the parallax images subjected to the correction processing;
Performing the sharpness process on the refocused image based on the sharpness application value.
コンピュータに、
互いに視差を有する複数の視差画像間の差を強調するための補正処理において適用される補正適用値と、前記補正処理が行われた前記複数の視差画像を合成することによって得られるリフォーカス画像の鮮鋭度を調整するためのシャープネス処理において適用されるシャープネス適用値とを、前記リフォーカス画像に対する調整を行うためにユーザによって入力される調整値に基づいて統括的に調整するステップと、
前記複数の視差画像に対して、前記補正適用値に基づいて前記補正処理を行うステップと、
前記補正処理が行われた前記視差画像を合成することによって、所定の結像面において結像した前記リフォーカス画像を生成するステップと、
前記リフォーカス画像に対して、前記シャープネス適用値に基づいて前記シャープネス処理を行うステップと
を実行させるためのプログラム。
On the computer,
A correction application value applied in a correction process for enhancing a difference between a plurality of parallax images having parallax with each other, and a refocus image obtained by combining the plurality of parallax images subjected to the correction process. A sharpness application value applied in a sharpness process for adjusting sharpness, and a step of comprehensively adjusting based on an adjustment value input by a user to perform adjustment on the refocused image,
Performing the correction process on the plurality of parallax images based on the correction application value;
Generating the refocus image formed on a predetermined image plane by combining the parallax images subjected to the correction processing;
Performing the sharpness process on the refocused image based on the sharpness application value.
JP2016010388A 2016-01-22 2016-01-22 Image processing apparatus and image processing method Active JP6643102B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016010388A JP6643102B2 (en) 2016-01-22 2016-01-22 Image processing apparatus and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016010388A JP6643102B2 (en) 2016-01-22 2016-01-22 Image processing apparatus and image processing method

Publications (2)

Publication Number Publication Date
JP2017130869A JP2017130869A (en) 2017-07-27
JP6643102B2 true JP6643102B2 (en) 2020-02-12

Family

ID=59395135

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016010388A Active JP6643102B2 (en) 2016-01-22 2016-01-22 Image processing apparatus and image processing method

Country Status (1)

Country Link
JP (1) JP6643102B2 (en)

Also Published As

Publication number Publication date
JP2017130869A (en) 2017-07-27

Similar Documents

Publication Publication Date Title
US10681286B2 (en) Image processing apparatus, imaging apparatus, image processing method, and recording medium
US9531960B2 (en) Imaging apparatus for generating HDR image from images captured at different viewpoints and method for controlling imaging apparatus
JP5180407B2 (en) Stereo imaging device and parallax image restoration method
JP6789833B2 (en) Image processing equipment, imaging equipment, image processing methods and programs
US10511781B2 (en) Image pickup apparatus, control method for image pickup apparatus
US10325356B2 (en) Image processing device, image processing method, imaging device, and recording medium for exclusively performing adjustment processing or viewpoint change processing
US9100559B2 (en) Image processing apparatus, image pickup apparatus, image processing method, and image processing program using compound kernel
US9992478B2 (en) Image processing apparatus, image pickup apparatus, image processing method, and non-transitory computer-readable storage medium for synthesizing images
CN108886581B (en) Image processing apparatus, image pickup apparatus, and control method thereof
US9699387B2 (en) Image processing device for processing pupil-divided images obtained through different pupil regions of an imaging optical system, control method thereof, and program
JPWO2012032826A1 (en) Stereo imaging device and stereo imaging method
JP5882789B2 (en) Image processing apparatus, image processing method, and program
US10291899B2 (en) Image processing apparatus, image pickup apparatus, image processing method, and non-transitory computer-readable storage medium for generating restored image
JP6095266B2 (en) Image processing apparatus and control method thereof
JP6516510B2 (en) Image processing apparatus, imaging apparatus, image processing method, image processing program, and storage medium
JP2017060010A (en) Imaging device, method of controlling imaging device, and program
JP6608194B2 (en) Image processing apparatus, control method therefor, and program
JP6976754B2 (en) Image processing equipment and image processing methods, imaging equipment, programs
JP2017032646A (en) Image-capturing device and method for controlling the same
JP2019047365A (en) Image processing apparatus, image processing apparatus control method, imaging apparatus, and program
JP6643102B2 (en) Image processing apparatus and image processing method
JP6800648B2 (en) Image processing device and its control method, program and imaging device
US10334161B2 (en) Image processing apparatus, image processing method, computer program and imaging apparatus
JP2020085967A (en) Image processor, method for controlling the same, and program
JP2019071596A (en) Imaging apparatus and control method therefor

Legal Events

Date Code Title Description
RD05 Notification of revocation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7425

Effective date: 20171214

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20180126

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20190118

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20191008

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200106

R151 Written notification of patent or utility model registration

Ref document number: 6643102

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151