JP6333095B2 - Imaging apparatus, control method therefor, and program - Google Patents
Imaging apparatus, control method therefor, and program Download PDFInfo
- Publication number
- JP6333095B2 JP6333095B2 JP2014141775A JP2014141775A JP6333095B2 JP 6333095 B2 JP6333095 B2 JP 6333095B2 JP 2014141775 A JP2014141775 A JP 2014141775A JP 2014141775 A JP2014141775 A JP 2014141775A JP 6333095 B2 JP6333095 B2 JP 6333095B2
- Authority
- JP
- Japan
- Prior art keywords
- exposure
- imaging
- image
- value
- frame
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000003384 imaging method Methods 0.000 title claims description 74
- 238000000034 method Methods 0.000 title claims description 40
- 238000012937 correction Methods 0.000 claims description 55
- 238000012545 processing Methods 0.000 description 58
- 238000006243 chemical reaction Methods 0.000 description 23
- 230000008569 process Effects 0.000 description 23
- 238000001514 detection method Methods 0.000 description 22
- 238000011161 development Methods 0.000 description 20
- 238000010586 diagram Methods 0.000 description 15
- 230000008859 change Effects 0.000 description 11
- 230000015572 biosynthetic process Effects 0.000 description 10
- 238000004891 communication Methods 0.000 description 10
- 238000012986 modification Methods 0.000 description 10
- 230000004048 modification Effects 0.000 description 10
- 238000003786 synthesis reaction Methods 0.000 description 10
- 239000000203 mixture Substances 0.000 description 9
- 230000003287 optical effect Effects 0.000 description 7
- 238000005375 photometry Methods 0.000 description 7
- 230000006870 function Effects 0.000 description 6
- 230000035945 sensitivity Effects 0.000 description 4
- 230000007423 decrease Effects 0.000 description 3
- 230000002194 synthesizing effect Effects 0.000 description 3
- 238000009825 accumulation Methods 0.000 description 2
- 238000013459 approach Methods 0.000 description 2
- 239000002131 composite material Substances 0.000 description 2
- 238000013461 design Methods 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 238000012935 Averaging Methods 0.000 description 1
- 239000000654 additive Substances 0.000 description 1
- 230000000996 additive effect Effects 0.000 description 1
- 230000003321 amplification Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000015556 catabolic process Effects 0.000 description 1
- 238000006731 degradation reaction Methods 0.000 description 1
- 230000004907 flux Effects 0.000 description 1
- 238000003702 image correction Methods 0.000 description 1
- 230000009191 jumping Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 239000011159 matrix material Substances 0.000 description 1
- 238000003199 nucleic acid amplification method Methods 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 238000003825 pressing Methods 0.000 description 1
- 230000011514 reflex Effects 0.000 description 1
- 229920006395 saturated elastomer Polymers 0.000 description 1
Images
Landscapes
- Exposure Control For Cameras (AREA)
- Studio Devices (AREA)
Description
本発明は、撮像装置およびその制御方法ならびにプログラムに関し、特にハイダイナミックレンジ画像の生成技術に関する。 The present invention relates to an imaging apparatus, a control method thereof, and a program, and more particularly to a technique for generating a high dynamic range image.
異なる露出(アンダー露出、オーバー露出)で撮影された複数枚の画像を合成して、画像のダイナミックレンジを拡大するハイダイナミックレンジ(HDR)合成といわれる技術が知られている。この技術では、各画像の適正露出部分を合成することで、白とびや黒つぶれを抑制し、暗部から明部まで良好な階調性を有する画像を得ることができる。 A technique called high dynamic range (HDR) composition is known in which a plurality of images taken with different exposures (underexposure and overexposure) are combined to expand the dynamic range of the images. In this technique, by combining the appropriately exposed portions of each image, it is possible to suppress overexposure and underexposure and to obtain an image having good gradation from a dark portion to a bright portion.
HDR合成技術は、静止画を撮影する場合のみならず、動画の撮影を行う場合にも適用可能な技術である。動画の撮影時にHDR合成(動画HDR撮影)を行う構成には、例えば動画の各フレームに異なる露出(アンダー露出、オーバー露出)を交互に適用して撮影する構成が知られている。このように撮影した場合、例えばフレームレートを60fpsとして動画を撮影すると、HDR合成されて記録される動画のフレームレートは半分の30fpsとなる。 The HDR synthesizing technique is a technique applicable not only when shooting a still image but also when shooting a moving image. As a configuration for performing HDR composition (moving image HDR shooting) when shooting a moving image, for example, a configuration in which different exposures (under exposure and over exposure) are alternately applied to each frame of the moving image is known. When shooting is performed in this manner, for example, when a moving image is shot at a frame rate of 60 fps, the frame rate of the moving image recorded by HDR synthesis is 30 fps, which is half.
動画の各フレームを用いてHDR撮影を行うためには、各フレームに適用する露出条件を順次制御する必要がある。特許文献1には、フレームの輝度のピーク検出を毎フレーム行って、アンダー露出を適用して撮影するフレームに対する露出時間を制御する技術が開示されている。また、特許文献2には、まず基準とする露出条件と階調変換特性を設定した撮影を行って、得られた信号レベル(即ちAEセンサの測光結果)に基づいて本撮影時に用いる各フレームの各露出と階調変換特性の組み合わせを適応的に選択する技術が開示されている。
In order to perform HDR shooting using each frame of a moving image, it is necessary to sequentially control exposure conditions applied to each frame. Japanese Patent Application Laid-Open No. H10-228688 discloses a technique for performing peak detection of the luminance of a frame every frame and controlling an exposure time for a frame to be shot by applying underexposure. Also, in
ところで、動画HDR撮影では、AE(自動露出制御)を動画の撮像中に行う場合がある。静止画のHDR撮影では、本撮影の前にAEによる露出制御が行われるのに対し、動画HDR撮影では、AEによる露出制御を動画の撮像中に並行して行う必要がある。露出制御の処理中には適正露出が徐々に変化するため、動画HDR撮影に用いるアンダー露出とオーバー露出の露出差が想定と異なるものになってしまう。従来であれば、現像後の露出をアンダー露出およびオーバー露出で撮影された画像で揃えるために、予めデジタルゲインやガンマなどの画像処理パラメータを決定しておくことができる。しかし、AEによる露出制御により想定と異なる露出差が生じた場合、現像後のHDR合成の際にアンダー露出およびオーバー露出で撮影された画像の間の輝度階調の連続性が低下し、例えば部分的に境界が発生するトーンジャンプが発生することが想定される。 By the way, in moving image HDR shooting, AE (automatic exposure control) may be performed during moving image shooting. In HDR shooting of still images, exposure control by AE is performed before main shooting, whereas in moving image HDR shooting, exposure control by AE needs to be performed in parallel with the shooting of moving images. Since the appropriate exposure gradually changes during the exposure control process, the exposure difference between the underexposure and overexposure used for moving image HDR shooting becomes different from the assumption. Conventionally, image processing parameters such as digital gain and gamma can be determined in advance in order to align the exposure after development with an image captured with underexposure and overexposure. However, when an exposure difference that is different from what is assumed occurs due to exposure control by AE, the luminance gradation continuity between images shot with underexposure and overexposure is reduced during HDR composition after development. It is assumed that a tone jump in which a boundary is generated occurs.
本発明は、上述の従来技術の問題点に鑑みてなされたものであり、動画によるHDR撮影において自動露出制御を行う場合に、生成画像の階調の連続性を向上させることが可能な撮像装置およびその制御方法ならびプログラムを提供することを目的とする。 The present invention has been made in view of the above-described problems of the prior art, and is an imaging apparatus capable of improving the continuity of the gradation of a generated image when automatic exposure control is performed in HDR shooting using a moving image. And its control method and program.
この課題を解決するため、例えば本発明の撮像装置は以下の構成を備える。すなわち、撮像手段と、所定のフレームレートで露出の異なる画像を繰り返し撮像するように撮像手段を制御する撮像制御手段と、撮像手段に入射させる光量を調節する露出制御手段と、撮像手段による撮像中に露出制御手段により光量が調節され、露出の異なる画像の露出差が所定の値から変動した場合、露出制御手段により調節された露出で撮像されたフレームの画像を該変動した露出差に基づいて補正する補正手段と、補正手段により補正されたフレームの画像を含む複数のフレームの画像を合成する合成手段と、を有することを特徴とする。 In order to solve this problem, for example, an imaging apparatus of the present invention has the following configuration. That is, an imaging unit, an imaging control unit that controls the imaging unit to repeatedly capture images with different exposures at a predetermined frame rate, an exposure control unit that adjusts the amount of light incident on the imaging unit, and during imaging by the imaging unit When the exposure control means adjusts the amount of light and the exposure difference of images with different exposures fluctuates from a predetermined value, the image of the frame captured with the exposure adjusted by the exposure control means is based on the changed exposure difference. The image processing apparatus includes correction means for correcting, and combining means for combining images of a plurality of frames including the image of the frame corrected by the correcting means.
本発明によれば、動画によるHDR撮影において自動露出制御を行う場合に、生成画像の階調の連続性を向上させることが可能になる。 According to the present invention, it is possible to improve the continuity of the gradation of a generated image when automatic exposure control is performed in HDR shooting using a moving image.
(実施形態1)
以下、本発明の例示的な実施形態について、図面を参照して詳細に説明する。なお、以下では撮像装置の一例として、露出を変更して動画を取得可能な撮像機能を備えるデジタルカメラに本発明を適用した例を説明する。しかし、本発明でいう撮像装置は、デジタルカメラに限らず、このような撮像機能を備える任意の電子機器にも適用可能である。これらの電子機器には、例えば携帯電話機、ゲーム機、タブレット端末、パーソナルコンピュータ、時計型や眼鏡型の情報端末などが含まれてよい。
(Embodiment 1)
Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the drawings. Hereinafter, as an example of the imaging apparatus, an example in which the present invention is applied to a digital camera having an imaging function capable of acquiring a moving image by changing exposure will be described. However, the imaging apparatus referred to in the present invention is not limited to a digital camera, and can be applied to any electronic device having such an imaging function. These electronic devices may include, for example, a mobile phone, a game machine, a tablet terminal, a personal computer, a clock-type or glasses-type information terminal.
(1 デジタルカメラの構成)
図1(a)は、実施形態の撮像装置の一例としてのデジタルカメラ100の、主として光学部材やセンサ等の配置を示す断面図である。デジタルカメラ100は、レンズ交換可能ないわゆるデジタル一眼レフカメラであり、カメラ本体1と交換レンズ2を有している。
(1 Digital camera configuration)
FIG. 1A is a cross-sectional view mainly illustrating an arrangement of optical members, sensors, and the like of a
カメラ本体1における撮像素子10は、例えばCMOSイメージセンサやCCDイメージセンサであり、複数の画素(蓄積型光電変換素子)が配列されている。また、受光部に配置される画素以外に、画素信号の増幅回路や信号処理用の周辺回路などが形成されている。撮像素子10は、画素に対する電荷の蓄積時間や電荷の読み出しを調節することで、撮像素子による露出制御が可能な電子シャッター機能を実現する。交換レンズ2の備える撮影光学系により結像された被写体光学像を各画素で光電変換し、画素単位の画像信号を出力する。
An
撮像素子10の前方近傍に設けられていたメカニカルシャッター11は、撮像素子10の露出タイミングおよび露出時間を調節する。半透過性の主ミラー3と、主ミラー3の背面に配置された第1の反射ミラー7は、撮影時には上部に跳ね上がる。第2の反射ミラー8は、第1の反射ミラー7が反射した光束をさらに反射し、AFセンサ9に入射させる。AFセンサ9は、例えば画素数が撮像素子10よりも少ない撮像素子であってよい。第1の反射ミラー7、第2の反射ミラー8およびAFセンサ9は、撮影画面内の任意の位置での位相差検出方式で焦点検出を行うための構成である。なお、ライブビュー表示および動画記録時には常時主ミラー3が上部に跳ね上がった状態となるため、露出制御や焦点調節制御は撮像面の画像情報を使用して行うこととなる。
A
AEセンサ6は、測光用センサであり、ペンタプリズム4および第3の反射ミラー5で反射された被写体の光束を受光して測光を行う。AEセンサ6は受光部を複数の領域に分割し、領域ごとに被写体の輝度情報を出力できる。
The
ペンタプリズム4によってファインダー光学系が構成される。ペンタプリズム4で反射された被写体光学像は図示しないアイピースから観察可能である。またペンタプリズム4で反射された光束のうち、主ミラー3によって反射されてピント板12によって拡散された光線の光軸外の一部は、AEセンサ6に入射する。
A finder optical system is configured by the
交換レンズ2は、取り外し可能なレンズであり、カメラ本体1に設けられたレンズマウントの接点を通じて、必要に応じてカメラ本体1と通信を行う。
The
図1(b)は、図1(a)に示したデジタルカメラ100のカメラ本体1とその交換レンズ2の機能構成例を示すブロック図である。なお、図1(b)に示す機能ブロックの1つ以上は、ASICやプログラマブルロジックアレイ(PLA)などのハードウェアによって実現されてもよいし、CPUやMPU等のプログラマブルプロセッサがソフトウェアを実行することによって実現されてもよい。また、ソフトウェアとハードウェアの組み合わせによって実現されてもよい。従って、以下の説明において、異なる機能ブロックが動作主体として記載されている場合であっても、同じハードウェアが主体として実現されうる。
FIG. 1B is a block diagram illustrating a functional configuration example of the
制御部21は、例えば内部にALU(Arithmetic and Logic Unit)33、ROM34、RAM35やA/Dコンバータ31、タイマー32、シリアル通信ポート(SPI)36等を内蔵したワンチップマイクロコンピュータである。制御部21は、例えばROM34に記憶されたプログラムを実行することにより、カメラ本体1および交換レンズ2の動作を制御する。例えば、制御部21は後述する動画HDR撮影に係る処理を実行するためカメラ本体1の各部を制御する。制御部21のA/Dコンバータ31には、AFセンサ9およびAEセンサ6の出力信号が入力される。
The
信号処理部25は、制御部21の指示に従って撮像素子10を制御し、撮像素子10によって出力された信号にA/D変換および信号処理を適用して画像信号を得る。信号処理部25は、得られた画像信号を記録する場合には、予め定められた形式で画像信号を圧縮し、記憶部26に出力する。また、後述する動画HDR撮影に必要な現像処理や合成処理を行う。
The
メモリ28は、DRAM等により構成される記憶装置である。メモリ28は、信号処理部25が種々の信号処理を行う際のワーク用メモリとして使用されるほか、後述する表示部27に画像を表示する際のVRAMとして使用される。
The
表示部27は、液晶ディスプレイパネル等で構成され、カメラの設定値やメッセージ、メニュー画面等の情報や撮像した画像を表示する。表示部27は制御部21からの指示により制御される。記憶部26は例えばフラッシュメモリ等の不揮発性メモリであり、撮像された画像信号が信号処理部25から入力される。
The
モーター22は、制御部21の制御に従い、主ミラー3および第1の反射ミラー7のアップ・ダウンやメカニカルシャッター11のチャージを行う。
The
操作部23は、ユーザがカメラを操作するために用いるスイッチなどの入力デバイス群である。操作部23には撮影準備動作の開始および撮影開始を指示するためのレリーズスイッチや、撮影モードを選択するための撮影モード選択スイッチ、方向キー、決定キー等が含まれる。
The
接点部29は、交換レンズ2と通信を行うための接点であり、制御部21のシリアル通信ポートの入出力信号が接続される。シャッター駆動部24は制御部21の出力端子に接続されてメカニカルシャッター11を駆動する。
The
交換レンズ2には、接点部29と対をなす接点部50が設けられている。接点部50には、制御部21と同様のワンチップマイクロコンピュータであるレンズ制御部51が接続され、制御部21との通信が可能である。レンズ制御部51は、例えばROMに記憶されたプログラムを実行し、制御部21からの指示に基づいて交換レンズ2の動作を制御する。また、交換レンズ2の状態などの情報を制御部21に通知する。
The
フォーカスレンズ駆動部52は、レンズ制御部51の指示に基づいてフォーカスレンズを駆動し、ズーム駆動部53は、レンズ制御部51の指示に基づいて交換レンズの画角を変更する。
The focus
絞り駆動部54は、レンズ制御部51の指示に基づいて絞りの開口量を調節し、撮像素子10に入射する光量を調節する。
The
交換レンズ2がカメラ本体1に装着されると、レンズ制御部51および制御部21とは接点部29および50を介してデータ通信が可能になる。例えば、制御部21が焦点検出や露出演算を行うために必要なレンズ固有の光学的な情報や距離エンコーダに基づいた被写体距離に関する情報等が、レンズ制御部51から制御部21へデータ通信によって出力される。また、制御部21が焦点検出や露出演算により得られた焦点や絞りの制御情報をレンズへ送信すると、レンズ制御部51は、受信した制御情報に従って絞り等を制御する。また、接点部29は、レンズ側の接点部50を介して、交換レンズ2に備えられた図示しないモーターやアクチュエータに対して電力を供給する。
When the
(2.動画HDR撮影に係る一連の動作)
次に、図2を参照して、動画HDR撮影に係る一連の動作を説明する。なお、本処理は、制御部21がROM34に記憶されたプログラムをRAM35の作業用領域に展開し、実行することにより実現される。
(2. A series of operations related to movie HDR shooting)
Next, a series of operations related to moving image HDR shooting will be described with reference to FIG. This process is realized by the
S11において制御部21は、たとえば操作部23に含まれる電源スイッチがオンされるなどにより動作が可能になると、交換レンズ2のレンズ制御部51と通信を行なって、焦点検出や測光に必要な各種レンズの情報を得るなどの初期化処理を行う。
In S11, when the
S12において制御部21は、操作部23に含まれる動画モード切り替えスイッチがオンされたことを検出すると、メモリ28の配置処理などを動画モードへと切り替えて、撮像を開始する。
In S12, when the
S13において制御部21は、操作部23に含まれるスイッチにおいて動画HDR撮影に切り替えられたことを検出すると、撮影モードを動画HDR撮影モードに切り替える。
In S13, when the
S14において制御部21は、適正露出条件を設定する。動画HDR撮影モードでは、予め設定された露出、例えば適正露出に対して+1EVのオーバー露出および−1EVのアンダー露出の設定で撮像を交互に繰り返す撮像制御を行う。本実施形態では、各露出を設定するための適正露出を算出する。適正露出の算出は、一度適正露出の算出を行って適正露出に制御した後であっても、シーンが変わった場合などに対応するために撮像中に定期的に実行される。
In S14, the
以下に、本ステップにおける適正露出の算出処理について、より詳細に説明する。S12において開始された動画モードでは、制御部21は、いわゆるライブビュー画像(またはスルー画像)と呼ばれる、表示部27を電子ビューファインダとして機能させる動画撮影を実行する。この撮影はいわゆる電子シャッターによる撮影を連続的に実行することで行われる。この状態ではミラーアップしている状態となるため、AEセンサ6によって測光することができない。
Hereinafter, the process for calculating the appropriate exposure in this step will be described in more detail. In the moving image mode started in S12, the
制御部21は、ライブビュー画像の撮影中に定期的に撮像素子10による測光用の信号取得を行って測光を行う。例えばライブビュー画像の1フレームを測光用の画像信号として取得すればよい。制御部21は、画像信号を撮像素子10から読み出し、A/D変換を行ってRAMに格納する。制御部21は、取得した画素信号を、図3に示すように、画素領域を例えば9×7個のブロックに分割して、各ブロックに含まれる画素信号を用いてブロックごとに輝度情報を算出する。各ブロックの輝度情報は、例えばブロック内の全画素の輝度を平均することにより算出する。なお、輝度の演算は、例えばAPEX(Additive System of Photographic Exposure )表現におけるBv値(適正露出における被写体の輝度)に換算して行う。これらの輝度情報に基づいてY1〜Y7およびX1〜X9の射影データを算出する。一般にm行×n列といった2次元配列のデータから行方向や列方向に加算或いは加算平均した1次元配列のデータに変換する手法のことを2次元から1次元への投影又は射影という。また、列方向や行方向に加算した結果得られた1次元配列のデータのことを射影像或いは射影データと呼ぶ。本実施形態においては射影データY1〜Y7およびX1〜X9を以下のように算出する。
X1=Σ(x1)÷7 但し、x=1〜7
X2=Σ(x2)÷7 但し、x=1〜7
X3=Σ(x3)÷7 但し、x=1〜7
X4=Σ(x4)÷7 但し、x=1〜7
X5=Σ(x5)÷7 但し、x=1〜7
X6=Σ(x6)÷7 但し、x=1〜7
X7=Σ(x7)÷7 但し、x=1〜7
X8=Σ(x8)÷7 但し、x=1〜7
X9=Σ(x9)÷7 但し、x=1〜7
Y1=Σ(1y)÷9 但し、y=1〜9
Y2=Σ(2y)÷9 但し、y=1〜9
Y3=Σ(3y)÷9 但し、y=1〜9
Y4=Σ(4y)÷9 但し、y=1〜9
Y5=Σ(5y)÷9 但し、y=1〜9
Y6=Σ(6y)÷9 但し、y=1〜9
Y7=Σ(7y)÷9 但し、y=1〜9
制御部21は、算出された射影データY1〜Y7およびX1〜X9の中の最大値Emaxを求め、求めた最大値Emaxに基づいて第1の露出補正値γを算出する。具体的には、Emaxの値がBv値で10を超える場合に下記の式により算出する。
The
X1 = Σ (x1) ÷ 7 where x = 1-7
X2 = Σ (x2) ÷ 7 where x = 1-7
X3 = Σ (x3) ÷ 7 where x = 1-7
X4 = Σ (x4) ÷ 7 where x = 1-7
X5 = Σ (x5) ÷ 7 where x = 1-7
X6 = Σ (x6) ÷ 7 where x = 1-7
X7 = Σ (x7) ÷ 7 where x = 1-7
X8 = Σ (x8) ÷ 7 where x = 1-7
X9 = Σ (x9) ÷ 7 where x = 1-7
Y1 = Σ (1y) ÷ 9 where y = 1-9
Y2 = Σ (2y) ÷ 9 where y = 1-9
Y3 = Σ (3y) ÷ 9 where y = 1-9
Y4 = Σ (4y) ÷ 9 where y = 1-9
Y5 = Σ (5y) ÷ 9 where y = 1-9
Y6 = Σ (6y) ÷ 9 where y = 1-9
Y7 = Σ (7y) ÷ 9 where y = 1-9
The
γ=(Emax−10)×0.25
ここで、この第1の露出補正値γは、Bv値で10を超えるような高輝度被写体は明るく写った方が好ましい場合が多いという経験則に従い露出補正を行うものである。係数0.25はあくまで例であって、高輝度被写体をどの程度明るく写るようにするかで最適値を決めれば良い。また画像信号全体の平均Bv(AVEBv)を下記の式により算出する
AVEBv=Σ(Xx+Yy)÷(7×9)
但し、x=1〜7、y=1〜9
これによりBv値に対する制御値は、
適正露出:AVEBv+γ
となる。
γ = (E max −10) × 0.25
Here, the first exposure correction value γ performs exposure correction in accordance with an empirical rule that it is often preferable that a high-luminance subject having a Bv value exceeding 10 is bright. The coefficient 0.25 is merely an example, and an optimal value may be determined depending on how bright a high-luminance subject is to be captured. Further, the average Bv (AVEBv) of the entire image signal is calculated by the following formula: AVEBv = Σ (Xx + Yy) ÷ (7 × 9)
However, x = 1-7, y = 1-9
As a result, the control value for the Bv value is
Proper exposure: AVEBv + γ
It becomes.
制御部21は、このBv値に対する制御値に基づいて予め設定したプログラム線図を参照して露出条件を決定する。図4は、本動画HDR撮影において使用するプログラム線図の例を示している。実線は適正露出を、破線はオーバー露出を、二点鎖線はアンダー露出をそれぞれ示している。右側縦軸は絞り値Avを、左側縦軸および上部横軸はBv値を示している。また、下部横軸はTv(シャッタースピード)を示しているが、図4に示す線図では、1/30秒以上の場合についてはISO感度を用いて表示している。これは、動画撮影においてはフレームレートに応じてTv値の限界があるためである。例えば図4において適正露出が30/fpsである場合、オーバー側の最長秒設定も1/30秒となるため、これよりも露出が増大する側はISO感度を上げることで実現することを示している。制御部21は、上述したBv値に対する制御値をもとに、プログラム線図に対応したデータテーブルを参照して露出条件(ISO感度、絞り、秒時)を決定し、当該条件に合わせて露出制御を行う。
The
S15において制御部21は、焦点検出処理および求めた焦点位置にレンズを駆動させる。制御部21は、撮像素子10で焦点検出用の信号蓄積を行う。なお、AFセンサ9を用いた焦点検出を行わないのは、動画記録を行うために、ミラーアップして連続的な撮影を行っているためである。従って、撮像素子10で得られる画像信号から、コントラスト検出方式の焦点検出を行う。蓄積が終了すると蓄積された信号を読み出しながらA/D変換を行い、焦点検出用の画像信号としてRAM35に格納する。さらにS11で得ているレンズ情報と焦点検出用の画像信号とから、撮影画面の各部の焦点状態を演算し、合焦させる焦点検出領域を決定する。なお、焦点検出領域の位置の決定は他の方法によってもよく、例えば予め操作部23を通じてユーザから指定されている焦点検出領域に決定してもよいし、顔検出などの画像認識技術を用いて人物の顔に焦点検出領域を設定してもよい。制御部21は、決定した焦点検出領域における焦点状態とレンズ情報とに従って、焦点検出領域に合焦させるためのレンズ移動量を算出し、レンズ制御部51を通じてフォーカスレンズ駆動部52を制御する。これにより、交換レンズ2は焦点検出領域内の被写体に対して合焦状態となる。フォーカスレンズを駆動すると距離エンコーダの情報が変化するので、制御部21は交換レンズ2内の各種レンズ情報の更新も行う。
In S15, the
S16において制御部21は、オーバー露出を実現するために処理対象となるフレームにおいて絞り制御が必要かを判定する。なお、HDR合成に用いる一組のフレームのうち、オーバー露出となるフレームをオーバーフレーム、アンダー露出となるフレームをアンダーフレームという。まず、例えばあるタイミングで設定している適正露出条件がBv11であり、画像信号から取得した輝度がBv10であるとする。図4に示したプログラム線図上ではISO感度が200から400へ1EV変化しただけで絞り値Avは変化しない。この場合、制御部21は絞り制御不要と判断してS18に処理を進め、現在の露出でオーバー露出の撮像(オーバー撮像)を行う。
In S <b> 16, the
一方、あるタイミングで設定している適正露出条件がBv8であり、画像信号から取得した輝度がBv10であるとする。プログラム線図上では絞りが2.8から5.6へ変化しており、絞り値Avは2EV変化している。この場合、制御部21は絞り制御が必要と判定して、S17に処理を進める。
On the other hand, it is assumed that the proper exposure condition set at a certain timing is Bv8, and the luminance acquired from the image signal is Bv10. On the program diagram, the aperture changes from 2.8 to 5.6, and the aperture value Av changes by 2 EV. In this case, the
S17において制御部21は、オーバーフレームにおいてオーバー露出に対する露出条件を算出すると、算出結果を用いて露出制御を行う。オーバー露出の露出条件の算出には、適正露出条件の算出と同様に図4のプログラム線図例を参照する。図中では波線がオーバー露出を示している。先に求めたBv値に対する制御値は適正露出に関する値であるから、以下のように、オーバー露出に対してさらに制御値を修正してからプログラム線図を参照すればよい。制御部21は、算出した露出条件に基づいてレンズ2に対して露出制御を行わせると、S18において基準フレーム、即ちオーバー露出となるフレームにおいてオーバー撮像を行なう。
オーバー:AVEBv+γ+α 但し、αは適正露出に対する露出差
なお、詳細はS21の処理において後述するが、ここで決定したオーバー撮像の露出条件は目標値であり、実際にはあるタイミングから数フレームをかけて目標の露出条件へと近づけていく処理がなされる。
In S17, when the
Over: AVEBv + γ + α where α is the exposure difference with respect to proper exposure
Although the details will be described later in the processing of S21, the over-imaging exposure condition determined here is a target value, and in reality, a process of approaching the target exposure condition over several frames from a certain timing is performed. The
S19において制御部21は、処理対象のフレームを1フレーム進めて、アンダーフレームにおいてアンダー露出を実現するために絞り制御が必要かを判定する。アンダー露出を実現するための絞り制御が必要か否かは、S16におけるオーバー露出の絞り制御の判定と同様に行う。制御部21は、絞り制御が不要と判定した場合は、S23に処理を進めてオーバー現像の処理を行わせる。一方、制御部21は、絞り制御が必要と判定した場合、処理をS20に進めて、アンダー露出の算出および露出制御を行う。
In S19, the
S20において制御部21は、図4に示したプログラム線図例を参照して適正露出と同様にアンダー露出に対する露出条件を算出し、算出結果を用いて露出制御を行う。図4においては、1点鎖線がアンダー露出を示している。先に求めたBv値に対する制御値は適正露出に関する値であるから、以下のように、アンダー露出に対してさらに制御値を修正してからプログラム線図を参照すればよい。制御部21は、処理を完了するとS21に処理を進めて、実際の露出差を取得する。
アンダー:AVEBv+γ―β 但し、βは適正露出に対する露出差
S21において制御部21は、露出制御による露出の調節後の、オーバー露出とアンダー露出における実際の露出差を取得する。以下、本ステップの詳細を図5(a)および図5(b)を参照して説明する。動画では露出の変化は滑らかにした方が視認性は良いため、直後のフレームがS17で決定した露出条件になるように制御するのではなく、複数フレームに渡って徐々に目標値に近づけてゆく。このため、目標値に向けた絞り制御の動作を継続しながら、オーバーフレームとアンダーフレームの実際の絞り値Avをフレームごとに取得してゲイン修正に反映させる。
In S20, the
Under: AVEBv + γ-β where β is the exposure difference from the proper exposure
In S <b> 21, the
まず、数フレーム先までの露出条件を予め決定する。実際に変化したシーンの輝度値Bvに対し、例えば絞り値Avを何フレームかけて目標値まで変化させるかを設定し、各フレームの露出条件を設定する。図5(a)には、Bv値の変化とそれに伴うAv値を4フレームかけて変化させる例を示している。図5(a)における点線は、Bv値に対する実際の制御値を示している。 First, exposure conditions up to several frames ahead are determined in advance. For example, how many frames the aperture value Av is changed to the target value is set for the actually changed scene brightness value Bv, and the exposure condition of each frame is set. FIG. 5A shows an example of changing the Bv value and the associated Av value over 4 frames. A dotted line in FIG. 5A indicates an actual control value with respect to the Bv value.
ここで重要なのはオーバーフレームとアンダーフレームの露出差であり、図5(b)には、当該露出差をBv値に対する制御値を用いて示している。なお、Bv値に対する制御値とは、測光したシーンのBv値そのものではなく、オーバーフレームおよびアンダーフレームの露出条件を決めるためのBv値である。図5(b)の例では、絞り駆動によるAv値の変化が始まる前の状態では想定の露出差が実現できていることを示している(図5(b)中に示す「b」で表す露出差)。上述したシーンの例では、Bv値が8(暗いシーン)から10(明るいシーン)へと変わるシーンであり、b=2EVとなる。しかし、HDR合成に用いられる1組のフレームのうち、1枚目となるオーバー撮像から開始したAv値変動期間の期間中は、オーバーフレームとアンダーフレームの露出差は2a+bとなる。本来、オーバーフレームとアンダーフレームの露出差を予め定めた露出差bとなるべきであるが、同時にAvを制御することによって適正露出自体が変動しているため、誤差露出の2aが発生する。
What is important here is the exposure difference between the overframe and the underframe, and FIG. 5B shows the exposure difference using a control value for the Bv value. The control value for the Bv value is not the Bv value of the photometric scene but the Bv value for determining the overframe and underframe exposure conditions. In the example of FIG. 5 (b), it is shown that the assumed exposure difference can be realized in the state before the change of the Av value due to the aperture driving starts (represented by “b” shown in FIG. 5 (b)). Exposure difference). In the above-described example of the scene, the Bv value changes from 8 (dark scene) to 10 (bright scene), and b = 2EV. However, the exposure difference between the overframe and the underframe is 2a + b during the Av value variation period starting from the first over-imaging in one set of frames used for HDR synthesis. Originally, the exposure difference between the overframe and the underframe should be a predetermined exposure difference b. However, since the proper exposure itself is fluctuated by controlling Av at the same time,
制御部21は、HDR合成に用いられるオーバーフレームとアンダーフレームの絞り値をレンズ制御部51から取得して、実際の露出差を取得する。制御部21は実際の露出差を取得すると、信号処理部25によるゲイン修正の処理に利用させるため、当該実際の露出差を信号処理部25へ出力する。
The
S22において信号処理部25は、制御部21から取得した実際の露出差に基づいて、画像信号に対してゲイン修正を行うための現像パラメータを生成する。なお、本実施形態における現像パラメータは後述するホワイトバランス係数である。
In S <b> 22, the
ゲイン修正においてはオーバーフレームかアンダーフレームのいずれかを基準にする必要があるが、本実施形態ではアンダーフレームを基準にオーバーフレームのゲインを修正する。図5(a)および図5(b)に示した例では、Av値の変動が小絞りの(絞り径が小さくなる)方向であって、Av値の制御開始フレームがオーバーフレームであるため、アンダー露出が想定よりも大きくなる。このため、Av値の制御中の誤差露出は、上述した通り2a分となる。よってゲインを修正する方向はゲインアップとなり、即ち誤差露出の影響を低下させるものとなる。ゲイン修正はデジタルゲインにより実現し、図6に示すホワイトバランス部802で生成されたホワイトバランス係数をかけることによって反映する。ホワイトバランス係数は、ホワイトバランス係数修正部809においてオーバーとアンダーのBv値に対する制御値を取得し、ホワイトバランス係数807を修正することで生成される。以下に、ホワイトバランス係数807を修正する例を示す。
ここでWBCoefx(x=R、G1、G2、B)は、修正前のホワイトバランス係数であり、Bvtは、各フレームにおけるBv値、bは図5(b)に示す目標値である露出差である。修正前のホワイトバランス係数については、「太陽光」や「くもり」など予めカメラにプリセットされている場合は各々設定されているホワイトバランス係数を用いる。オートホワイトバランスに設定されている場合は、例えば画像信号から白っぽい領域を検出してその領域の平均R、G、Bのバランスを整えるような公知のホワイトバランス係数を算出する方法を用いて行うことができる。
In gain correction, it is necessary to use either the overframe or the underframe as a reference, but in this embodiment, the overframe gain is corrected based on the underframe. In the example shown in FIG. 5A and FIG. 5B, the variation of the Av value is in the direction of a small diaphragm (diaphragm diameter decreases), and the control start frame of the Av value is an overframe. Underexposure is greater than expected. For this reason, the error exposure during the control of the Av value is 2a as described above. Therefore, the gain correction direction is gain up, that is, the influence of error exposure is reduced. The gain correction is realized by digital gain, and is reflected by applying the white balance coefficient generated by the
Here WBCoefx (x = R, G1, G2, B) is a white balance coefficient before correction, Bv t is exposure difference Bv value in each frame, b is the target value shown in FIG. 5 (b) It is. When the white balance coefficient before correction is preset in the camera in advance, such as “sunlight” or “cloudy”, the set white balance coefficient is used. When the auto white balance is set, for example, a known white balance coefficient that detects a whitish area from the image signal and adjusts the average R, G, B balance of the area is used. Can do.
S23において、信号処理部25は現像処理を行う。即ち、修正されたホワイトバランス係数を用いてホワイトバランスを含むオーバー現像を行う。ここで、画像信号に対する現像処理の詳細について、図6を参照して説明する。各機能ブロックの処理は、オーバーフレームとアンダーフレームのそれぞれで取得された画像信号に対して行われる。
In S23, the
被写体像は、結像光学系(レンズ)によって撮像素子10の撮像素子上に結像されて光電変換される。撮像素子10は、例えば、一般的な原色カラーフィルタを備える単板カラー撮像素子である。原色カラーフィルタは、各々650nm、550nm、450nm近傍に透過主波長帯を持つ3種類の色フィルタからなり、各々R(赤)、G(緑)、B(青)の各バンドに対応する色プレーンを撮影する。単板カラー撮像素子では、この色フィルタは画素ごとに空間的に配列され、各画素は各々単一の色プレーンにおける光の強度を得ることしかできない。このため撮像素子からは色モザイク画像が出力される(801および810)。ホワイトバランス部802では、白くあるべき領域のR、G、B値が同じ信号値になるようなゲインをR、G、B各画素値にかける。色補間部803では色モザイク画像を補間することによって、全ての画素においてR、G、Bの色情報が揃ったカラー画像を生成する。生成されたカラー画像は、マトリクス変換部804およびガンマ変換部805を経て基本的なカラー画像が生成される。
The subject image is imaged on the image sensor of the
ハイダイナミックレンジ合成に先だって、異なる露出で撮影したオーバーフレームとアンダーフレームの各々の輝度レベルを揃えておく必要がある。ガンマ変換部805において適用されるゲインは、白飛びや黒潰れをしないように設定する必要があるため一律なゲインではなくガンマ曲線を用いて行う。これらのガンマ曲線の設計に関しては、例えば2EVの露出差によるゲイン、即ちアンダーに対して2倍のゲインやオーバーに対して1/2のゲインをかけたときに、ガンマ曲線と特性が同じになるように設計する。こうすることで、輝度域に応じて複数枚の画像を切り換えた際に、境界を滑らかにすることができる。色輝度調整部806で画像の見栄えを改善するための処理がカラー画像に対し行われ、例えば、彩度強調、色相補正、エッジ強調といった画像補正が行われる。色輝度調整部806による処理が終わると現像処理が完了する。
Prior to the high dynamic range composition, it is necessary to align the brightness levels of the overframe and underframe taken with different exposures. The gain applied in the
静止画のHDR合成の場合は、さらに、合成前に一方の画像を他方を基準として、手振れ等により生じた動きに対して空間的な位置合わせがなされることが一般的である。しかし、動画HDR合成の場合は、オーバーとアンダーの撮影間隔が静止画撮影と比較して格段に短く、位置合わせを行うとフレームレートが低下したような描写になること、処理の計算量などの理由により位置合わせ処理を行わなくてもよい。信号処理部25は、オーバー現像の処理を完了するとS24に処理を進める。
In the case of still image HDR synthesizing, it is general that spatial alignment is performed with respect to movement caused by camera shake or the like with one image as a reference before synthesizing. However, in the case of moving image HDR composition, the over and under shooting intervals are much shorter than still image shooting, and if the alignment is performed, the frame rate is reduced, the amount of processing calculation, etc. The alignment process may not be performed for a reason. When completing the over-development process, the
S24において撮像素子10は、アンダーフレームにおいて、アンダー露出を設定して撮像(アンダー撮像)を行なう。そして、S25において信号処理部25は、得られた画像信号に対する現像パラメータの生成と現像処理を行う。但し、本実施形態では、ゲイン修正はオーバー撮像された画像信号にのみ適用されるため、アンダー撮像された画像信号に対する現像パラメータの修正は行わない。
In S <b> 24, the
さらにS26において信号処理部25は、オーバーフレームとアンダーフレームのそれぞれの画像信号に対する現像処理が完了すると、それぞれオーバー現像画像およびアンダー現像画像を用いて、HDR合成部816にてHDR合成処理を行う。
Furthermore, in S26, when the development processing for the overframe and underframe image signals is completed, the
HDR合成処理について図7を参照して説明する。横軸は基準輝度を、縦軸は各画像を加算合成する際の合成比率を表す。合成する際の基準輝度の閾値Y1より暗い領域はオーバー現像画像のみを使用し、基準輝度の閾値Y2より明るい領域ではアンダー現像画像のみを用いる。また、基準輝度の閾値付近の境界Y1〜Y2の中間領域では、合成比率を徐々に変化させることで画像の切り替えを滑らかにすることができる。基準輝度として用いるのは、本実施形態ではアンダーフレームとなる。以上の処理により信号処理部は、HDR画像を生成して生成したHDR画像をメモリ28に格納する。
The HDR synthesis process will be described with reference to FIG. The horizontal axis represents the reference luminance, and the vertical axis represents the composition ratio when the images are added and combined. Only an over-developed image is used for an area darker than the reference luminance threshold Y1 when combining, and only an under-developed image is used for an area brighter than the reference luminance threshold Y2. Also, in the intermediate region between the boundaries Y1 and Y2 near the reference luminance threshold, the image switching can be made smooth by gradually changing the composition ratio. In this embodiment, the underframe is used as the reference luminance. Through the above processing, the signal processing unit stores the HDR image generated by generating the HDR image in the
S27において制御部21は、操作部23を介してREC釦等の押下による撮像終了の指示があったかを判定する。撮像終了の指示がないと判定した場合は、再び処理をS14に戻してS14〜S26までの処理を繰り返す。一方、撮像終了の指示があったと判定した場合は、生成したHDR動画を圧縮するためにS28に処理を進める。
In S <b> 27, the
S28において信号処理部は、メモリに格納していたHDR動画を所定の形式で圧縮したうえで、S29においてメモリなどの記憶部26に記録して一連の動作を終了する。
In S28, the signal processing unit compresses the HDR moving image stored in the memory in a predetermined format, records it in the
上述した本実施形態の処理について図8に示すシーケンス図を参照して各処理のタイミング等を説明する。なお、t〜t+3フレームは、動画記録中のある一区間に着目していることを示している。このため、動画記録の開始直後に行われる初期化処理等の説明は省略している。また、当区間中は、Av値がある目標値に向かって変動している。 Regarding the processing of the present embodiment described above, the timing of each processing will be described with reference to the sequence diagram shown in FIG. Note that frames t to t + 3 indicate that attention is paid to a certain section during moving image recording. For this reason, description of initialization processing performed immediately after the start of moving image recording is omitted. Further, during this period, the Av value fluctuates toward a certain target value.
tフレームの開始前であるt−1フレームにおいて、レンズ2は、制御部21の指示に応じて所定のAv値へと制御し(1006)、そのAv値をオーバー撮像用のAv値として記憶部26が記憶する(1007)。
In the t−1 frame before the start of the t frame, the
tフレームにおいて撮像素子10ではオーバー撮像を開始する(1008)。信号処理部25は、オーバー撮像により得られた画像信号(オーバー画像信号)を読み出して、記憶部26に格納する(1009)。オーバー撮像が終了すると、レンズ2はt+1フレーム用に絞り制御を行ったのち(1010)、記憶部26がアンダー撮像用のAv値を記憶する。記憶部26は、オーバー撮像用のAv値とアンダー撮像用Av値を出力(1011)し、信号処理部25はこれらのAv値を用いてホワイトバランスゲインの修正を行う(1012)。信号処理部25は、ホワイトバランスゲインの修正が終わるとオーバー現像を行って現像画像を記憶部26に格納する(1013)。
In the t frame, the
t+1フレームの開始タイミングに入ると、撮像素子10は別途アンダー撮像を開始する(1014)。信号処理部25は、アンダー撮像によって得られた画像(アンダー画像信号)を読み出して記憶部26に格納する(1015)。信号処理部25は撮像後速やかにアンダー現像を開始する(1016)。また、t−1フレームと同様にレンズ2は、制御部21の指示に応じてオーバー撮像用に絞り制御を行い(1017)、記憶部26がそのオーバー撮像用Av値を記憶する(1018)。
When the start timing of the t + 1 frame is entered, the
t+2フレーム開始のタイミングになると、tフレームと同様に、撮像素子10がオーバーフレームの撮像を開始する(1019)。信号処理部25は、同時に現像後のオーバー現像画像とアンダー現像画像を用いてHDR合成を行い(1020)、生成した画像を記憶部26に記憶させる(1022)。以降は、再び1060からの処理を撮像終了まで繰り返す。
When it is time to start the t + 2 frame, the
なお、本実施形態では、オーバーフレームとアンダーフレームの2枚の画像信号を用いる例を説明したが、3枚以上のフレームを繰り返し取得する場合についても適用可能である。例えば3枚のフレームの露出を段階的に変化させている場合、3枚のフレームで生じる露出差をフレーム枚数で平滑化して、平滑化した露出差から得られるゲイン修正を基準となるフレーム以外の画像信号に対して適用すればよい。また、連続するフレーム間で露出差があればよいので、例えば、オーバーフレームとアンダーフレームの代わりに、適正フレームとアンダーフレーム、オーバーフレームと適正フレーム、などであってもよい。 In the present embodiment, an example in which two image signals of an over frame and an under frame are used has been described. However, the present embodiment can also be applied to a case where three or more frames are repeatedly acquired. For example, when the exposure of three frames is changed in stages, the exposure difference generated in the three frames is smoothed by the number of frames, and gain correction obtained from the smoothed exposure difference is used for other than the reference frame. What is necessary is just to apply with respect to an image signal. Further, since there is only an exposure difference between consecutive frames, for example, instead of an overframe and an underframe, a proper frame and an underframe, an overframe and a proper frame, and the like may be used.
以上説明したように本実施形態では、自動露出の制御によって絞り値が変化することにより適正露出が変化する場合であっても、オーバーフレームとアンダーフレームの絞り値に基づいて実際の露出差を取得するようにした。そして取得した実際の露出差に基づいてデジタルゲインでゲイン修正を行った画像をHDR合成するようにした。このようにすることで、動画HDR撮影において自動露出制御を行う場合に、生成画像の階調の連続性を向上させることが可能になる。即ち、オーバーフレームとアンダーフレームの露出差を想定通りに制御することが可能となり、HDR合成された画像においてトーンジャンプなどの画質劣化を抑えることができる。 As described above, in the present embodiment, even when the proper exposure changes due to the change of the aperture value by the automatic exposure control, the actual exposure difference is obtained based on the overframe and underframe aperture values. I tried to do it. Then, HDR synthesis is performed on an image whose gain has been corrected with digital gain based on the acquired actual exposure difference. This makes it possible to improve the continuity of the gradation of the generated image when automatic exposure control is performed in moving image HDR shooting. That is, the exposure difference between the overframe and the underframe can be controlled as expected, and image quality degradation such as tone jump can be suppressed in the HDR synthesized image.
(実施形態2)
次に実施形態2について説明する。実施形態1では、ホワイトバランスのデジタルゲインを用いて画像信号にゲイン修正を行った。これに対して、本実施形態では、ガンマ特性を用いて画像信号にゲイン修正を行なう。また、実施形態1ではAv値の変動が開始するフレームがHDR合成に用いるオーバーフレームとアンダーフレームのうち1枚目である場合を例に説明したが、本実施形態では、Av値の変動が2枚目のフレームから開始する例を説明する。なお、本実施形態のデジタルカメラ100の構成は実施形態1と同一でよい。このため、同一の構成については同一の符号を付して重複する説明は省略し、相違点について重点的に説明する。
(Embodiment 2)
Next,
まず、本実施形態における動画HDR撮影に係る一連の動作を、図15を参照して説明する。なお、図2と共通する処理については共通の参照番号を付して説明を省略する。 First, a series of operations related to moving image HDR shooting in the present embodiment will be described with reference to FIG. Note that the processes common to those in FIG.
S150において制御部21は、実際の露出差を取得する。なお、本実施形態では、例えば、設定している露出条件がBv10で設定されたものであり、取得した輝度がBv8であるとする。この場合、図4に示すプログラム線図上では、絞り値が5.6から2.8へ2EV変化している。即ち、明るいシーンから暗いシーンへとシーンが変化するため、絞りは絞り値が小さくなる側(絞り径が大きくなる側)へと変動していく。図9(a)は、この場合のAv値と、Bv値に対する制御値の変動を示している。Bv値が低下した後にAv値の変動が開始されている。Av値の変動が開始するフレームがHDR合成に用いられるフレームの組の2枚目つまり、アンダーフレームとなっている。そのため、オーバーフレームとアンダーフレームの露出誤差がAv値の変動開始直後および終了直前と変動中とで異なってくる。Av値の変動開始ではオーバーフレームが、終了直前ではアンダーフレームがそれぞれ想定通りの露出となり、フレームの組のもう一方のフレームがAv値の変動分を含むケースである。この場合の露出差は、図9(b)のようになる。なお、想定の露出差は実施形態1と同様にbである。
そして、制御部21は実際の露出差を取得する。実施形態1ではレンズ2との通信により実際の露出を取得する例を示したが、本実施形態では実際の露出差を推定により取得する。これは、ハード上の制約などで必ずしもレンズ通信による絞り値の取得が困難な場合やレンズとの通信に遅延が生じる場合、処理の高速化を図る場合等に有効である。露出差の推定方法について図10を参照して説明する。制御部21は、S14において算出した適正露出条件に加えて、何フレームかけて露出を変動させていくかの情報を用いて、所定のタイミングiにおけるBv値に対する制御値(Bvi)を以下の式を用いて算出する。そして、制御部21は算出したBv値に対する制御値と上述したAv値変動中のフレームにおける露出誤差とを用いて露出差を求める。
S151において信号処理部25は、推定演算により推定した実際の露出に基づいてゲイン修正を行うための現像パラメータを生成する。ゲイン修正においてはオーバーフレームかアンダーフレームのいずれかが基準フレームとする必要があるが、本実施形態ではオーバーフレームを基準にアンダーフレームのゲインを修正することを考える。本実施形態では、Av値の変動が開放絞りの方向であり、Av値の制御開始フレームがHDR合成フレームに用いる1組のフレームの2枚目となるため、アンダー露出が想定よりも小さくなりAv値の制御中の露出誤差は上述の通りaもしくは2a分となる。よって、ゲインを修正する方向はゲインアップとなる。本実施形態におけるゲインアップはガンマ特性を用いたガンマ変換により実現し、図11に示すガンマ変換部805が修正されたガンマテーブルを用いてガンマ変換することによって反映する。ガンマテーブルによるゲイン調整を行うことで、より柔軟に階調特性を制御した現像画像を生成できる。
In S150, the
And the
In S151, the
ガンマテーブルの修正は、ガンマテーブル修正部1310においてガンマテーブル1307を修正することによって行う。ガンマテーブル修正部1310は、ガンマテーブル1307を修正するために必要なオーバーとアンダーのBv値に対する制御値を、制御Bv値推定部1309より取得する。また制御Bv値推定部1309は、この推定に必要な撮影情報1308として、Av変動開始フレーム、Av変動終了フレーム、Av制御フレーム数、処理対象のフレームナンバーを取得する。
The gamma table is corrected by correcting the gamma table 1307 in the gamma
ガンマテーブル修正部1310におけるガンマテーブルの具体的な修正方法について、図12を参照して説明する。図12に示すグラフにおいて横軸はガンマ変換への入力信号値であるがLogスケール表示されており点線で刻まれる1刻みは1段分を示している。また実線の縦線で示されるポイントは適正露出を示している。縦軸はガンマ変換の出力信号値を示している。実線のガンマテーブルはアンダーフレーム用の変換特性を、一点鎖線のガンマテーブルはオーバーフレーム用の変換特性をそれぞれ示している。この図ではアンダーフレームとオーバーフレームはおおむね3段分の露出差がある。二点鎖線のガンマテーブルは修正後のガンマテーブルを示しており、これは元の実線の変換特性を水平方向にシフトすることで得られるガンマテーブルである。矢印で示されるシフト量は先述したaまたは2aとして求めればよい。そして、S23において信号処理部25は、修正されたガンマテーブルを用いて現像処理を行う。
A specific method for correcting the gamma table in the gamma
以上の実施形態2に係る処理について、シーケンス図を図13に示す。本実施形態では、Bv値に対する制御値を推測するため、tフレームにおいてアンダーフレーム用のBv値に対する制御値を推定して記憶部26に格納する(1601)。そして、アンダーフレーム用のゲイン即ちガンマテーブルを修正するため、t+1フレームにおいて、アンダーフレームの現像前にゲイン値(ガンマテーブル)の修正を行い(1602)、アンダー現像を行う(1016)。 A sequence diagram of the processing according to the second embodiment is shown in FIG. In this embodiment, in order to estimate the control value for the Bv value, the control value for the Bv value for the underframe is estimated at t frame and stored in the storage unit 26 (1601). Then, in order to correct the gain for the underframe, that is, the gamma table, the gain value (gamma table) is corrected before developing the underframe (1602) and the underdevelopment is performed (1016).
なお、本実施形態ではガンマテーブルを修正してゲイン修正を行うようにしたが、必ずしもガンマテーブルでなくてもよく、所定の階調補正特性を有する補正用のテーブルであれば同様の動画HDR撮影が実現できる。 In this embodiment, the gain correction is performed by correcting the gamma table. However, it is not always necessary to use the gamma table, and the same moving picture HDR shooting is possible as long as the correction table has a predetermined gradation correction characteristic. Can be realized.
以上説明したように、本実施形態では、露出差を用いてゲイン修正を行う際に、露出差を用いてガンマテーブルを修正し当該ガンマテーブルを用いてゲイン修正を行うようにした。このようにすることで、動画HDR撮影において自動露出制御を行う場合に、より柔軟に階調特性を制御した現像画像を生成して合成画像の階調の連続性を向上させることが可能になる。また、実際の露出差については、露出を複数フレームにわたって変更する制御情報に基づいて実際の露出差を推定するようにした。レンズとの通信に遅延が生じる場合や処理の高速化を図ることができる。 As described above, in the present embodiment, when the gain correction is performed using the exposure difference, the gamma table is corrected using the exposure difference, and the gain correction is performed using the gamma table. In this way, when automatic exposure control is performed in moving picture HDR shooting, it is possible to generate a developed image with more controlled gradation characteristics and improve the continuity of the gradation of the composite image. . As for the actual exposure difference, the actual exposure difference is estimated based on control information for changing the exposure over a plurality of frames. When a delay occurs in the communication with the lens, the processing speed can be increased.
(実施形態2の変形例)
さらに実施形態2の変形例について説明する。実施形態1および実施形態2では、共に修正ゲインについてゲインアップする例について説明した。本変形例では、ガンマ変換によって修正ゲインについてゲインダウンする場合について説明する。本変形例では、修正ゲインの適用において、特に高輝度領域の飽和値が変わらないようにするための修正ゲインの適用を新たに行う。
(Modification of Embodiment 2)
Further, a modification of the second embodiment will be described. In the first embodiment and the second embodiment, the example in which the gain is increased for the correction gain has been described. In this modification, a case will be described in which the correction gain is reduced by gamma conversion. In the present modification, in the application of the correction gain, the correction gain is applied anew so that the saturation value in the high luminance region does not change.
本変形例において想定している状況は、実施形態1同様に、あるタイミングで設定している露出条件がBv8に設定されたものであり、その際に取得した輝度がBv10の場合である。この場合、図4に示すプログラム線図上では絞りが2.8から5.6へ2EV変化し、絞り値Avが2EV変化している。即ち、暗いシーンから明るいシーンへとシーンが変化して、絞りは値が大きくなる側、小絞り側(絞り径が小さくなる側)へと変動していく。Av値とBv値に対する制御値の変動の様子は図5(a)に示す通りであり、この場合の露出差は実施形態1で示した通り2a+bである。 The situation assumed in this modification is the case where the exposure condition set at a certain timing is set to Bv8 and the luminance acquired at that time is Bv10, as in the first embodiment. In this case, on the program diagram shown in FIG. 4, the aperture changes by 2 EV from 2.8 to 5.6, and the aperture value Av changes by 2 EV. That is, the scene changes from a dark scene to a bright scene, and the aperture fluctuates from a larger value side to a smaller aperture side (a smaller aperture diameter side). The variation of the control value with respect to the Av value and the Bv value is as shown in FIG. 5A, and the exposure difference in this case is 2a + b as shown in the first embodiment.
上述したように、この露出差を低下させるためにゲイン修正を行う。ゲイン修正においてはオーバーフレームかアンダーフレームのいずれかが基準フレームとする必要があるが本変形例ではオーバーフレームを基準にアンダーフレームのゲインを修正することを考える。本変形例では、Av値の変動が小絞りの(絞り径が小さくなる)の方向であり、Av値の制御開始フレームがオーバーフレームとなるため、アンダー露出が想定よりも大きくなる。このためAv値の制御中の露出誤差は、実施形態1において上述した通り2a分となる。そしてゲインを修正する方向はゲインダウンとなる。ゲインダウンのゲイン修正は、実施形態2と同様にガンマ変換を用いて行う。対象フレームのBvに対する制御値は、実施形態1のようにレンズ通信を介して取得してもよいし、実施形態2のように撮影情報から推定してもよい。 As described above, gain correction is performed to reduce this exposure difference. In the gain correction, either the overframe or the underframe needs to be the reference frame, but in this modification, it is considered that the gain of the underframe is corrected based on the overframe. In the present modification, the Av value varies in the direction of small aperture (diaphragm diameter decreases), and the control start frame of the Av value is overframe. Therefore, underexposure is larger than expected. For this reason, the exposure error during the control of the Av value is 2a as described in the first embodiment. The direction of correcting the gain is gain down. Gain correction for gain reduction is performed using gamma conversion, as in the second embodiment. The control value for Bv of the target frame may be acquired through lens communication as in the first embodiment, or may be estimated from shooting information as in the second embodiment.
ガンマテーブルの具体的な修正方法を図14を参照して説明する。図14に示す二点鎖線のガンマテーブルは、修正後のガンマテーブルである。このガンマテーブルは、実線のガンマテーブルを水平方向に露出誤差2a分シフトすることで求められる。しかし、そのままシフトしただけでは、高輝度部は飽和が出なくなってしまう。そこで、基本的には元のガンマテーブルを水平方向にシフトしつつ、高輝度部は元のガンマテーブルに近づくようにテーブルを調整する。例えば、図14に示す白丸の輝度値から高輝度領域は、アンダーフレームが使用される輝度域であるため、当該領域で調整すればよい。図14に示す白丸の輝度値は、図7で示したY2に相当する輝度値である。
A specific method for correcting the gamma table will be described with reference to FIG. The two-dot chain line gamma table shown in FIG. 14 is a corrected gamma table. This gamma table is obtained by shifting the solid line gamma table in the horizontal direction by the
以上説明したように、本変形例では、ゲインダウンするゲイン修正を行う場合に、飽和を維持するようにガンマテーブルの調整を行なうようにした。このようにすることで、自動露出調整に対してゲインダウンのゲイン修正を行う場合に、高輝度部の飽和を維持させたゲイン修正ができるようになる。 As described above, in this modification, the gamma table is adjusted so as to maintain the saturation when the gain correction for reducing the gain is performed. In this way, when performing gain correction for gain reduction with respect to automatic exposure adjustment, it is possible to perform gain correction while maintaining saturation of the high luminance part.
なお、上述の実施形態および変形例では、自動露出の制御中にBv値が1度しか変わらないシーンのみを例示したが、Bv値が連続的に上下に変化するシーンにも適用できる。そのようなシーンであっても、それぞれの変化に対して本実施形態で説明したゲインアップとゲインダウンによるゲイン修正の組み合わせで対応できる。 In the above-described embodiment and modification, only the scene in which the Bv value changes only once during the automatic exposure control is illustrated, but the present invention can also be applied to a scene in which the Bv value continuously changes up and down. Even in such a scene, each change can be dealt with by a combination of gain correction by gain-up and gain-down described in this embodiment.
(その他の実施形態)
また、本発明は、以下の処理を実行することによっても実現される。即ち、上述した実施形態の機能を実現するソフトウェア(プログラム)を、ネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。
(Other embodiments)
The present invention can also be realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various storage media, and a computer (or CPU, MPU, or the like) of the system or apparatus reads the program. It is a process to be executed.
10…撮像素子、25…信号処理部、21…制御部、51…レンズ制御部、54…絞り駆動部、805…ガンマ変換部、809…ホワイトバランス係数補正部、816…HDR合成部、1309…制御Bv値推定部、1310…ガンマテーブル修正部
DESCRIPTION OF
Claims (10)
所定のフレームレートで露出の異なる画像を繰り返し撮像するように前記撮像手段を制御する撮像制御手段と、
前記撮像手段に入射させる光量を調節する露出制御手段と、
前記撮像手段による撮像中に前記露出制御手段により前記光量が調節され、前記露出の異なる画像の露出差が所定の値から変動した場合、前記露出制御手段により調節された露出で撮像されたフレームの画像を該変動した露出差に基づいて補正する補正手段と、
前記補正手段により補正されたフレームの画像を含む複数のフレームの画像を合成する合成手段と、を有することを特徴とする撮像装置。 Imaging means;
Imaging control means for controlling the imaging means so as to repeatedly capture images with different exposures at a predetermined frame rate;
Exposure control means for adjusting the amount of light incident on the imaging means;
When the light amount is adjusted by the exposure control means during imaging by the imaging means and the exposure difference of the images with different exposures fluctuates from a predetermined value, the frame of the image captured with the exposure adjusted by the exposure control means Correction means for correcting the image based on the changed exposure difference;
An image pickup apparatus comprising: a combining unit configured to combine a plurality of frame images including a frame image corrected by the correcting unit.
前記補正手段により補正されるフレームの画像は、前記オーバー画像および前記アンダー画像の少なくともいずれかを含むことを特徴とする請求項1乃至7のいずれか1項に記載の撮像装置。 The images with different exposures are an over image captured with overexposure with respect to proper exposure and an under image captured with underexposure with respect to the appropriate exposure,
The imaging apparatus according to claim 1, wherein the image of the frame corrected by the correcting unit includes at least one of the over image and the under image.
撮像制御手段が、所定のフレームレートで露出の異なる画像を繰り返し撮像するように前記撮像手段を制御する撮像制御工程と、
露出制御手段が、前記撮像手段に入射させる光量を調節する露出制御工程と、
補正手段が、前記撮像手段による撮像中に前記露出制御手段により前記光量が調節され、前記露出の異なる画像の露出差が所定の値から変動した場合、前記露出制御手段により調節された露出で撮像されたフレームの画像を該変動した露出差に基づいて補正する補正工程と、
合成手段が、前記補正手段により補正されたフレームの画像を含む複数のフレームの画像を合成する合成工程と、を有することを特徴とする撮像装置の制御方法。 An imaging step of imaging by the imaging means;
An imaging control step in which the imaging control means controls the imaging means so as to repeatedly capture images with different exposures at a predetermined frame rate;
An exposure control step in which the exposure control means adjusts the amount of light incident on the imaging means;
When the light amount is adjusted by the exposure control unit during imaging by the imaging unit and the exposure difference of the images with different exposures fluctuates from a predetermined value, the correction unit performs imaging with the exposure adjusted by the exposure control unit. A correction step of correcting the image of the frame that has been corrected based on the changed exposure difference;
A method for controlling an imaging apparatus, comprising: a combining unit configured to combine a plurality of frame images including a frame image corrected by the correcting unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014141775A JP6333095B2 (en) | 2014-07-09 | 2014-07-09 | Imaging apparatus, control method therefor, and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014141775A JP6333095B2 (en) | 2014-07-09 | 2014-07-09 | Imaging apparatus, control method therefor, and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2016019196A JP2016019196A (en) | 2016-02-01 |
JP6333095B2 true JP6333095B2 (en) | 2018-05-30 |
Family
ID=55234100
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014141775A Active JP6333095B2 (en) | 2014-07-09 | 2014-07-09 | Imaging apparatus, control method therefor, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6333095B2 (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10742892B1 (en) | 2019-02-18 | 2020-08-11 | Samsung Electronics Co., Ltd. | Apparatus and method for capturing and blending multiple images for high-quality flash photography using mobile electronic device |
US10911691B1 (en) | 2019-11-19 | 2021-02-02 | Samsung Electronics Co., Ltd. | System and method for dynamic selection of reference image frame |
US11062436B2 (en) | 2019-05-10 | 2021-07-13 | Samsung Electronics Co., Ltd. | Techniques for combining image frames captured using different exposure settings into blended images |
US11095829B2 (en) | 2019-06-11 | 2021-08-17 | Samsung Electronics Co., Ltd. | Apparatus and method for high dynamic range (HDR) image creation of dynamic scenes using graph cut-based labeling |
US11107205B2 (en) | 2019-02-18 | 2021-08-31 | Samsung Electronics Co., Ltd. | Techniques for convolutional neural network-based multi-exposure fusion of multiple image frames and for deblurring multiple image frames |
US11430094B2 (en) | 2020-07-20 | 2022-08-30 | Samsung Electronics Co., Ltd. | Guided multi-exposure image fusion |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR102412591B1 (en) | 2017-12-21 | 2022-06-24 | 삼성전자주식회사 | Method of generating composite image using a plurality of images with different exposure values and electronic device supporting the same |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3731729B2 (en) * | 2000-12-20 | 2006-01-05 | 松下電器産業株式会社 | Image composition circuit |
JP4854581B2 (en) * | 2007-04-24 | 2012-01-18 | キヤノン株式会社 | Imaging apparatus and control method thereof |
JP6137792B2 (en) * | 2012-07-10 | 2017-05-31 | キヤノン株式会社 | IMAGING DEVICE, CONTROL METHOD FOR IMAGING DEVICE, PROGRAM, AND STORAGE MEDIUM |
-
2014
- 2014-07-09 JP JP2014141775A patent/JP6333095B2/en active Active
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10742892B1 (en) | 2019-02-18 | 2020-08-11 | Samsung Electronics Co., Ltd. | Apparatus and method for capturing and blending multiple images for high-quality flash photography using mobile electronic device |
US11107205B2 (en) | 2019-02-18 | 2021-08-31 | Samsung Electronics Co., Ltd. | Techniques for convolutional neural network-based multi-exposure fusion of multiple image frames and for deblurring multiple image frames |
US11062436B2 (en) | 2019-05-10 | 2021-07-13 | Samsung Electronics Co., Ltd. | Techniques for combining image frames captured using different exposure settings into blended images |
US11095829B2 (en) | 2019-06-11 | 2021-08-17 | Samsung Electronics Co., Ltd. | Apparatus and method for high dynamic range (HDR) image creation of dynamic scenes using graph cut-based labeling |
US10911691B1 (en) | 2019-11-19 | 2021-02-02 | Samsung Electronics Co., Ltd. | System and method for dynamic selection of reference image frame |
US11430094B2 (en) | 2020-07-20 | 2022-08-30 | Samsung Electronics Co., Ltd. | Guided multi-exposure image fusion |
Also Published As
Publication number | Publication date |
---|---|
JP2016019196A (en) | 2016-02-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6343200B2 (en) | Imaging apparatus, control method therefor, and program | |
US10194091B2 (en) | Image capturing apparatus, control method therefor, program, and recording medium | |
JP6223028B2 (en) | Imaging apparatus, control method and program thereof | |
US9357138B2 (en) | Image capture apparatus, method of controlling image capture apparatus, and electronic device | |
JP6333095B2 (en) | Imaging apparatus, control method therefor, and program | |
US10986262B2 (en) | Imaging apparatus, control method, and non-transitory storage medium | |
US10992854B2 (en) | Image processing apparatus, imaging apparatus, image processing method, and storage medium | |
JP6028928B2 (en) | Imaging apparatus and imaging method | |
JP6744711B2 (en) | Imaging device, control method thereof, program, and storage medium | |
JP2017022610A (en) | Image processing apparatus and image processing method | |
US20170318208A1 (en) | Imaging device, imaging method, and image display device | |
JP2008131530A (en) | Image pickup device, image processing apparatus and method, and computer program | |
US10097751B2 (en) | Imaging apparatus and image compositing method | |
JP2010068046A (en) | Imaging apparatus | |
US9013597B2 (en) | Image pickup apparatus that carries out noise compensation, control method therefor, and storage medium | |
JP7361557B2 (en) | Imaging device and exposure control method | |
JP6294607B2 (en) | IMAGING DEVICE, ITS CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM | |
JP2006157342A (en) | The camera module | |
JP2013179565A (en) | Image pickup device | |
JP7555730B2 (en) | Image processing device, method and program | |
JP2014030146A (en) | Imaging apparatus and method for controlling the same | |
JP2005311843A (en) | Image pickup device | |
JP2017011762A (en) | Imaging device and imaging method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20170627 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20180226 |
|
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: 20180326 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20180424 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 6333095 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |