JP5392336B2 - Imaging apparatus, imaging method, and imaging program - Google Patents

Imaging apparatus, imaging method, and imaging program Download PDF

Info

Publication number
JP5392336B2
JP5392336B2 JP2011225416A JP2011225416A JP5392336B2 JP 5392336 B2 JP5392336 B2 JP 5392336B2 JP 2011225416 A JP2011225416 A JP 2011225416A JP 2011225416 A JP2011225416 A JP 2011225416A JP 5392336 B2 JP5392336 B2 JP 5392336B2
Authority
JP
Japan
Prior art keywords
imaging
image data
image
pixel
region
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.)
Expired - Fee Related
Application number
JP2011225416A
Other languages
Japanese (ja)
Other versions
JP2012050121A (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.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co Ltd
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 Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP2011225416A priority Critical patent/JP5392336B2/en
Publication of JP2012050121A publication Critical patent/JP2012050121A/en
Application granted granted Critical
Publication of JP5392336B2 publication Critical patent/JP5392336B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、デジタルカメラなどに係り、夜景撮影を行う撮像装置、撮像方法および撮像プログラムに関する。   The present invention relates to a digital camera and the like, and relates to an imaging apparatus, an imaging method, and an imaging program that perform night scene photography.

従来より、デジタルカメラでは、フラッシュを発光させて適切な露出で手前の人物を撮影するとともに、背景の夜景を例えばシャッタスピードをかなり遅くして撮影するという、いわゆる「夜景撮影」という撮影方法があった。   Conventionally, a digital camera has a so-called “night scene shooting” method in which a flash is emitted to shoot a person in front with an appropriate exposure, and a night scene in the background is shot at a considerably slow shutter speed, for example. It was.

図13は、従来技術によるデジタルカメラの夜景撮影時の動作例を示すタイミングチャートである。夜景撮影時には、一度の撮影で、まず、メカニカルシャッタを開放し、シャッタボタンが押下されると、フラッシュを所定の時間だけ発光させ、その後、所定時間経過後、メカニカルシャッタを閉じる。この結果、フラッシュ発光期間に主に手前の人物の画像が撮影され、このシャッタボタンが押下されてからメカニカルシャッタを閉じるまでの期間に背景(夜景)の画像が撮影される。   FIG. 13 is a timing chart showing an example of operation of a digital camera according to the prior art during night scene shooting. When shooting night scenes, the mechanical shutter is first opened, and when the shutter button is pressed, the flash is emitted for a predetermined time, and then the mechanical shutter is closed after the predetermined time has elapsed. As a result, an image of the person in the foreground is mainly captured during the flash emission period, and an image of the background (night view) is captured during the period from when the shutter button is pressed until the mechanical shutter is closed.

この場合、フラッシュ光が届きにくい背景で適正露出を得るためには、シャッタスピードを遅くする必要である。このように一度の撮影で手前の人物と背景とを撮影する場合、全体としてどうしてもシャッタスピードを遅くしなければならないため、手ぶれを防止するために、三脚等、デジタルカメラ本体を固定する必要があった。また、夜景の中に動くものがあると、薄く流れて撮影されてしまうという問題があった。   In this case, it is necessary to slow down the shutter speed in order to obtain appropriate exposure in a background where the flash light is difficult to reach. When shooting the person and background in the foreground in this way, the shutter speed must be slowed down as a whole, so it is necessary to fix the digital camera body, such as a tripod, to prevent camera shake. It was. Also, there was a problem that if there were moving objects in the night view, the film flowed thinly.

そこで、一度の撮影指示に対して、フラッシュを発光させる撮影とフラッシュを発光させない撮影とをそれぞれ行い、双方の画像の相関を検出し、該相関に基づいて撮影画像を補正する技術提案されている(例えば特許文献1参照)。 Therefore, a technique has been proposed in which shooting with a flash and shooting without a flash are performed in response to a single shooting instruction, the correlation between both images is detected, and the shot image is corrected based on the correlation. (For example, refer to Patent Document 1).

特開2000−102022号公報JP 2000-102022 A

しかしながら、上述した従来技術では、フラッシュを発光させて撮影した画像と、フラッシュを発光させないで撮影した画像とを用いて撮影画像を補正しても、明るさとノイズとのバランスの良い画像を得ることができないという問題がある。また、フラッシュ光による影響を受けた画像部分とフラッシュ光による影響を受けなかった画像部分とを識別するための相関検出処理と、この識別された画像部分に対する画像補正処理の2つの複雑な演算を別々に行う必要があるため、回路構成あるいはソフトウェアが複雑になるという問題がある。   However, with the above-described conventional technology, an image with a good balance between brightness and noise can be obtained even if the captured image is corrected using an image shot with the flash and an image shot without the flash. There is a problem that can not be. In addition, two complex operations, correlation detection processing for identifying an image portion affected by flash light and an image portion not affected by flash light, and image correction processing for the identified image portion are performed. Since it needs to be performed separately, there is a problem that the circuit configuration or software becomes complicated.

そこで本発明は、特に夜間撮影などにおいて、撮影画像に十分な明るさを確保するとともに、感度変更によるノイズや、シャッタスピード変更による手ぶれとのバランスの良い画像を、簡単な演算処理で得ることのできる撮像装置、撮像方法および撮像プログラムを提供することを目的とする。   Therefore, the present invention secures sufficient brightness for a photographed image, particularly in night photography, and obtains an image having a good balance with noise due to sensitivity change and camera shake due to shutter speed change by simple arithmetic processing. An object is to provide an imaging device, an imaging method, and an imaging program.

本発明による撮像装置は、被写体像を撮像する撮像手段と、前記撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得手段と、予め、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定手段と、前記取得手段により取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記規定手段の規定に基づいて決定する決定手段と、前記決定手段により決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録手段と、を具備することを特徴とする。
また、本発明による撮像方法は、撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得ステップと、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定情報を参照する参照ステップと、前記取得ステップにより取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記参照ステップにより参照される規定情報に基づいて決定する決定ステップと、前記決定ステップにより決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録ステップと、を含むことを特徴とする。
また、本発明による撮像プログラムは、撮像装置のコンピュータを、被写体像を撮像する撮像手段と、前記撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得手段と、予め、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定手段と、前記取得手段により取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記規定手段の規定に基づいて決定する決定手段と、前記決定手段により決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録手段と、して機能させることを特徴とする。
An image pickup apparatus according to the present invention has an image pickup means for picking up a subject image, an acquisition means for picking up images under two different shooting conditions by the image pickup means to acquire two image data, and a relationship between two luminance values in advance. By defining the relationship between the two luminance values and the composition ratio by subdividing the obtained region into a plurality of regions by dividing the region by a plurality of inclined boundary lines and assigning a different composition ratio for each region; Determination of determining a composition ratio corresponding to pixel values of two pixels to be combined based on the definition of the defining means when combining the two image data acquired by the acquisition means with different composition ratios for each pixel And a composite recording means for recording image data obtained by combining the two image data for each pixel at a composite ratio determined by the determining means.
The imaging method according to the present invention also includes an acquisition step of acquiring two image data by performing imaging under two different imaging conditions by an imaging means, and a boundary line that inclines a region obtained by the relationship between two luminance values. And subdividing into multiple regions by assigning different composition ratios to each region, assigning different composition ratios for each area, referring to the defining information that defines the relationship between the two luminance values and the composition ratios, and obtaining by the acquisition step A determining step of determining a combining ratio corresponding to pixel values of two pixels to be combined based on the defining information referred to in the reference step when combining the two image data with different combining ratios for each pixel; And a combination recording step for recording image data obtained by combining the two image data for each pixel at a combination ratio determined by the determination step. And wherein the Mukoto.
In addition, an imaging program according to the present invention includes an imaging unit that captures a computer of an imaging device, an acquisition unit that acquires two image data by performing imaging under two different imaging conditions using the imaging unit, By dividing the region obtained by the relationship between the two luminance values by a plurality of inclined boundary lines, the region is subdivided into a plurality of regions, and by assigning different composition ratios for each region, the two luminance values and the composition ratio A defining means for defining the relationship and a combining ratio corresponding to the pixel values of the two pixels to be combined when the two image data acquired by the acquiring means are combined at different combining ratios for each pixel. Determining means for determining based on the stipulations, and a composite recording device for recording image data obtained by combining the two image data for each pixel at a composite ratio determined by the determining means When, characterized in that to function with.

本発明によれば、予め、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係をより柔軟に規定可能となり、2つの異なる撮影条件で撮像を行って取得した2つの画像データを画素毎に異なる合成比率で合成する際に、よりバランスの良い画像を、簡単な演算処理で得ることができるという利点が得られる。 According to the present invention, an area obtained by the relationship between two luminance values is divided into a plurality of areas by dividing the area by a plurality of inclined boundary lines, and two synthesis ratios are assigned to each area, thereby The relationship between the luminance value and the composition ratio can be defined more flexibly. When two image data acquired by imaging under two different shooting conditions are combined at a different composition ratio for each pixel , a more balanced image Can be obtained by simple arithmetic processing.

本発明の第1実施形態によるデジタルカメラの構成を示すブロック図である。It is a block diagram which shows the structure of the digital camera by 1st Embodiment of this invention. 本第1実施形態によるデジタルカメラの夜景撮影時の動作を示すタイミングチャートである。It is a timing chart which shows the operation | movement at the time of night view imaging | photography of the digital camera by this 1st Embodiment. 本第1実施形態のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。It is a conceptual diagram which shows the threshold value at the time of synthesize | combining the image at the time of high sensitivity imaging | photography with the digital camera of this 1st Embodiment, and the image at the time of flash light emission imaging | photography. 本第1実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。4 is a flowchart for explaining the operation of the digital camera according to the first embodiment during night scene shooting. 本第1実施形態によるデジタルカメラの夜景撮影時の画像、および画像合成例を示す模式図である。It is a schematic diagram which shows the image at the time of night view photography of the digital camera by this 1st Embodiment, and an example of an image synthesis. 本発明の第2実施形態のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。It is a conceptual diagram which shows the threshold value at the time of synthesize | combining the image at the time of high sensitivity imaging | photography with the digital camera of 2nd Embodiment of this invention, and the image at the time of flash light emission imaging | photography. 本第2実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement at the time of night view imaging | photography of the digital camera by this 2nd Embodiment. 本発明の第3実施形態のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。It is a conceptual diagram which shows the threshold value at the time of synthesize | combining the image at the time of high sensitive imaging | photography with the digital camera of 3rd Embodiment of this invention, and the image at the time of flash light emission imaging | photography. 本第3実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement at the time of night view imaging | photography of the digital camera by this 3rd Embodiment. 本第3実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement at the time of night view imaging | photography of the digital camera by this 3rd Embodiment. 本発明の第4実施形態のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。It is a conceptual diagram which shows the threshold value at the time of synthesize | combining the image at the time of high sensitivity imaging | photography with the digital camera of 4th Embodiment of this invention, and the image at the time of flash light emission imaging | photography. 本発明の変形例のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。It is a conceptual diagram which shows the threshold value at the time of synthesize | combining the image at the time of high sensitivity imaging | photography with the digital camera of the modification of this invention, and the image at the time of flash light emission imaging | photography. 従来技術による夜景撮影時のデジタルカメラの動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the digital camera at the time of night view photography by a prior art.

以下、本発明の実施の形態を、図面を参照して説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

A.第1実施形態
A−1.第1実施形態の構成
図1は、本発明の第1実施形態によるデジタルカメラの構成を示すブロック図である。図において、画像取得部10は、レンズ11、シャッタ12、LPF13からなる。レンズ11は、通常の光学レンズであり、非球面レンズを重ねたレンズ群からなる。シャッタ12は、シャッタボタンが操作されると、制御部20によって駆動されるドライバ14により動作する、所謂メカニカルシャッタである。なお、デジタルカメラによっては、メカニカルシャッタを備えない場合もあり、沈胴式のレンズ構造、メカニカルズームを搭載する機種の場合、これらの駆動制御もドライバ14で行う。LPF13は、水晶ローパスフィルタであり、モアレの発生を防ぐために搭載されている。
A. First embodiment A-1. Configuration of First Embodiment FIG. 1 is a block diagram showing a configuration of a digital camera according to a first embodiment of the present invention. In the figure, the image acquisition unit 10 includes a lens 11, a shutter 12, and an LPF 13. The lens 11 is a normal optical lens and includes a lens group in which aspherical lenses are stacked. The shutter 12 is a so-called mechanical shutter that is operated by a driver 14 driven by the control unit 20 when a shutter button is operated. Depending on the digital camera, a mechanical shutter may not be provided. In the case of a model equipped with a retractable lens structure and a mechanical zoom, these drivers are also controlled by the driver 14. The LPF 13 is a crystal low-pass filter and is mounted to prevent the occurrence of moire.

次に、アナログ信号処理部15は、撮像センサ(CCD,CMOS)16、サンプリング/信号増幅処理部17、A/Dコンバータ18からなる。撮像センサ16は、被写体画像(イメージ)を結像し、RGBの各色の光の強さを、電流値に変換する。サンプリング/信号増幅処理部17は、ノイズや色むらを抑えるための相関二重サンプリング処理や信号増幅処理を行う。A/Dコンバータ18は、アナログフロントエンドとも呼ばれ、サンプリング・増幅したアナログ信号をデジタル信号に変換する(RGB,CMYG各色について12bitデータに変換してバスラインに出力する)。   Next, the analog signal processing unit 15 includes an image sensor (CCD, CMOS) 16, a sampling / signal amplification processing unit 17, and an A / D converter 18. The imaging sensor 16 forms a subject image (image), and converts the intensity of light of each color of RGB into a current value. The sampling / signal amplification processing unit 17 performs correlated double sampling processing and signal amplification processing for suppressing noise and color unevenness. The A / D converter 18 is also called an analog front end, and converts the sampled / amplified analog signal into a digital signal (converts each color of RGB and CMYG into 12-bit data and outputs it to the bus line).

次に、制御部(CPU)20は、後述するプログラムメモリ格納されるプログラムに従ってデジタルカメラ1(撮像装置)の全体を制御する。特に、本第1実施形態では、夜景撮影において、2回の露光により背景の夜景と手前の被写体(人物など)とを撮影するようになっている。詳細は後述するが、1回目の撮影(高感度撮影)では、ISO感度を上げて露光し、2回目の撮影(フラッシュ発光撮影)では、ISO感度を下げ、フラッシュを発光させて露光する。そして、1回目の画像と2回目の画像とを、後述する所定の閾値、所定の合成比率(重み)に従って合成するようになっている。制御部20は、これら夜景撮影時の動作、画像取り込み、画像合成等を制御する。   Next, the control unit (CPU) 20 controls the entire digital camera 1 (imaging device) according to a program stored in a program memory described later. In particular, in the first embodiment, in night scene shooting, a background night scene and a subject (such as a person) in the foreground are shot by two exposures. Although details will be described later, in the first shooting (high-sensitivity shooting), the ISO sensitivity is increased and exposed, and in the second shooting (flash flash shooting), the ISO sensitivity is decreased and the flash is emitted for exposure. Then, the first image and the second image are combined according to a predetermined threshold and a predetermined combining ratio (weight) described later. The control unit 20 controls the operation at the time of night scene shooting, image capture, image composition, and the like.

プレビューエンジン22は、録画モード(記録モード、撮影モードともいう)において、画像取得部10、アナログ信号処理部15を介して入力されたデジタルデータ、もしくはシャッタ操作検出直後、イメージバッファ26に格納されたデジタルデータ、および、画像メモリ31に格納されたデジタルデータを表示部25に表示させるために間引き処理を行う。D/Aコンバータ23は、プレビューエンジン22により間引き処理されたデジタルデータを変換し、後段のドライバ24に出力する。   The preview engine 22 is stored in the image buffer 26 immediately after detection of digital data input via the image acquisition unit 10 and the analog signal processing unit 15 in the recording mode (also referred to as recording mode or photographing mode) or shutter operation detection. Thinning processing is performed in order to display the digital data and the digital data stored in the image memory 31 on the display unit 25. The D / A converter 23 converts the digital data thinned out by the preview engine 22 and outputs it to the driver 24 at the subsequent stage.

ドライバ24は、後段の表示部25に表示されるデジタルデータを一時記憶するバッファ領域を備え、キー操作部27、制御部20を介して入力された制御信号に基づいて表示部25を駆動させる。表示部25は、カラーTFT液晶や、STN液晶などからなり、プレビュー画像や、撮影後の画像データ、設定メニューなどを表示する。   The driver 24 includes a buffer area for temporarily storing digital data displayed on the display unit 25 at the subsequent stage, and drives the display unit 25 based on a control signal input via the key operation unit 27 and the control unit 20. The display unit 25 includes a color TFT liquid crystal, an STN liquid crystal, or the like, and displays a preview image, image data after shooting, a setting menu, and the like.

イメージバッファ26は、アナログ信号処理部15、もしくはデジタル信号処理部28を介して入力され、デジタル信号処理部28に渡すまで一時的に撮影直後のデジタルデータを格納する。キー操作部27は、シャッタボタンや、記録/再生モード選択スライドスイッチ、メニューボタン、十字キー(中央押しで決定)などからなる。   The image buffer 26 temporarily stores digital data immediately after photographing until it is input via the analog signal processing unit 15 or the digital signal processing unit 28 and passed to the digital signal processing unit 28. The key operation unit 27 includes a shutter button, a recording / playback mode selection slide switch, a menu button, a cross key (determined by pressing the center), and the like.

デジタル信号処理部28は、アナログ信号処理部15を介して入力されたデジタルデータに対して、ホワイトバランス処理、色処理、階調処理、輸郭強調、RGB形式からYUV形式への変換、YUV形式からJPEG形式への変換を行う。特に、本第1実施形態では、デジタル信号処理部28は、夜景撮影時において、ISO感度を上げて露光した、1回目の撮影(高感度撮影)による画像と、ISO感度を下げ、フラッシュを発光させて露光した、2回目の撮影(フラッシュ発光撮影)による画像とを、後述する所定の閾値、所定の合成比率(重み)に従って合成する。   The digital signal processing unit 28 performs white balance processing, color processing, gradation processing, contour emphasis, conversion from RGB format to YUV format, YUV format for digital data input via the analog signal processing unit 15. To JPEG format. In particular, in the first embodiment, the digital signal processing unit 28 emits a flash by lowering the ISO sensitivity and the image of the first shooting (high-sensitivity shooting), which is exposed with increased ISO sensitivity during night scene shooting. The image obtained by the second shooting (flash flash shooting) is then combined in accordance with a predetermined threshold value and a predetermined combining ratio (weight) described later.

画像圧縮/伸張処理部29は、デジタル信号処理部28を介して入力されたデジタルデータをJPEG方式に圧縮符号化したり、モーションJPEG形式の動画ファイルを生成したり、モーションJPEG形式の動画ファイルをMPEG形式の動画ファイルに変換したり、再生モードにおいては、JPEG形式、モーションJPEG形式、あるいはMPEG形式の動画ファイルを伸張したりする。   The image compression / decompression processing unit 29 compresses and encodes the digital data input via the digital signal processing unit 28 into the JPEG format, generates a motion JPEG format movie file, or converts the motion JPEG format movie file to MPEG. It is converted into a moving image file in a format, or in a reproduction mode, a moving image file in JPEG format, motion JPEG format, or MPEG format is expanded.

プログラムメモリ30は、制御部20にロードされる各種プログラムや、ベストショット機能におけるEV値、色補正情報などを格納する。画像メモリ31は、イメージバッファ26に一時的に保持された画像データや、各種ファイル形式に変換されたデジタルデータ、動画データなどを格納する。カードI/F32は、外部記録媒体33と撮像装置本体との間のデータ交換を制御する。   The program memory 30 stores various programs loaded in the control unit 20, EV values in the best shot function, color correction information, and the like. The image memory 31 stores image data temporarily stored in the image buffer 26, digital data converted into various file formats, moving image data, and the like. The card I / F 32 controls data exchange between the external recording medium 33 and the imaging apparatus main body.

外部記録媒体33は、コンパクトフラッシュ(登録商標)、メモリースティック、SDカード等からなる着脱可能な記録媒体である。外部接続用I/F34は、USBコネクター用スロットなどからなり、パーソナルコンピュータなどと接続され、撮影した画像データの転送などに用いられる。RAM35は、制御部(CPU)20の制御に必要な各種パラメータや、夜景撮影時の各種パラメータ(ゲイン(ISO感度)、絞り、シャッタスピード、画像合成のための閾値、重みなど)などを記憶する。   The external recording medium 33 is a detachable recording medium composed of a compact flash (registered trademark), a memory stick, an SD card, or the like. The external connection I / F 34 includes a USB connector slot and the like, is connected to a personal computer or the like, and is used for transferring photographed image data. The RAM 35 stores various parameters necessary for control of the control unit (CPU) 20, various parameters at the time of night scene shooting (gain (ISO sensitivity), aperture, shutter speed, threshold for image composition, weight, etc.), and the like. .

次に、図2は、本第1実施形態によるデジタルカメラの夜景撮影時の動作を示すタイミングチャートである。夜景撮影時には、まず、メカニカルシャッタを開放し、シャッタボタンが押下されると、まず、露光期間ET1で、ISO感度を上げて画像を露光させ、メカニカルシャッタを閉じた後、そのデータを転送期間TT1で読み出す。該画像が背景(遠景)の夜景の画像に相当する。その後、すぐにメカニカルシャッタを開放するとともにISO感度を下げ、フラッシュを発光させて、露光時間ET2で露光させ、メカニカルシャッタを閉じた後、そのデータを転送期間TT2で読み出す。該画像が手前の人物などの被写体の画像に相当する。   Next, FIG. 2 is a timing chart showing the operation of the digital camera according to the first embodiment during night scene shooting. During night scene shooting, first, when the mechanical shutter is opened and the shutter button is pressed, first, in the exposure period ET1, the ISO sensitivity is increased to expose the image, the mechanical shutter is closed, and the data is transferred in the transfer period TT1. Read with. This image corresponds to an image of a night view of the background (far view). Thereafter, the mechanical shutter is immediately opened, the ISO sensitivity is lowered, the flash is emitted, the exposure is performed with the exposure time ET2, the data is read out in the transfer period TT2 after the mechanical shutter is closed. The image corresponds to an image of a subject such as a person in front.

次に、図3は、本第1実施形態のデジタルカメラによる高感度撮影時の画像とフラッシュ発光撮影時の画像とを合成する際の閾値を示す概念図である。本第1実施形態では、2回目のフラッシュ発光撮影時に取り込んだ画像データD2について、画素毎に、その画素の輝度値が閾値THAより大きいか判定し、その画素の輝度値が閾値THAより大きく領域Aにあれば、2回目のフラッシュ発光撮影時に取り込んだ画像データD2(D1×0%+D2×100%)の画素を用い、その画素の輝度値が閾値THA以下で領域Bにあれば、1回目の高感度撮影時の画像データD1(D1×100%+D2×0%)の画素を用いて画像を合成して記録用の画像を得るようになっている。これら閾値THAや画像データD1,D2との合成比率は、上述したRAM35にデータテーブルまたは計算式の形で記憶されている。   Next, FIG. 3 is a conceptual diagram showing a threshold when combining an image at the time of high-sensitivity shooting with the digital camera of the first embodiment and an image at the time of flash emission shooting. In the first embodiment, for the image data D2 captured at the time of the second flash photography, it is determined for each pixel whether the luminance value of the pixel is larger than the threshold value THA, and the luminance value of the pixel is larger than the threshold value THA. If it is in A, the pixel of the image data D2 (D1 × 0% + D2 × 100%) captured at the time of the second flash photography is used, and if the luminance value of the pixel is equal to or lower than the threshold THA and in the region B, the first time An image for recording is obtained by synthesizing images using pixels of image data D1 (D1 × 100% + D2 × 0%) during high-sensitivity shooting. The synthesis ratio of the threshold THA and the image data D1 and D2 is stored in the above-described RAM 35 in the form of a data table or a calculation formula.

A−B.第1実施形態の動作
次に、本第1実施形態の動作について説明する。ここで、図4は、本第1実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。また、図5は、夜景撮影時の画像、および画像合成例を示す模式図である。
AB. Operation of the First Embodiment Next, the operation of the first embodiment will be described. Here, FIG. 4 is a flowchart for explaining the operation of the digital camera according to the first embodiment during night scene shooting. FIG. 5 is a schematic diagram showing an image at the time of night scene shooting and an example of image synthesis.

夜景撮影が選択されると、まず、高感度設定として、絞りを開放、ゲイン(ISO感度)を最大、シャッタスピードを手ぶれしない最大時間に設定する(ステップS10)。次に、シャッタボタンが押下されると、高感度露光(図2に示す露光期間ET1)し、主に遠景の夜景を撮影し(ステップS12)、画像データD1としてイメージバッファ26に転送して一時保存する(ステップS14)。該夜景の画像は、図5(a)に示すように、手ぶれせずに、背景である夜景がより良い状態で撮られている。但し、近景の被写体については露出不足となる。   When night scene shooting is selected, first, as a high sensitivity setting, the aperture is opened, the gain (ISO sensitivity) is set to the maximum, and the shutter speed is set to the maximum time without camera shake (step S10). Next, when the shutter button is pressed, high-sensitivity exposure (exposure period ET1 shown in FIG. 2) is performed, and a night view of a distant view is mainly photographed (step S12), which is transferred to the image buffer 26 as image data D1 and temporarily stored. Save (step S14). As shown in FIG. 5A, the night scene image is taken in a better state of the night scene as a background without camera shake. However, the foreground subject is underexposed.

次に、フラッシュ露光設定として、ゲイン(ISO感度)を最小、フラッシュを最大発光、その他として上記二条件下で最も高画質な撮影ができるように設定する(ステップS16)。次に、フラッシュを発光して露光(図2に示す露光期間ET2)し、近景の被写体(人物など)を撮影し(ステップS18)、画像データD2としてイメージバッファ26に転送して一時保存する(ステップS20)。該近景の画像は、図5(b)に示すように、被写体である人物がより良い状態で撮られている。但し、遠景の夜景については、フラッシュ光が届かず、露出時間ET2も短いので露出不足となる。   Next, as the flash exposure setting, the gain (ISO sensitivity) is set to the minimum, the flash is set to the maximum light emission, and others are set so that the highest quality image can be taken under the above two conditions (step S16). Next, a flash is emitted for exposure (exposure period ET2 shown in FIG. 2), a subject (such as a person) in the foreground is photographed (step S18), transferred to the image buffer 26 as image data D2, and temporarily stored (step S18). Step S20). As shown in FIG. 5B, the close-up image is taken in a better state of the person who is the subject. However, the night view of the distant view is underexposed because the flash light does not reach and the exposure time ET2 is short.

次に、ステップS22〜S32で各画素のデータ作成のループ処理を実行する。まず、所定の座標の、フラッシュ発光撮影時の画像データD2を読み込み(ステップS24)、画像データD2の輝度値が閾値THAを超えているか否かを判断する(ステップS26)。そして、フラッシュ発光撮影時の輝度値が閾値THAを超えている場合、すなわち、図2の領域Aである場合には、該フラッシュ発光撮影時の画像データD2(D1×0%+D2×100%)を合成データとして画像メモリ31に保存する(ステップS28)。   Next, a loop process for creating data for each pixel is executed in steps S22 to S32. First, the image data D2 at the time of flash photography is read at a predetermined coordinate (step S24), and it is determined whether or not the luminance value of the image data D2 exceeds the threshold value THA (step S26). When the luminance value at the time of flash photography is greater than the threshold value THA, that is, when it is the area A in FIG. 2, the image data D2 at the time of flash photography (D1 × 0% + D2 × 100%). Is stored in the image memory 31 as composite data (step S28).

一方、フラッシュ発光撮影時の輝度値が閾値THAを超えていない場合、すなわち、図2の領域Bである場合には、1回目の高感度撮影時の画像データD1(D1×100%+D2×0%)を合成データとして画像メモリ31に保存する(ステップS30)。以上の処理を全画素について行って記録用の画像データを得る。   On the other hand, when the luminance value at the time of flash photography does not exceed the threshold value THA, that is, in the region B in FIG. 2, the image data D1 (D1 × 100% + D2 × 0) at the time of the first high-sensitivity photography. %) Is stored in the image memory 31 as composite data (step S30). The above processing is performed for all pixels to obtain recording image data.

この結果、合成された画像は、図5(c)に示すように、より良い状態で撮影された夜景とより良い状態で撮影された近景の被写体とが合成され、手ぶれのない、露出、S/N比のバランスが良好な撮影画像となる。   As a result, as shown in FIG. 5C, the synthesized image is composed of a night view taken in a better state and a subject in the foreground taken in a better state. The captured image has a good balance of the / N ratio.

B.第2実施形態
次に、本発明の第2実施形態について説明する。なお、デジタルカメラの構成は、図1と同様であるので説明を省略する。また、デジタルカメラの夜景撮影時の動作についても、図2に示すタイミングチャートと同様である。本第2実施形態では、1回目の画像と2回目の画像とを合成する際の閾値の設定方法を変えており、図6に示すように、閾値THBを1:1のところに設けており、画素毎に、1回目の高感度撮影時に取り込んだ画像の輝度値と2回目のフラッシュ発光撮影時に取り込んだ画像の輝度値とを比較し、輝度値が大きい方の画素を用いて画像を合成して記録用の画像を得るようになっている。
B. Second Embodiment Next, a second embodiment of the present invention will be described. The configuration of the digital camera is the same as that in FIG. Also, the operation of the digital camera at the time of night view shooting is the same as the timing chart shown in FIG. In the second embodiment, the method of setting the threshold value when the first image and the second image are combined is changed, and the threshold value THB is set at 1: 1 as shown in FIG. For each pixel, compare the brightness value of the image captured during the first high-sensitivity shooting with the brightness value of the image captured during the second flash shooting, and synthesize the image using the pixel with the higher luminance value. Thus, an image for recording is obtained.

すなわち、2回目のフラッシュ発光撮影時に取り込んだ画像の画素の輝度値の方が大きい場合、言い換えると、領域Aにあれば、2回目のフラッシュ発光撮影時に取り込んだ画像の画素値である画像データD2(D1×0%+D2×100%)を用い、1回目の高感度撮影時に取り込んだ画像の画素の輝度値の方が大きい場合、言い換えると、領域Bにあれば、1回目の高感度撮影時に取り込んだ画像の画素値である画像データD1(D1×100%+D2×0%)を用いて画像を合成して記録用の画像を得るようになっている。これら閾値THBや画像データD1,D2との合成比率は、上述したRAM35にデータテーブルまたは計算式の形で記憶されている。   That is, if the luminance value of the pixel of the image captured at the second flash photography is larger, in other words, if it is in the area A, the image data D2 is the pixel value of the image captured at the second flash photography. (D1 × 0% + D2 × 100%) is used, and if the luminance value of the pixel of the image captured at the time of the first high-sensitivity shooting is larger, in other words, if it is in the region B, the first high-sensitivity shooting An image for recording is obtained by combining images using image data D1 (D1 × 100% + D2 × 0%) which is a pixel value of the captured image. The synthesis ratio of the threshold THB and the image data D1 and D2 is stored in the RAM 35 in the form of a data table or a calculation formula.

B−2.第2実施形態の動作
次に、上述した第2実施形態の動作について説明する。ここで、図7は、本第2実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。夜景撮影が選択されると、まず、高感度設定として、絞りを開放、ゲイン(ISO感度)を最大、シャッタスピードを手ぶれしない最大時間に設定する(ステップS40)。次に、シャッタボタンが押下されると、高感度露光(図2に示す露光期間ET1)し、主に遠景の夜景を撮影し(ステップS42)、画像データD1としてイメージバッファ26に転送して一時保存する(ステップS44)。該夜景の画像は、図5(a)に示すように、手ぶれせずに、背景である夜景がより良い状態で撮られている。但し、近景の被写体については露出不足となる。
B-2. Operation of the Second Embodiment Next, the operation of the second embodiment described above will be described. Here, FIG. 7 is a flowchart for explaining the operation of the digital camera according to the second embodiment during night scene shooting. When night scene shooting is selected, first, as a high sensitivity setting, the aperture is opened, the gain (ISO sensitivity) is set to the maximum, and the shutter speed is set to the maximum time without camera shake (step S40). Next, when the shutter button is pressed, high-sensitivity exposure (exposure period ET1 shown in FIG. 2) is performed, and a night view of a distant view is mainly photographed (step S42), which is transferred to the image buffer 26 as image data D1 and temporarily stored. Save (step S44). As shown in FIG. 5A, the night scene image is taken in a better state of the night scene as a background without camera shake. However, the foreground subject is underexposed.

次に、フラッシュ露光設定として、ゲイン(ISO感度)を最小、フラッシュを最大発光、その他として上記二条件下で最も高画質な撮影ができるように設定する(ステップS46)。次に、フラッシュを発光して露光(図2に示す露光期間ET2)し、近景の被写体(人物など)を撮影し(ステップS48)、画像データD2としてイメージバッファ26に転送して一時保存する(ステップS50)。該近景の画像は、図5(b)に示すように、被写体である人物がより良い状態で撮られている。但し、遠景の夜景については、フラッシュ光が届かず、露出時間ET2も短いので露出不足となる。   Next, as the flash exposure setting, the gain (ISO sensitivity) is set to the minimum, the flash is set to the maximum light emission, and others are set so that the highest quality image can be taken under the above two conditions (step S46). Next, the flash is fired for exposure (exposure period ET2 shown in FIG. 2), a subject (such as a person) in the foreground is photographed (step S48), transferred to the image buffer 26 as image data D2, and temporarily stored (step S48). Step S50). As shown in FIG. 5B, the close-up image is taken in a better state of the person who is the subject. However, the night view of the distant view is underexposed because the flash light does not reach and the exposure time ET2 is short.

次に、ステップS52〜S62で各画素のデータ作成のループ処理を実行する。まず、所定の座標の、高感度撮影時の画像データD1とフラッシュ発光撮影時の画像データD2とを読み込み(ステップS54)、画像データD1の輝度値が画像データD2の輝度値より大きい否かを判断する(ステップS56)。そして、高感度撮影時の輝度値の方が大きい場合、すなわち、図6の領域Bである場合には、1回目の高感度撮影時の画像データD1(D1×100%+D2×0%)を合成データとして画像メモリ31に保存する(ステップS58)。 Next, a loop process for creating data for each pixel is executed in steps S52 to S62. First, the predetermined coordinate, reading the image data D2 at the time of image data D1 and flash photography High ISO speed (step S54), the luminance value of the image data D1 whether larger than the luminance value of the image data D2 Is determined (step S56). If the luminance value at the time of high-sensitivity shooting is larger, that is, in the region B of FIG. 6, the image data D1 (D1 × 100% + D2 × 0%) at the time of the first high-sensitivity shooting is obtained. The synthesized data is stored in the image memory 31 (step S58).

一方、フラッシュ発光撮影時の輝度値の方が大きい場合、すなわち、図6の領域Aである場合には、2回目のフラッシュ発光撮影時の画像データD2(D1×0%+D2×100%)を合成データとして画像メモリ31に保存する(ステップS60)。以上の処理を全画素について行って記録用の画像データを得る。   On the other hand, when the luminance value at the time of flash photography is larger, that is, in the area A of FIG. 6, the image data D2 (D1 × 0% + D2 × 100%) at the time of the second flash photography is obtained. The synthesized data is stored in the image memory 31 (step S60). The above processing is performed for all pixels to obtain recording image data.

この結果、合成された画像は、より良い状態で撮影された夜景とより良い状態で撮影された近景の被写体とが合成され、手ぶれのない、露出、S/N比のバランスが良好な撮影画像となる。   As a result, the synthesized image is composed of a night view taken in a better state and a subject in the foreground taken in a better state, and has a good balance between exposure and S / N ratio without camera shake. It becomes.

C.第3実施形態
次に、本発明の第3実施形態について説明する。なお、デジタルカメラの構成は、図1と同様であるので説明を省略する。本第3実施形態では、1回目の画像と2回目の画像とを合成する際の閾値、および合成比率を変えており、図8に示すように、閾値THC1、THC2を設け、フラッシュ発光撮影時の輝度値と高感度撮影時の輝度値との関係で得られる領域を、4つの領域A〜Dに細分化している。なお、領域Bと領域Cとの境界は、大小比較で判定する。そして、画素毎に、1回目の高感度撮影時に取り込んだ画像の輝度値と2回目のフラッシュ発光撮影時に取り込んだ画像の輝度値とを比較し、輝度値がどの領域にあるかで、記録用の画像(の画素)として用いる画素合成比率を決めるようになっている。
C. Third Embodiment Next, a third embodiment of the present invention will be described. The configuration of the digital camera is the same as that in FIG. In the third embodiment, the threshold value and the composition ratio for combining the first image and the second image are changed, and threshold values THC1 and THC2 are provided as shown in FIG. The area obtained by the relationship between the brightness value of the image and the brightness value at the time of high-sensitivity shooting is subdivided into four areas A to D. Note that the boundary between the region B and the region C is determined by size comparison. Then, for each pixel, the luminance value of the image captured at the first high-sensitivity shooting is compared with the luminance value of the image captured at the second flash shooting, and it is determined whether the luminance value is in which area. The pixel composition ratio to be used as the (image) is determined.

例えば、領域Aでは、合成画像の画素値を、高感度撮影時の画像データD1×0%+フラッシュ発光撮影時の画像データD2×100%とし、領域Bでは、高感度撮影時の画像データD1×25%+フラッシュ発光撮影時の画像データD2×75%とし、領域Cでは、高感度撮影時の画像データD1×75%+フラッシュ発光撮影時の画像データD2×25%とし、領域Dでは、D1×100%+D2×0%とする。これら閾値THC1、THC2や画像データD1,D2との合成比率は、上述したRAM35にデータテーブルまたは計算式の形で記憶されている。   For example, in the area A, the pixel value of the composite image is set to the image data D1 × 0% at the time of high sensitivity shooting + the image data D2 × 100% at the time of flash shooting, and in the area B, the image data D1 at the time of high sensitivity shooting. X25% + image data D2 × 75% during flash photography, and in area C, image data D1 × 75% during high sensitivity photography + image data D2 × 25% during flash photography, and in area D, D1 × 100% + D2 × 0%. The synthesis ratios of the threshold values THC1 and THC2 and the image data D1 and D2 are stored in the above-described RAM 35 in the form of a data table or a calculation formula.

次に、本第3実施形態の動作について説明する。ここで、図9および図10は、本第3実施形態によるデジタルカメラの夜景撮影時の動作を説明するためのフローチャートである。夜景撮影が選択されると、まず、高感度設定として、絞りを開放、ゲイン(ISO感度)を最大、シャッタスピードを手ぶれしない最大時間に設定する(ステップS70)。次に、シャッタボタンが押下されると、高感度露光(図2に示す露光期間ET1)し、主に遠景の夜景を撮影し(ステップS72)、画像データD1としてイメージバッファ26に転送して一時保存する(ステップS74)。該夜景の画像は、図5(a)に示すように、手ぶれせずに、背景である夜景がより良い状態で撮られている。但し、近景の被写体については露出不足となる。   Next, the operation of the third embodiment will be described. Here, FIGS. 9 and 10 are flowcharts for explaining the operation of the digital camera according to the third embodiment at the time of night scene shooting. When night scene shooting is selected, first, as a high sensitivity setting, the aperture is opened, the gain (ISO sensitivity) is set to the maximum, and the shutter speed is set to the maximum time without camera shake (step S70). Next, when the shutter button is pressed, high-sensitivity exposure (exposure period ET1 shown in FIG. 2) is performed, and a night view of a distant view is mainly photographed (step S72), which is transferred to the image buffer 26 as image data D1 and temporarily stored. Save (step S74). As shown in FIG. 5A, the night scene image is taken in a better state of the night scene as a background without camera shake. However, the foreground subject is underexposed.

次に、フラッシュ露光設定として、ゲイン(ISO感度)を最小、フラッシュを最大発光、その他として上記二条件下で最も高画質な撮影ができるように設定する(ステップS76)。次に、フラッシュを発光して露光(図2に示す露光期間ET2)し、近景の被写体(人物など)を撮影し(ステップS78)、画像データD2としてイメージバッファ26に転送して一時保存する(ステップS80)。該近景の画像は、図5(b)に示すように、被写体である人物がより良い状態で撮られている。但し、遠景の夜景については、フラッシュ光が届かず、露出時間ET2も短いので露出不足となる。   Next, as the flash exposure setting, the gain (ISO sensitivity) is set to the minimum, the flash is set to the maximum light emission, and others are set so that the highest quality image can be taken under the above two conditions (step S76). Next, a flash is emitted for exposure (exposure period ET2 shown in FIG. 2), a subject (such as a person) in the foreground is photographed (step S78), transferred to the image buffer 26 as image data D2, and temporarily stored (step S78). Step S80). As shown in FIG. 5B, the close-up image is taken in a better state of the person who is the subject. However, the night view of the distant view is underexposed because the flash light does not reach and the exposure time ET2 is short.

次に、ステップS82〜S104で各画素のデータ作成のループ処理を実行する。まず、所定の座標の、高感度撮影時の画像データD1とフラッシュ発光撮影時の画像データD2とを読み込み(ステップS84)、画像データD1の輝度値が画像データD2の輝度値より大きい否かを判断する(ステップS86)。そして、高感度撮影時の画像データD1の輝度値の方が大きい場合、すなわち、図8の領域Cまたは領域Dである場合には、画像データD1の輝度値と画像データD2の輝度値との差が、図8に示す閾値THC2より大きいか否かを判断する(ステップS88)。そして、画像データD1の輝度値と画像データD2の輝度値との差が閾値THC2より大きい場合には、領域Dにあると判断し、1回目の高感度撮影時の画像データD1(D1×100%+D2×0%)を合成データとして画像メモリ31に保存する(ステップS90)。 Next, a loop process for creating data for each pixel is executed in steps S82 to S104. First, the predetermined coordinate, reading the image data D2 at the time of image data D1 and flash photography High ISO speed (step S84), the luminance value of the image data D1 whether larger than the luminance value of the image data D2 Is determined (step S86). When the brightness value of the image data D1 at the time of high-sensitivity shooting is larger, that is, in the region C or the region D in FIG. 8, the brightness value of the image data D1 and the brightness value of the image data D2 are It is determined whether or not the difference is larger than a threshold value THC2 shown in FIG. 8 (step S88). If the difference between the luminance value of the image data D1 and the luminance value of the image data D2 is larger than the threshold value THC2, it is determined that the region is in the region D, and the image data D1 (D1 × 100) at the time of the first high-sensitivity shooting. % + D2 × 0%) is stored in the image memory 31 as composite data (step S90).

一方、画像データD1の輝度値と画像データD2の輝度値との差が閾値THC2以下の場合には、領域Cにあると判断し、合成画像データDbとして、画像データD1×3/4+画像データD2×1/4を算出し(ステップS92)、該合成画像データDbを画像メモリ31に保存する(ステップS94)。   On the other hand, when the difference between the luminance value of the image data D1 and the luminance value of the image data D2 is equal to or less than the threshold value THC2, it is determined that the region is in the region C, and the combined image data Db is image data D1 × 3/4 + image data. D2 × 1/4 is calculated (step S92), and the composite image data Db is stored in the image memory 31 (step S94).

一方、ステップS86において、フラッシュ発光撮影時の画像データD2の輝度値の方が大きい場合には、すなわち、図8の領域Aまたは領域Bである場合には、画像データD1の輝度値と画像データD2の輝度値との差が、図8に示す閾値THC1より大きいか否かを判断する(ステップS96)。そして、画像データD1の輝度値と画像データD2の輝度値との差が閾値THC1より小さい場合には、領域Bにあると判断し、合成画像データDcとして、画像データD1×1/4+画像データD2×3/4を算出し(ステップS98)、該合成画像データDcを画像メモリ31に保存する(ステップS100)。   On the other hand, if the brightness value of the image data D2 at the time of flash photography is larger in step S86, that is, if it is the area A or the area B in FIG. 8, the brightness value of the image data D1 and the image data It is determined whether or not the difference between the luminance value of D2 is larger than the threshold value THC1 shown in FIG. 8 (step S96). If the difference between the luminance value of the image data D1 and the luminance value of the image data D2 is smaller than the threshold value THC1, it is determined that the region is in the region B, and the combined image data Dc is image data D1 × 1/4 + image data. D2 × 3/4 is calculated (step S98), and the composite image data Dc is stored in the image memory 31 (step S100).

一方、画像データD1の輝度値と画像データD2の輝度値との差が閾値THC1以上の場合には、領域Aにあると判断し、2回目のフラッシュ発光撮影時の画像データD2(D1×0%+D2×100%)を合成データとして画像メモリ31に保存する(ステップS102)。   On the other hand, when the difference between the luminance value of the image data D1 and the luminance value of the image data D2 is equal to or greater than the threshold value THC1, it is determined that the area is A, and the image data D2 (D1 × 0) at the time of the second flash photography. % + D2 × 100%) is stored in the image memory 31 as composite data (step S102).

この結果、合成された画像は、より良い状態で撮影された夜景とより良い状態で撮影された近景の被写体とが合成され、手ぶれのない、露出、S/N比のバランスが良好な撮影画像となる。   As a result, the synthesized image is composed of a night view taken in a better state and a subject in the foreground taken in a better state, and has a good balance between exposure and S / N ratio without camera shake. It becomes.

D.第4実施形態
次に、本発明の第4実施形態について説明する。なお、デジタルカメラの構成は、図1と同様であるので説明を省略する。本第4実施形態では、1回目の画像と2回目の画像とを合成する際の閾値、および合成比率を変えており、図11に示すように、閾値THD1〜THD4を設け、フラッシュ発光撮影時の輝度値と高感度撮影時の輝度値との関係で得られる領域を、9つの領域A〜Iに細分化している。そして、画素毎に、1回目の高感度撮影時に取り込んだ画像の輝度値と2回目のフラッシュ発光撮影時に取り込んだ画像の輝度値とを比較し、輝度値がどの領域にあるかで、記録用の画像(の画素)として用いる画素合成比率を決めるようになっている。
D. Fourth Embodiment Next, a fourth embodiment of the present invention will be described. The configuration of the digital camera is the same as that in FIG. In the fourth embodiment, the threshold value and the composition ratio for combining the first image and the second image are changed, and threshold values THD1 to THD4 are provided as shown in FIG. The area obtained by the relationship between the brightness value of the image and the brightness value at the time of high-sensitivity shooting is subdivided into nine areas A to I. Then, for each pixel, the luminance value of the image captured at the first high-sensitivity shooting is compared with the luminance value of the image captured at the second flash shooting, and it is determined whether the luminance value is in which area. The pixel composition ratio to be used as the (image) is determined.

例えば、領域A、Iでは、合成画像の画素値を、高感度撮影時の画像データD1×50%+フラッシュ発光撮影時の画像データD2×50%とし、領域B、C、E、G、Hでは、高感度撮影時の画像データD1×0%+フラッシュ発光撮影時の画像データD2×100%とし、領域D、Fでは、高感度撮影時の画像データD1×100%+フラッシュ発光撮影時の画像データD2×0%とする。これら閾値THD1〜THD4や画像データD1,D2との合成比率は、上述したRAM35にデータテーブルまたは計算式の形で記憶されている。なお、領域の判別、画像の合成については基本的に上述した第3実施形態などと同じであるので説明を省略する。   For example, in regions A and I, the pixel values of the composite image are set to image data D1 × 50% at the time of high-sensitivity shooting + image data D2 × 50% at the time of flash shooting, and regions B, C, E, G, H The image data D1 × 0% at the time of high-sensitivity shooting and the image data D2 × 100% at the time of flash shooting are set. In the regions D and F, the image data D1 × 100% at the time of high-sensitivity shooting + The image data D2 × 0%. The synthesis ratios of the threshold values THD1 to THD4 and the image data D1 and D2 are stored in the above-described RAM 35 in the form of a data table or a calculation formula. Note that the region determination and the image composition are basically the same as those in the third embodiment described above, and thus the description thereof is omitted.

E.変形例
次に、本発明の変形例について説明する。上述した第1ないし第4実施形態では、画素合成比率を決定するための領域毎に明らかに異なる合成比率を設定していた。すなわち、隣り合う領域においては、境界近傍に存在する場合であっても、合成比率が異なっていた。これに対して、本変形例では、図12に示すように、例えば、領域Aと領域Bとの境界部分をより細かい領域C1〜C6に分割し、段階的に合成比率を変化させるようにする。これにより、より精細な合成画像を得ることが可能となる。
E. Modified Example Next, a modified example of the present invention will be described. In the first to fourth embodiments described above, different composition ratios are clearly set for each region for determining the pixel composition ratio. That is, in the adjacent regions, the composition ratios are different even when they exist in the vicinity of the boundary. On the other hand, in this modification, as shown in FIG. 12, for example, the boundary portion between the region A and the region B is divided into finer regions C1 to C6, and the composition ratio is changed stepwise. . This makes it possible to obtain a finer composite image.

また、他の変形例としては、上述したように、領域Aと領域Bとの境界部分をより細かく分割するのではなく、実際にアナログ回路により合成比率を徐々に変化させるようにしてもよい。また、各位置の画素値を同じ位置の画素同士の合成により決定したが、周辺領域の画素を用いるようにしてもよい。また、3つ以上の撮影画像を用いてもよい。   As another modification, as described above, the boundary portion between the region A and the region B may not be divided more finely, but the synthesis ratio may actually be gradually changed by an analog circuit. Further, although the pixel value at each position is determined by combining the pixels at the same position, pixels in the peripheral area may be used. Three or more captured images may be used.

また、上述した実施形態では、手前の被写体部分と背景の被写体部分との識別と画素合成とを同時に行うことで、手前の被写体部分と背景の被写体部分とを正確に識別するための識別処理を不要としているが、被写体までの距離を示す測距情報などが利用できるのであれば、該測距情報を用いて識別するようにしてもよい。   In the above-described embodiment, identification processing for accurately identifying the front subject portion and the background subject portion is performed by simultaneously performing identification and pixel synthesis of the front subject portion and the background subject portion. Although not required, if distance measurement information indicating the distance to the subject can be used, the distance information may be used for identification.

また、上述した実施形態では、異なる画素合成方法を異なる実施形態として説明したが、複数の画素合成方法の中からモード選択により1つの画素合成方法を予め設定しておき、撮影指示が行われた際に設定モードを判別し、選択された画素合成方法に従って画素合成を実行するようにしてもよい。この場合、画素合成モードの設定は、ユーザが任意に指定してもよいし、外部の明るさをセンサで感知して自動設定するようにしてもよいし、撮像センサにより得られる画像情報に基づいて自動設定するようにしてもよい。   In the above-described embodiments, different pixel composition methods have been described as different embodiments. However, one pixel composition method is set in advance by mode selection from a plurality of pixel composition methods, and a shooting instruction is issued. At this time, the setting mode may be determined, and pixel synthesis may be executed according to the selected pixel synthesis method. In this case, the setting of the pixel synthesis mode may be arbitrarily specified by the user, may be set automatically by sensing external brightness with a sensor, or based on image information obtained by the image sensor. May be set automatically.

なお、上述した実施形態においては、デジタルカメラについてのみ説明したが、これ限らず、携帯電話などの撮像装置を備える電子機器に適用するようにしてもよい。また、上述した実施形態による画像合成処理等については、制御部20によるソフトウェア制御で実現されるものであるが、処理速度、汎用性、装置サイズ、コストなどを考慮して、その全てまたは一部を回路により実現するようにしてもよい。   In the above-described embodiment, only the digital camera has been described. However, the present invention is not limited to this, and the present invention may be applied to an electronic apparatus including an imaging device such as a mobile phone. In addition, the image composition processing and the like according to the above-described embodiment are realized by software control by the control unit 20, and all or part of them is considered in consideration of processing speed, versatility, device size, cost, and the like. May be realized by a circuit.

1 デジタルカメラ
10 画像取得部
11 レンズ
12 シャッタ
13 LPF
14 ドライバ
15 アナログ信号処理部
16 撮像センサ(撮像手段)
17 サンプリング/信号増幅処理部
18 A/Dコンバータ
19 フラッシュ(発光手段)
20 制御部(撮影感度設定手段、撮影制御手段)
22 プレビューエンジン
23 D/Aコンバータ
24 ドライバ
25 表示部
26 イメージバッファ
27 キー操作部
28 デジタル信号処理部(合成手段)
29 画像圧縮/伸張処理部
30 プログラムメモリ
31 画像メモリ
32 カードI/F
33 外部記録媒体
34 外部接続用I/F
35 RAM
1 Digital Camera 10 Image Acquisition Unit 11 Lens 12 Shutter 13 LPF
14 Driver 15 Analog Signal Processing Unit 16 Imaging Sensor (Imaging Means)
17 Sampling / Signal Amplification Processing Unit 18 A / D Converter 19 Flash (Light Emitting Unit)
20 control unit (photographing sensitivity setting means, photographing control means)
22 Preview Engine 23 D / A Converter 24 Driver 25 Display Unit 26 Image Buffer 27 Key Operation Unit 28 Digital Signal Processing Unit (Composition Unit)
29 Image compression / decompression processing unit 30 Program memory 31 Image memory 32 Card I / F
33 External recording medium 34 I / F for external connection
35 RAM

Claims (6)

被写体像を撮像する撮像手段と、
前記撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得手段と、
予め、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定手段と、
前記取得手段により取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記規定手段の規定に基づいて決定する決定手段と、
前記決定手段により決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録手段と、
を具備することを特徴とする撮像装置。
Imaging means for capturing a subject image;
Obtaining means for obtaining two image data by performing imaging under two different photographing conditions by the imaging means;
By dividing a region obtained by the relationship between two luminance values in advance with a plurality of inclined boundary lines, the region is subdivided into a plurality of regions, and by assigning a different composition ratio for each region, two luminance values and a composition ratio Defining means for defining the relationship between
Determination of determining a composition ratio corresponding to pixel values of two pixels to be combined based on the definition of the defining means when combining the two image data acquired by the acquisition means with different composition ratios for each pixel Means,
Synthesis recording means for recording image data obtained by synthesizing the two image data for each pixel at a synthesis ratio determined by the determination means;
An imaging apparatus comprising:
発光手段を更に備え、
前記取得手段は、前記発光手段を発光させて前記撮像手段により撮像した画像データと前記発光手段を発光させずに前記撮像手段により撮像した画像データを取得することを特徴とする請求項1に記載の撮像装置。
Further comprising a light emitting means,
Said acquisition means, according to claim 1, characterized in that acquires image data captured by the image pickup means said light emitting means and the image data picked up by the image pickup means by emitting the light emitting means without emitting Imaging device.
前記取得手段は、前記発光手段を発光させずに前記撮像手段により撮像する際には撮像感度を高くし、前記発光手段を発光させて前記撮像手段により撮像する際には撮像感度を低くすることを特徴とする請求項2記載の撮像装置。 The acquisition unit increases the imaging sensitivity when imaging by the imaging unit without causing the light emitting unit to emit light, and decreases the imaging sensitivity when imaging by the imaging unit by causing the light emitting unit to emit light. The imaging apparatus according to claim 2 . 前記取得手段は、一度の撮影指示に応じて、前記発光手段を発光させない前記撮像手段による撮像と、前記発光手段を発光させる前記撮像手段による撮像とを続けて行って前記2つの画像データを取得することを特徴とする請求項2または3に記載の撮像装置。   The acquisition unit obtains the two image data by continuously performing imaging by the imaging unit that does not cause the light emitting unit to emit light and imaging by the imaging unit that causes the light emitting unit to emit light according to a single shooting instruction. The imaging apparatus according to claim 2 or 3, wherein 撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得ステップと、
2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定情報を参照する参照ステップと、
前記取得ステップにより取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記参照ステップにより参照される規定情報に基づいて決定する決定ステップと、
前記決定ステップにより決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録ステップと、
を含むことを特徴とする撮像方法。
An acquisition step of performing imaging under two different imaging conditions by an imaging means to acquire two image data;
By dividing the region obtained by the relationship between the two luminance values by a plurality of inclined boundary lines, it is subdivided into a plurality of regions, and by assigning a different composition ratio for each region, the relationship between the two luminance values and the composition ratio A reference step for referring to regulation information that defines
When the two image data acquired in the acquisition step are combined at different combining ratios for each pixel, the combining ratio corresponding to the pixel values of the two pixels to be combined is based on the defining information referred to in the referring step. A decision step to decide,
A composite recording step for recording image data obtained by combining the two image data for each pixel at a composite ratio determined by the determination step;
An imaging method comprising:
撮像装置のコンピュータを、
被写体像を撮像する撮像手段と、
前記撮像手段により2つの異なる撮影条件で撮像を行って2つの画像データを取得する取得手段と、
予め、2つの輝度値の関係で得られる領域を複数の傾斜する境界線により区分することで複数の領域に細分化し、領域毎に異なる合成比率を割り当てることで、2つの輝度値と合成比率との関係を規定する規定手段と、
前記取得手段により取得した2つの画像データを画素毎に異なる合成比率で合成する際に、合成対象となる2つの画素の画素値に対応する合成比率を前記規定手段の規定に基づいて決定する決定手段と、
前記決定手段により決定される合成比率で前記2つの画像データを画素毎に合成した画像データを記録する合成記録手段と、
して機能させることを特徴とする撮像プログラム。
The computer of the imaging device,
Imaging means for capturing a subject image;
Obtaining means for obtaining two image data by performing imaging under two different photographing conditions by the imaging means;
By dividing a region obtained by the relationship between two luminance values in advance with a plurality of inclined boundary lines, the region is subdivided into a plurality of regions, and by assigning a different composition ratio for each region, two luminance values and a composition ratio Defining means for defining the relationship between
Determination of determining a composition ratio corresponding to pixel values of two pixels to be combined based on the definition of the defining means when combining the two image data acquired by the acquisition means with different composition ratios for each pixel Means,
Synthesis recording means for recording image data obtained by synthesizing the two image data for each pixel at a synthesis ratio determined by the determination means;
An imaging program characterized by causing the function to function.
JP2011225416A 2011-10-13 2011-10-13 Imaging apparatus, imaging method, and imaging program Expired - Fee Related JP5392336B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011225416A JP5392336B2 (en) 2011-10-13 2011-10-13 Imaging apparatus, imaging method, and imaging program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011225416A JP5392336B2 (en) 2011-10-13 2011-10-13 Imaging apparatus, imaging method, and imaging program

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2005314032A Division JP5156991B2 (en) 2005-10-28 2005-10-28 Imaging apparatus, imaging method, and imaging program

Publications (2)

Publication Number Publication Date
JP2012050121A JP2012050121A (en) 2012-03-08
JP5392336B2 true JP5392336B2 (en) 2014-01-22

Family

ID=45904366

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011225416A Expired - Fee Related JP5392336B2 (en) 2011-10-13 2011-10-13 Imaging apparatus, imaging method, and imaging program

Country Status (1)

Country Link
JP (1) JP5392336B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10074165B2 (en) 2014-09-10 2018-09-11 Morpho, Inc. Image composition device, image composition method, and recording medium
JP6823942B2 (en) * 2016-05-02 2021-02-03 株式会社モルフォ Image synthesizer, image synthesizer, image synthesizer program and storage medium
CN109997350B (en) 2017-10-31 2021-01-15 株式会社摩如富 Image synthesizing apparatus, image synthesizing method, and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004214836A (en) * 2002-12-27 2004-07-29 Minolta Co Ltd Imaging apparatus
JP2005072965A (en) * 2003-08-25 2005-03-17 Fuji Photo Film Co Ltd Image compositing method, solid-state image pickup device and digital camera

Also Published As

Publication number Publication date
JP2012050121A (en) 2012-03-08

Similar Documents

Publication Publication Date Title
US8947557B2 (en) Photographing apparatus and method for dynamic range adjustment and stereography
JP4008778B2 (en) Imaging device
US8576327B2 (en) Focus bracket photographing imaging apparatus, reproduction display apparatus, image recording method, and reproduction displaying method
JP5156991B2 (en) Imaging apparatus, imaging method, and imaging program
JP2008170932A (en) Imaging device, method for controlling exposure of imaging device
JP2010213090A (en) Imaging apparatus, imaging method, and imaging program
JP2007300581A (en) Moving image photographing apparatus and moving image photographing program
JP2010087599A (en) Imaging apparatus and method, and program
JP5392336B2 (en) Imaging apparatus, imaging method, and imaging program
US20080100724A1 (en) Image processing device and imaging device
JP2014179920A (en) Imaging apparatus, control method thereof, program, and storage medium
JP2002040321A (en) Electronic camera
JP4888829B2 (en) Movie processing device, movie shooting device, and movie shooting program
JP4877186B2 (en) Image processing apparatus, image processing method, and program
JP4678273B2 (en) Imaging apparatus, moving image storage method, and moving image storage program
JP6410416B2 (en) IMAGING DEVICE AND IMAGING DEVICE CONTROL METHOD
JP2010154390A (en) Imaging device, imaging method, and program
JP2010232961A (en) Image processor, image processing method and program
JP5136335B2 (en) CAMERA DEVICE, IMAGE CUTTING METHOD, PROGRAM
JP5332668B2 (en) Imaging apparatus and subject detection program
JP2007228233A (en) Photographic device
JP2006186796A (en) Photographic apparatus, photographing method, and photographing program
JP4964830B2 (en) Omnidirectional imaging apparatus and omnidirectional image imaging control method
JP5239687B2 (en) Imaging device
JP2008271181A (en) Imaging apparatus and imaging method, reproducing device and reproducing method, and imaged image processing system

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20121005

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20121030

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20121225

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20130604

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20130802

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130930

R150 Certificate of patent or registration of utility model

Ref document number: 5392336

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees