JP2018098582A - Image processing apparatus and method, and imaging apparatus - Google Patents
Image processing apparatus and method, and imaging apparatus Download PDFInfo
- Publication number
- JP2018098582A JP2018098582A JP2016239774A JP2016239774A JP2018098582A JP 2018098582 A JP2018098582 A JP 2018098582A JP 2016239774 A JP2016239774 A JP 2016239774A JP 2016239774 A JP2016239774 A JP 2016239774A JP 2018098582 A JP2018098582 A JP 2018098582A
- Authority
- JP
- Japan
- Prior art keywords
- image
- virtual light
- image signal
- signal
- processing apparatus
- 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
Images
Landscapes
- Image Processing (AREA)
- Studio Devices (AREA)
Abstract
【課題】 リライティングを行う箇所の解像感をできるだけ保持した状態でノイズを低減したリライティング処理を行うこと。【解決手段】 入力画像の各画素の第1の画像信号に対して、平滑化処理を行って第2の画像信号を生成する平滑化処理部(304)と、各画素について、第2の画像信号から、仮想光源から照射された仮想的な光の反射成分である第3の画像信号を生成し、当該第3の画像信号と第1の画像信号とを加算する仮想光源付加処理部(303)と、を有し、平滑化処理部による平滑化処理を、第1の画像信号の信号レベル及び前記仮想的な光の強度の少なくともいずれか一方に基づいて制御する。【選択図】 図3PROBLEM TO BE SOLVED: To perform a rewriting process in which noise is reduced while maintaining a sense of resolution of a portion to be rewritten as much as possible. SOLUTION: A smoothing processing unit (304) that performs smoothing processing on a first image signal of each pixel of an input image to generate a second image signal, and a second image for each pixel. A virtual light source addition processing unit (303) that generates a third image signal, which is a reflection component of virtual light emitted from a virtual light source, from the signal and adds the third image signal and the first image signal. ), And the smoothing process by the smoothing processing unit is controlled based on at least one of the signal level of the first image signal and the virtual light intensity. [Selection diagram] Fig. 3
Description
本発明は、画像処理装置及び方法、及び撮像装置に関し、特に入力された画像の明るさを補正する画像処理装置及び方法、及び撮像装置に関するものである。 The present invention relates to an image processing apparatus and method, and an imaging apparatus, and more particularly to an image processing apparatus and method for correcting the brightness of an input image, and an imaging apparatus.
従来、撮影後の画像中の被写体に対して、仮想的な光源からの光を照射し、リライティングを行う技術が知られている。これにより、環境光によって生じた影などの暗部領域を明るくし、好ましい画像を得ることが可能となる。 Conventionally, a technique for performing relighting by irradiating light from a virtual light source onto a subject in an image after photographing is known. This makes it possible to brighten dark areas such as shadows caused by ambient light and obtain a preferable image.
特許文献1には、撮影画像に対して疑似的なライティング処理を行うライティング処理手段について開示されている。具体的には、顔領域全体の平均輝度よりも低い輝度領域を影領域として抽出し、抽出した影領域の明度を上げる処理を行うことにより、被写体の影を抑えることができる。
上記の特許文献1の方法では、ゲインアップで輝度を上げる事で影領域を低減させているが、ゲインアップすることによって輝度を上げた場合、ノイズ成分も増幅されてしまい、S/N比が悪くなってしまう。これを解決するために、特許文献1ではノイズ除去フィルタをかけているが、単純にノイズ除去処理を行ってしまうと、必要以上にノイズを落とすことによって、被写体の解像感も低下してしまう可能性がある。
In the method of
本発明は上記問題点を鑑みてなされたものであり、リライティングを行う箇所の解像感をできるだけ保持した状態でノイズを低減したリライティング処理を行うことを目的とする。 The present invention has been made in view of the above-described problems, and an object of the present invention is to perform relighting processing with reduced noise while maintaining as much as possible the resolution of the portion where relighting is performed.
上記目的を達成するために、本発明の画像処理装置は、入力画像の各画素の第1の画像信号に対して、平滑化処理を行って第2の画像信号を生成する平滑化手段と、前記各画素について、前記第2の画像信号から、仮想光源から照射された仮想的な光の反射成分である第3の画像信号を生成し、当該第3の画像信号と前記第1の画像信号とを加算する処理手段と、を有し、前記平滑化手段による平滑化処理を、前記第1の画像信号の信号レベル及び前記仮想的な光の強度の少なくともいずれか一方に基づいて制御することを特徴とする。 To achieve the above object, the image processing apparatus of the present invention performs smoothing processing on the first image signal of each pixel of the input image to generate a second image signal, and For each pixel, a third image signal that is a reflection component of virtual light emitted from a virtual light source is generated from the second image signal, and the third image signal and the first image signal are generated. And controlling the smoothing process by the smoothing unit based on at least one of the signal level of the first image signal and the virtual light intensity. It is characterized by.
本発明によれば、リライティングを行う箇所の解像感をできるだけ保持した状態でノイズを低減したリライティング処理を行うことが可能となる。 According to the present invention, it is possible to perform relighting processing with reduced noise while maintaining as much as possible the resolution of the location where relighting is performed.
以下、添付図面を参照して本発明を実施するための形態を詳細に説明する。なお、本実施形態では、画像処理装置として、本発明をデジタルカメラに適用した例について説明する。 DESCRIPTION OF EMBODIMENTS Hereinafter, embodiments for carrying out the present invention will be described in detail with reference to the accompanying drawings. In the present embodiment, an example in which the present invention is applied to a digital camera as an image processing apparatus will be described.
図1は、本発明の実施形態におけるデジタルカメラの構成例を示すブロック図である。 以下、図1を参照して、デジタルカメラ100の構成及び基本動作について説明する。図1に示すデジタルカメラ100において、ズームレンズ、フォーカスレンズを含むレンズ群101(撮像光学系)、及び、絞り機能を備えるシャッター102を介して入射した光は、撮像部103において光電変換される。撮像部103は、CCDやCMOS素子などで構成され、光電変換により得られた電気信号は、画像信号としてA/D変換器104へ出力される。A/D変換器104は、撮像部103から出力されるアナログ画像信号をデジタル画像信号(画像データ)に変換し、画像処理部105に出力する。
FIG. 1 is a block diagram illustrating a configuration example of a digital camera according to an embodiment of the present invention. Hereinafter, the configuration and basic operation of the
画像処理部105は、A/D変換器104からの画像データ、または、メモリ制御部107を介して画像メモリ106から読み出された画像データに対し、ホワイトバランス処理などの色変換処理、ガンマ処理、輪郭強調処理、色補正処理などの各種画像処理を行う。画像処理部105から出力された画像データは、メモリ制御部107を介して画像メモリ106に書き込まれる。画像メモリ106は、画像処理部105から出力された画像データや、表示部109に表示するための画像データを格納する。
The
また、画像処理部105では、撮像した画像データを用いて所定の評価値算出処理を行い、得られた評価値に基づいてシステム制御部50が露光制御、測距制御を行う。これにより、TTL(スルー・ザ・レンズ)方式のAF(オートフォーカス)処理、AE(自動露出)処理、AWB(オートホワイトバランス)処理などを行う。
In the
D/A変換器108は、画像メモリ106に格納されている表示用のデジタルの画像データをアナログ信号に変換して表示部109に供給する。表示部109は、LCD等の表示器上に、D/A変換器108からのアナログ信号に応じた表示を行う。
The D /
コーデック部110は、画像メモリ106に格納された画像データをJPEG、MPEGなどの規格に基いてそれぞれ圧縮符号化する。システム制御部50は符号化した画像データを、インタフェース(I/F)111を介して、メモリカードやハードディスク等の記録媒体112に格納する。
The
また、I/F111を介して記録媒体112から読み出された画像データをコーデック部110により復号して伸長し、画像メモリ106に格納する。そして、画像メモリ106に格納された画像データを、メモリ制御部107、D/A変換器108を介して表示部109に表示することで、画像を再生表示することができる。
Further, the image data read from the
リライティング処理部113は、撮影された画像にリライティング処理(再照明処理)を行う。なお、リライティング処理部113により行われるリライティング処理については、詳細に後述する。
The
システム制御部50はデジタルカメラ100のシステム全体を制御する。不揮発性メモリ121は、EEPROMなどのメモリにより構成され、システム制御部50の処理に必要なプログラムやパラメータなどを格納する。システムメモリ122はシステム制御部50の動作用の定数、変数、不揮発性メモリ121から読みだしたプログラム等を展開するために用いられる。操作部120は、ユーザによる操作を受け付ける。
The
なお、上記の基本動作以外に、システム制御部50は、不揮発性メモリ121に記録されたプログラムを実行することで、後述する本実施形態の各処理を実現する。ここでいうプログラムとは、本実施形態にて後述する各種フローチャートを実行するためのプログラムの事である。この際、システム制御部50の動作用の定数、変数、不揮発性メモリ121から読み出したプログラム等をシステムメモリ122に展開する。
In addition to the above basic operation, the
図2は、画像処理部105の構成を示すブロック図である。以下、図2を参照して、画像処理部105における処理について説明する。なお、本実施形態では、撮像部103はベイヤー配列のカラーフィルタにより覆われているものとする。従って、撮像部103の各画素からはR、G、Bいずれかの画像信号が出力される。
FIG. 2 is a block diagram illustrating a configuration of the
図1のA/D変換器104から画像処理部105に入力された画像信号は、まず、図2の輝度・色信号生成部200に入力される。輝度・色信号生成部200は、入力されたR、G、Bの画像データに対して同時化処理を行い、各画素について色信号RGBを生成する。また、輝度・色信号生成部200は、色信号RGBから輝度信号Yを生成し、生成した輝度信号Yを輪郭強調処理部201へ、色信号RGBをWB増幅部203へ出力する。
The image signal input from the A /
輪郭強調処理部201では、輝度信号Yに対して輪郭強調処理を行い、輝度ガンマ処理部202へ出力する。輝度ガンマ処理部202では輝度信号Yに対してガンマ補正を行い、メモリ制御部107を介して輝度信号Yを画像メモリ106に出力する。
The contour
WB増幅部203は、後述する処理によりシステム制御部50が算出するホワイトバランスゲイン値に基づき、生成された各画素の色信号RGBにゲインをかけ、ホワイトバランスを調整する。色変換処理部204は、ホワイトバランス調整を行った色信号RGBに、例えば、マトリクス演算を行って、所望のカラーバランスへ変換する。色ガンマ処理部205では、色信号RGBにガンマ補正を行う。色差信号生成部206では、RGB信号から色差信号R−Y、B−Yを生成する。
The WB
このようにして生成された輝度信号Y及び色差信号R−Y、B−Y(画像データ)は、画像メモリ106に一旦記憶され、コーデック部110によって圧縮符号化され、記録媒体112に記録される。
The luminance signal Y and the color difference signals RY and BY (image data) generated in this way are temporarily stored in the
次に、画像処理部105から出力された画像に対して、リライティング処理部113でリライティング処理を行う動作について説明する。なお、リライティング処理部113の動作に先立ち、システム制御部50は、リライティング処理部113に設定する制御パラメータを計算し、リライティング処理部113へパラメータを設定する。
Next, an operation in which the relighting
図4(a)は、リライティング処理時のシステム制御部50の処理を示すフローチャートである。以下、図4(a)に従って、リライティング処理時の、システム制御部50の動作について説明する。
FIG. 4A is a flowchart showing processing of the
S401では、操作部120に対するユーザからの操作を受信し、リライティング処理に必要なパラメータをリライティング処理部113へ設定する。具体的には、操作部120に対するユーザ操作によって、不図示のメニューからリライティング処理が選択され、リライティング処理のパラメータが入力される。
In step S <b> 401, an operation from the user for the operation unit 120 is received, and parameters necessary for the relighting process are set in the
リライティング処理のパラメータとしては、一例として、画像内でリライティングを行う領域、すなわち、仮想光源から照射される仮想的な光の中心位置、及び、仮想光源強度(α)(仮想的な光の強度)、仮想的な光の色ゲイン(Rv_Gain、Bv_Gain)とする。なお、本発明はこれらのパラメータに限られるものではなく、例えば、仮想光源から被写体までの距離など、他のパラメータを追加的または上記パラメータに変えて用いてもよい。これらのパラメータをユーザが入力し、リライティング処理部113へ設定する。なお、パラメータの設定方法としては、例えば、任意の値をユーザが入力する方法でも、予め決められたパラメータセットの中から選択する方法でも良い。
As an example of the parameters of the relighting process, the relighting area in the image, that is, the center position of the virtual light emitted from the virtual light source, and the virtual light source intensity (α) (virtual light intensity) , And virtual light color gain (Rv_Gain, Bv_Gain). The present invention is not limited to these parameters. For example, other parameters such as the distance from the virtual light source to the subject may be used additionally or in place of the above parameters. These parameters are input by the user and set in the relighting
リライティングを行う領域の中心位置と、仮想的な光の照射範囲の例を図5(a)に示す。図5(a)において、501はリライティングを行う領域の中心位置、502は仮想的な光の照射範囲を示しており、この照射範囲502内の被写体が仮想的な光の影響を受けるものとする。仮想的な光の照射範囲502は、ユーザが入力した仮想光源強度(α)によって決定し、リライティングを行う領域の中心位置から円形の範囲を照射範囲としており、仮想光源強度(α)が強いほど、照射範囲が広くなる。
FIG. 5A shows an example of the center position of the relighting region and the virtual light irradiation range. In FIG. 5A, 501 indicates the center position of the relighting region, 502 indicates the virtual light irradiation range, and the subject in the
また、仮想的な光の色ゲイン(Rv_Gain、Bv_Gain)は、照射する仮想的な光の色を、撮影時の環境光に対するゲインとして設定し、リライティング処理部113へ設定する。環境光源と仮想光源が同じ場合には、
Rv_Gain=1
Bv_Gain=1
となる。
Further, the virtual light color gains (Rv_Gain, Bv_Gain) are set in the relighting
Rv_Gain = 1
Bv_Gain = 1
It becomes.
S402では、これらの設定された値に基づいて、リライティング処理部113を動作させる。
In S402, the relighting
図3は、リライティング処理部113の構成を示すブロック図である。以下、図3を参照して、リライティング処理部113の構成および動作について説明する。
FIG. 3 is a block diagram illustrating a configuration of the relighting
リライティング処理部113は、画像処理部105により処理されて画像メモリ106に記録された輝度信号Y及び色差信号B−Y、R−Yを読み出し、入力とする。RGB信号変換部301は、入力された輝度信号Y及び色差信号B−Y、R−YをRGB信号に変換し、デガンマ処理部302へ出力する。
The relighting
デガンマ処理部302は、画像処理部105の輝度ガンマ処理部202及び色ガンマ処理部205におけるガンマ補正のガンマ特性と逆の特性の演算(デガンマ処理)を行い、リニアデータに変換する。デガンマ処理部302は、リニアデータに変換後のRGB信号(Rt、Gt、Bt)を、仮想光源付加処理部303及び平滑化処理部304へ出力する。
The
平滑化処理部304では、処理対象のRGB信号を周辺の画素も使用してノイズの平滑化処理を行う。仮想光源付加処理部303は、後述する処理により、平滑化処理部304により生成されたRGB信号(Ra、Ga、Ba)を用いて、仮想光源によるライティング効果を付加し、生成したRGB信号(Rout、Gout、Bout)を出力する。
The smoothing
平滑化処理部304では、ノイズの平滑化処理として、例えば、処理対象画素を中心とした、例えば周辺3×3画素の領域に含まれる9画素を用いて、色成分毎に、周辺画素の色信号値との平均値で置き換える平均値処理を行う。もちろん、平均値処理に用いる周辺画素の領域は、3×3画素に限られるものではなく、適宜設定することができる。本実施形態では、この平均値処理を行う際、処理対象画素と複数の周辺画素の各画素との差分絶対値を算出し、差分絶対値がフィルタリング閾値以下の場合は、平均値処理に使用する画素として扱う。また、差分絶対値がフィルタリング閾値を超えた画素は除外して、平均値処理に使用しない。処理対象画素に近い値を有する画素のみを使用して平均値処理を行うことによって、エッジ等の解像感を維持したままノイズ低減が可能となる。
In the smoothing
ここで、本実施形態における平滑化処理で用いるフィルタリング閾値の算出方法の例について説明する。まず、図6(a)に示すように、処理対象画素の信号レベルに応じたフィルタリング閾値を予め設定しておき、信号レベルに応じてその値を取得する。信号レベルが大きくなるほど、合成する仮想光源によるリライティング処理により増幅されるノイズ量が増えるため、フィルタリング閾値を大きくして、ノイズ抑圧効果が高くなるような特性としても良い。 Here, an example of a filtering threshold calculation method used in the smoothing process in the present embodiment will be described. First, as shown in FIG. 6A, a filtering threshold value corresponding to the signal level of the processing target pixel is set in advance, and the value is acquired according to the signal level. As the signal level increases, the amount of noise amplified by the relighting process using the virtual light source to be combined increases. Therefore, the filtering threshold value may be increased to increase the noise suppression effect.
または、図6(b)に示すように、仮想光源強度の大きさに応じたフィルタリング閾値を予め設定しておき、信号レベルに応じてその値を取得する。仮想光源強度が大きくなるほど、仮想光源によるリライティング処理により増幅されるノイズ量が増えるため、フィルタリング閾値を大きくして、ノイズ抑圧効果が高くなるような特性とする。 Alternatively, as shown in FIG. 6B, a filtering threshold value corresponding to the magnitude of the virtual light source intensity is set in advance, and the value is acquired according to the signal level. As the virtual light source intensity increases, the amount of noise amplified by the relighting process using the virtual light source increases. Therefore, the filtering threshold value is increased so that the noise suppression effect is enhanced.
ただし、本発明はこれに限らず、ある信号レベルからフィルタリング閾値が一定または小さくなるような特性としてもよいし、ある仮想光源強度からフィルタリング閾値が一定または小さくなるような特性としてもよい。 However, the present invention is not limited to this, and may have a characteristic that the filtering threshold is constant or small from a certain signal level, or a characteristic that the filtering threshold is constant or small from a certain virtual light source intensity.
また、図6(a)に示すようなフィルタリング閾値と、図6(b)に示すようなフィルタリング閾値とを合成したフィルタリング閾値を用いても良く、少なくとも、いずれか一方のフィルタリング閾値を用いれば良い。 Further, a filtering threshold value obtained by combining a filtering threshold value as shown in FIG. 6A and a filtering threshold value as shown in FIG. 6B may be used, and at least one of the filtering threshold values may be used. .
更に、平滑化処理は上記の平均値処理に限らず、図6(c)、(d)に示すようなLPF特性を有するフィルタリング処理(ローパスフィルタ処理)で行っても良い。ここで行われるローパスフィルタ処理で用いるLPFのフィルタ特性は、仮想光源強度に応じて適応的に変化する。仮想光源強度が大きいほど、仮想光源によるリライティング処理により増幅されるノイズ量が増えるため、フィルタ特性を狭帯域にして、より強いLPF効果が出るように制御する。例えば、ある仮想光源強度の時に図6(d)に示すようなフィルタ特性で処理を行っていた場合、仮想光源強度がそれよりも大きくなった時には、図6(c)に示すように、周波数fが高い帯域の出力が小さくなるようなフィルタ特性に変化させる。 Further, the smoothing process is not limited to the above average value process, and may be performed by a filtering process (low-pass filter process) having an LPF characteristic as shown in FIGS. The filter characteristics of the LPF used in the low-pass filter processing performed here adaptively change according to the virtual light source intensity. As the virtual light source intensity increases, the amount of noise amplified by the relighting process using the virtual light source increases, so that the filter characteristics are controlled to be narrower and a stronger LPF effect is produced. For example, when processing is performed with a filter characteristic as shown in FIG. 6D at a certain virtual light source intensity, when the virtual light source intensity becomes larger than that, as shown in FIG. The filter characteristics are changed so that the output of the band with high f becomes small.
さらに、このフィルタ特性の制御と、前述したフィルタリング閾値制御を組み合わせたεフィルタ処理でノイズの平滑化処理を行っても良い。 Further, the noise smoothing process may be performed by an ε filter process that combines the control of the filter characteristic and the above-described filtering threshold value control.
このようにして、ノイズを平滑化したRGB信号(Ra、Ga、Ba)を仮想光源付加処理部303へ出力する。
In this way, the RGB signals (Ra, Ga, Ba) whose noise has been smoothed are output to the virtual light source
仮想光源付加処理部303では、仮想光源によるリライティングの効果を入力画像に付加する処理を行う。以下、図4(b)のフローチャートに従って、仮想光源付加処理部303の動作について説明する。仮想光源付加処理部303は、入力されたRGB画像全体に対して、画素単位で処理を行う。
The virtual light source
S410では、処理対象の画素が仮想的な光の照射範囲502内であるかを判定する。処理対象画素503が照射範囲502内にある場合は、S411へ進み、仮想的な光の照射範囲502内ではない場合は、光源の付加処理は行わないため、処理は終了となる。
In S <b> 410, it is determined whether the pixel to be processed is within the virtual
S411では、処理対象である画素に、仮想的な光をあてた場合の仮想光反射色成分(Rv、Gv、Bv)を決定する。この仮想光反射色成分(Rv、Gv、Bv)は、カメラで撮影した場合の特性も含んだ特性である。仮想光反射色成分(Rv、Gv、Bv)は、平滑化処理部304で算出した平滑化画像(Ra、Ga、Ba)に対して、S301で設定された仮想的な光の色ゲイン(Rv_Gain、Bv_Gain)を乗算することで算出する。
Rv=Rv_Gain×Ra
Gv=Ga
Bv=Bv_Gain×Ba
In S411, virtual light reflection color components (Rv, Gv, Bv) when virtual light is applied to the pixel to be processed are determined. This virtual light reflection color component (Rv, Gv, Bv) is a characteristic including a characteristic when it is photographed by a camera. The virtual light reflection color component (Rv, Gv, Bv) is the virtual light color gain (Rv_Gain) set in S301 with respect to the smoothed image (Ra, Ga, Ba) calculated by the smoothing
Rv = Rv_Gain × Ra
Gv = Ga
Bv = Bv_Gain × Ba
S412では、図5(b)に示すように、処理対象画素503と仮想的な光の照射範囲502の中心位置501との距離Dを算出する。距離Dは、処理対象画素503の画像上の座標(X,Y)と、中心位置501の座標(Xc,Yc)とから、以下の式によって算出する。
D=√((Xc−X)2+(Yc−Y)2)
In S412, as shown in FIG. 5B, a distance D between the
D = √ ((Xc−X) 2 + (Yc−Y) 2 )
S413では、仮想光源強度(α)と距離Dに基づき、仮想光反射色成分(Rv、Gv、Bv)を処理対象画素のRGB信号(Rt、Gt、Bt)に対して付加する。すなわち、本実施形態では、仮想的な光で照射された処理対象画素の出力RGB信号(Rout、Gout、Bout)は、下記の式で算出するものとする。ただし、仮想光源強度(α)はα<1である。
Rout=Rt+α×(1/(D2))×Rv
Gout=Gt+α×(1/(D2))×Gv
Bout=Bt+α×(1/(D2))×Bv
In S413, based on the virtual light source intensity (α) and the distance D, the virtual light reflection color components (Rv, Gv, Bv) are added to the RGB signals (Rt, Gt, Bt) of the processing target pixel. That is, in this embodiment, output RGB signals (Rout, Gout, Bout) of the processing target pixel irradiated with virtual light are calculated by the following formula. However, the virtual light source intensity (α) is α <1.
Rout = Rt + α × (1 / (D 2 )) × Rv
Gout = Gt + α × (1 / (D 2 )) × Gv
Bout = Bt + α × (1 / (D 2 )) × Bv
図3に戻り、仮想光源付加処理部303から出力されたRGB信号(Rout、Gout、Bout)は、ガンマ処理部305に入力される。ガンマ処理部305では、入力したRGB信号(Rout、Gout、Bout)に対してガンマ補正を行う。輝度色差信号変換部306では、入力したRGB信号を輝度信号Y及び色差信号B−Y、R−Yに変換して出力する。以上が、リライティング処理部113の動作である。
Returning to FIG. 3, the RGB signals (Rout, Gout, Bout) output from the virtual light source
システム制御部50は、リライティング処理部113が出力した輝度・色差信号を、メモリ制御部107の制御によって、画像メモリ106に蓄積したのち、コーデック部110で圧縮符号化を行う。また、I/F111を介して記録媒体112に記録する。
The
以上説明したように、本実施形態では、実際の環境光が被写体に反射した反射色成分を取得し、取得した反射色成分と、仮想光源強度及び仮想的な光の色ゲインから、仮想光的な光が反射した反射成分(Rv、Gv、Bv)を推定する。そして、推定した仮想光的な光の反射成分を処理対象画素(Rt、Gt、Bt)に加算することで、リライティング処理を行う構成を有する。 As described above, in this embodiment, the reflected color component obtained by reflecting the actual ambient light to the subject is acquired, and from the acquired reflected color component, the virtual light source intensity, and the virtual light color gain, The reflection components (Rv, Gv, Bv) from which the light is reflected are estimated. And it has the structure which performs a relighting process by adding the reflection component of the estimated virtual light-like light to a process target pixel (Rt, Gt, Bt).
さらに、仮想的な光の反射成分(Rv、Gv、Bv)を算出する際に、ノイズ低減処理を適応的に制御することにより、ノイズ成分は抑えつつ、解像感を維持した反射成分を生成する。これにより、処理対象画素のRGB信号(Rt、Gt、Bt)に対して、単純にゲインを加える場合と比較して、ノイズ成分を持ちあげることなく、リライティング効果を付加することが可能となる。 Furthermore, when calculating virtual light reflection components (Rv, Gv, Bv), the noise reduction process is adaptively controlled to generate a reflection component that maintains the sense of resolution while suppressing the noise component. To do. As a result, the relighting effect can be added to the RGB signals (Rt, Gt, Bt) of the pixel to be processed without raising the noise component as compared with the case of simply adding gain.
また、本実施形態では、説明の簡略化のために、仮想的な光の照射範囲502を図5で示す円で説明したが、仮想的な光の影響範囲はどのようなものであっても構わない。例えば、図示しない顔検出処理を使用することによって、人物の顔領域を抽出し、その領域を基準として仮想的な光の影響範囲としてもよく、仮想的な光の照射方向や対象被写体との距離に応じて、円を変形させても良い。もしくは、図示しない測距センサを用いて、撮影画像の画素単位の距離情報を算出し、距離が近いものだけに仮想的な光をあてる処理を行っても良い。
Further, in the present embodiment, the virtual
また、リライティングを行う領域の中心位置と処理対象画素の距離Dの算出方法は、本実施形態に限定するものではなく、どのような算出方法を取っても良い。例えば、カメラの位置および被写体位置を三次元位置として取得し、三次元での距離を計算しても良い。 Further, the calculation method of the distance D between the center position of the relighting region and the processing target pixel is not limited to this embodiment, and any calculation method may be used. For example, a camera position and a subject position may be acquired as a three-dimensional position, and a three-dimensional distance may be calculated.
また、仮想的な光を付加する場合に、距離Dの二乗に反比例する式で計算したが、仮想的な光の付加量をこの方式で算出するものに限定するものではない。例えば、距離Dに反比例するものや、ガウス分布的に照射範囲が変化する式であっても良い。 Further, in the case of adding virtual light, the calculation is performed using an equation that is inversely proportional to the square of the distance D, but the amount of virtual light addition is not limited to that calculated by this method. For example, an expression that is inversely proportional to the distance D or an expression in which the irradiation range changes in a Gaussian distribution may be used.
<他の実施形態>
なお、本発明は、撮像装置で得られた画像を外部の画像処理装置に送信し、当該画像処理装置において、送信された画像に対して上述したリライティング処理を実施する構成としてもよい。
<Other embodiments>
Note that the present invention may be configured such that an image obtained by an imaging apparatus is transmitted to an external image processing apparatus, and the above-described relighting process is performed on the transmitted image in the image processing apparatus.
また、本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。 Further, the present invention supplies a program that realizes one or more functions of the above-described embodiment to a system or apparatus via a network or a storage medium, and one or more processors in a computer of the system or apparatus execute the program. It can also be realized by a process of reading and executing. It can also be realized by a circuit (for example, ASIC) that realizes one or more functions.
50:システム制御部、103:撮像部、105:画像処理部、111:インタフェース、113:リライティング処理部、121:不揮発性メモリ、122:システムメモリ、120:操作部、303:仮想光源付加処理部、304:平滑化処理部 50: System control unit, 103: Imaging unit, 105: Image processing unit, 111: Interface, 113: Relighting processing unit, 121: Non-volatile memory, 122: System memory, 120: Operation unit, 303: Virtual light source addition processing unit 304: Smoothing processing unit
Claims (13)
前記各画素について、前記第2の画像信号から、仮想光源から照射された仮想的な光の反射成分である第3の画像信号を生成し、当該第3の画像信号と前記第1の画像信号とを加算する処理手段と、を有し、
前記平滑化手段による平滑化処理を、前記第1の画像信号の信号レベル及び前記仮想的な光の強度の少なくともいずれか一方に基づいて制御することを特徴とする画像処理装置。 Smoothing means for performing a smoothing process on the first image signal of each pixel of the input image to generate a second image signal;
For each pixel, a third image signal that is a reflection component of virtual light emitted from a virtual light source is generated from the second image signal, and the third image signal and the first image signal are generated. And processing means for adding
An image processing apparatus, wherein smoothing processing by the smoothing means is controlled based on at least one of the signal level of the first image signal and the virtual light intensity.
前記平滑化処理を行う対象画素と、当該対象画素の複数の周辺画素の各画素との信号レベルの差の絶対値を求め、
前記複数の周辺画素のうち、前記絶対値が予め決められた閾値よりも大きい周辺画素を除外した周辺画素と、前記対象画素の信号レベルの平均値を求めることを特徴とする請求項1乃至3のいずれか1項に記載の画像処理装置。 The smoothing means includes
Find the absolute value of the difference in signal level between the target pixel to be smoothed and each of the peripheral pixels of the target pixel,
4. The average value of signal levels of peripheral pixels excluding peripheral pixels having an absolute value larger than a predetermined threshold among the plurality of peripheral pixels and the signal level of the target pixel is obtained. The image processing apparatus according to any one of the above.
前記撮像手段から出力された前記画像信号を前記第1の画像信号として処理する、請求項1乃至9のいずれか1項に記載の画像処理装置と
を有することを特徴とする撮像装置。 Imaging means for outputting an image signal obtained by photoelectrically converting incident light; and
An image processing apparatus comprising: the image processing apparatus according to claim 1, wherein the image signal output from the image capturing unit is processed as the first image signal.
処理手段が、前記各画素について、前記第2の画像信号から、仮想光源から照射された仮想的な光の反射成分である第3の画像信号を生成する生成工程と、
前記処理手段が、前記第3の画像信号と前記第1の画像信号とを加算する処理工程と、を有し、
前記平滑化工程における平滑化処理を、前記第1の画像信号の信号レベル及び前記仮想的な光の強度の少なくともいずれか一方に基づいて制御することを特徴とする画像処理装置。 A smoothing step in which the smoothing means performs a smoothing process on the first image signal of each pixel of the input image to generate a second image signal;
A generating step of generating, for each of the pixels, a third image signal that is a reflection component of virtual light emitted from a virtual light source, from the second image signal;
The processing means includes a processing step of adding the third image signal and the first image signal,
An image processing apparatus that controls a smoothing process in the smoothing step based on at least one of a signal level of the first image signal and an intensity of the virtual light.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2016239774A JP6742231B2 (en) | 2016-12-09 | 2016-12-09 | Image processing apparatus and method, and imaging apparatus |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2016239774A JP6742231B2 (en) | 2016-12-09 | 2016-12-09 | Image processing apparatus and method, and imaging apparatus |
Publications (3)
| Publication Number | Publication Date |
|---|---|
| JP2018098582A true JP2018098582A (en) | 2018-06-21 |
| JP2018098582A5 JP2018098582A5 (en) | 2020-01-23 |
| JP6742231B2 JP6742231B2 (en) | 2020-08-19 |
Family
ID=62633193
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2016239774A Active JP6742231B2 (en) | 2016-12-09 | 2016-12-09 | Image processing apparatus and method, and imaging apparatus |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP6742231B2 (en) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN113592998A (en) * | 2021-06-29 | 2021-11-02 | 北京百度网讯科技有限公司 | Relighting image generation method and device and electronic equipment |
| WO2022025413A1 (en) * | 2020-07-29 | 2022-02-03 | 삼성전자 주식회사 | Electronic device and method for generating training data of artificial intelligence learning model by electronic device |
| KR20220055380A (en) * | 2020-10-26 | 2022-05-03 | 서울과학기술대학교 산학협력단 | Image conversion apparatus and method thereof |
Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2003008935A (en) * | 2001-06-20 | 2003-01-10 | Sony Corp | Image processing method and apparatus |
| JP2009111541A (en) * | 2007-10-29 | 2009-05-21 | Sony Corp | Image processing apparatus and image processing method |
| JP2009238009A (en) * | 2008-03-27 | 2009-10-15 | Toshiba Corp | Image processing apparatus and method |
| US7805017B1 (en) * | 2001-02-01 | 2010-09-28 | At&T Intellectual Property Ii, L.P. | Digitally-generated lighting for video conferencing applications |
| JP2010534432A (en) * | 2007-07-26 | 2010-11-04 | オムロン株式会社 | System and method for enhancing digital image processing with noise removal function |
| JP2016005203A (en) * | 2014-06-18 | 2016-01-12 | キヤノン株式会社 | Image processing apparatus and control method thereof |
| JP2016171391A (en) * | 2015-03-11 | 2016-09-23 | キヤノン株式会社 | Image processing apparatus and control method thereof |
-
2016
- 2016-12-09 JP JP2016239774A patent/JP6742231B2/en active Active
Patent Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US7805017B1 (en) * | 2001-02-01 | 2010-09-28 | At&T Intellectual Property Ii, L.P. | Digitally-generated lighting for video conferencing applications |
| JP2003008935A (en) * | 2001-06-20 | 2003-01-10 | Sony Corp | Image processing method and apparatus |
| JP2010534432A (en) * | 2007-07-26 | 2010-11-04 | オムロン株式会社 | System and method for enhancing digital image processing with noise removal function |
| JP2009111541A (en) * | 2007-10-29 | 2009-05-21 | Sony Corp | Image processing apparatus and image processing method |
| JP2009238009A (en) * | 2008-03-27 | 2009-10-15 | Toshiba Corp | Image processing apparatus and method |
| JP2016005203A (en) * | 2014-06-18 | 2016-01-12 | キヤノン株式会社 | Image processing apparatus and control method thereof |
| JP2016171391A (en) * | 2015-03-11 | 2016-09-23 | キヤノン株式会社 | Image processing apparatus and control method thereof |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2022025413A1 (en) * | 2020-07-29 | 2022-02-03 | 삼성전자 주식회사 | Electronic device and method for generating training data of artificial intelligence learning model by electronic device |
| KR20220055380A (en) * | 2020-10-26 | 2022-05-03 | 서울과학기술대학교 산학협력단 | Image conversion apparatus and method thereof |
| KR102558643B1 (en) * | 2020-10-26 | 2023-07-24 | 서울과학기술대학교 산학협력단 | Image conversion apparatus and method thereof |
| CN113592998A (en) * | 2021-06-29 | 2021-11-02 | 北京百度网讯科技有限公司 | Relighting image generation method and device and electronic equipment |
Also Published As
| Publication number | Publication date |
|---|---|
| JP6742231B2 (en) | 2020-08-19 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US10574961B2 (en) | Image processing apparatus and image processing method thereof | |
| JP6445844B2 (en) | Imaging device and method performed in imaging device | |
| US10861136B2 (en) | Image processing apparatus, image processing method, and storage medium | |
| JP6463177B2 (en) | Image processing apparatus and control method thereof | |
| JP6381404B2 (en) | Image processing apparatus and method, and imaging apparatus | |
| JP6376934B2 (en) | Image processing apparatus, imaging apparatus, image processing method, and program | |
| JP2018041380A (en) | Image processing apparatus, image processing method, and program | |
| JP6887853B2 (en) | Imaging device, its control method, program | |
| JP6742231B2 (en) | Image processing apparatus and method, and imaging apparatus | |
| JP2010193002A (en) | Imaging apparatus, image processing method and program | |
| US11523064B2 (en) | Image processing apparatus, image processing method, and storage medium | |
| JP2020004007A (en) | Image processing device, image processing method, and program | |
| US10021314B2 (en) | Image processing apparatus, image capturing apparatus, method of controlling the same, and storage medium for changing shading using a virtual light source | |
| JP2021064884A (en) | Image processing apparatus, imaging apparatus, control method, program, and imaging system | |
| US11368630B2 (en) | Image processing apparatus and image processing method | |
| JP2017068513A (en) | Image processing apparatus and method, program, and storage medium | |
| JP6541416B2 (en) | IMAGE PROCESSING APPARATUS, IMAGE PROCESSING METHOD, PROGRAM, AND STORAGE MEDIUM | |
| JP2020024581A (en) | Image processing apparatus, image processing method, and program | |
| JP2019024256A (en) | Image processing apparatus and image processing method | |
| JP6849351B2 (en) | Image processing equipment, image processing methods, and programs | |
| JP6616674B2 (en) | Image processing apparatus and method, and imaging apparatus | |
| JP2021087125A (en) | Image processing device, control method thereof, and program | |
| JP2018207429A (en) | Imaging apparatus |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20191204 |
|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20191204 |
|
| TRDD | Decision of grant or rejection written | ||
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20200625 |
|
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20200629 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20200728 |
|
| R151 | Written notification of patent or utility model registration |
Ref document number: 6742231 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |