JP2010021915A - Digital camera - Google Patents

Digital camera Download PDF

Info

Publication number
JP2010021915A
JP2010021915A JP2008182357A JP2008182357A JP2010021915A JP 2010021915 A JP2010021915 A JP 2010021915A JP 2008182357 A JP2008182357 A JP 2008182357A JP 2008182357 A JP2008182357 A JP 2008182357A JP 2010021915 A JP2010021915 A JP 2010021915A
Authority
JP
Japan
Prior art keywords
shading correction
area
unit
digital camera
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP2008182357A
Other languages
Japanese (ja)
Inventor
Takashi Minagawa
貴志 皆川
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.)
Nikon Corp
Original Assignee
Nikon Corp
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 Nikon Corp filed Critical Nikon Corp
Priority to JP2008182357A priority Critical patent/JP2010021915A/en
Publication of JP2010021915A publication Critical patent/JP2010021915A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Studio Devices (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a digital camera capable of executing proper shading correction in accordance with a picked-up scene. <P>SOLUTION: The digital camera includes: an imaging section for imaging a subject and generating the data of the image; an evaluation value calculating section for dividing an imaging screen into a plurality of areas and calculating an evaluation value for each area based on the image data generated by the imaging section; a determination section for determining whether or not shading correction is performed for each area based on the evaluation value calculated by the evaluation value calculating section; and a shading correction section for executing shading correction for areas determined to be subjected to shading correction by the determination section and not executing shading correction for areas determined not to be subjected to shading correction. <P>COPYRIGHT: (C)2010,JPO&INPIT

Description

本発明は、被写体を撮像して画像のデータを生成するデジタルカメラに関する。   The present invention relates to a digital camera that images a subject and generates image data.

従来から、画像周辺の光量落ち(シェーディング)を補正するデジタルカメラが知られる。   2. Description of the Related Art Conventionally, a digital camera that corrects a light amount drop (shading) around an image is known.

例えば、特許文献1のデジタルカメラは、画像を複数のブロックに分割し、このブロックごとに1つずつ設定された光量補正データに基づいて、各画素ごとにシェーディング補正を行う。
特開2001−275029号公報
For example, the digital camera of Patent Document 1 divides an image into a plurality of blocks, and performs shading correction for each pixel based on light amount correction data set for each block.
JP 2001-275029 A

しかし、上述したデジタルカメラは、撮像した画像に対して一律にシェーディング補正を行う。そのため、必ずしも撮像シーンに応じた適切なシェーディング補正が施されない可能性がある。例えば、画像中の高輝度被写体が飽和するおそれがある。また、夜景など全体的に暗い画像は全体的に明るくなり、ユーザが違和感を感じることがある。さらに、エッジがある画像においてはノイズが目立つ場合がある。   However, the above-described digital camera uniformly performs shading correction on the captured image. Therefore, there is a possibility that appropriate shading correction according to the imaging scene is not necessarily performed. For example, a high brightness subject in the image may be saturated. In addition, an entirely dark image such as a night view becomes bright overall, and the user may feel uncomfortable. Furthermore, noise may be noticeable in an image having an edge.

そこで、本発明のデジタルカメラは、撮像シーンに応じた適切なシェーディング補正を行うことを目的とする。   Therefore, an object of the digital camera of the present invention is to perform an appropriate shading correction according to an imaging scene.

本発明のデジタルカメラは、被写体を撮像して画像のデータを生成する撮像部と、撮像画面を複数のエリアに分割し、前記撮像部により生成した前記画像のデータに基づいて前記エリアごとに評価値を算出する評価値算出部と、前記評価値算出部により算出した前記評価値に基づいて、前記エリアごとにシェーディング補正を行うか否かを判定する判定部と、前記判定部によりシェーディング補正を行うと判定したエリアにシェーディング補正を行い、シェーディング補正を行わないと判定したエリアにシェーディング補正を行わないシェーディング補正部とを備える。   The digital camera of the present invention includes an imaging unit that captures a subject and generates image data, and an imaging screen that is divided into a plurality of areas, and is evaluated for each area based on the image data generated by the imaging unit. An evaluation value calculation unit that calculates a value, a determination unit that determines whether or not to perform shading correction for each area based on the evaluation value calculated by the evaluation value calculation unit, and shading correction by the determination unit A shading correction unit that performs shading correction on an area determined to be performed and does not perform shading correction on an area determined not to perform shading correction.

なお、好ましくは、前記エリアごとにそれぞれ対応するシェーディング補正値を予め格納するメモリをさらに備え、前記判定部は、前記評価値算出部により算出した前記評価値と前記メモリに格納された前記シェーディング補正値とを比較することにより、前記エリアごとにシェーディング補正を行うか否かを判定しても良い。   Preferably, the image processing apparatus further includes a memory that stores in advance a shading correction value corresponding to each area, and the determination unit calculates the evaluation value calculated by the evaluation value calculation unit and the shading correction stored in the memory. It may be determined whether shading correction is performed for each area by comparing the values.

また、好ましくは、前記判定部は、前記評価値算出部により算出した前記評価値と閾値とを比較することにより、前記エリアごとにシェーディング補正を行うか否かを判定しても良い。   Preferably, the determination unit may determine whether to perform shading correction for each area by comparing the evaluation value calculated by the evaluation value calculation unit with a threshold value.

また、好ましくは、前記撮像部により生成した前記画像のデータに基づいて、前記エリアごとにエッジを検出するエッジ検出部をさらに備え、前記判定部は、前記エッジ検出部により前記エッジを検出したエリアにシェーディング補正を行い、前記エッジを検出しないエリアにシェーディング補正を行わないと判定しても良い。   Preferably, the image processing apparatus further includes an edge detection unit that detects an edge for each area based on the image data generated by the imaging unit, and the determination unit detects the edge by the edge detection unit. Alternatively, it may be determined that the shading correction is not performed on the area where the edge is not detected.

また、好ましくは、前記撮像部により生成した前記画像のデータに基づいて、前記エリアごとにエッジ量を算出するエッジ量算出部をさらに備え、前記判定部は、前記画像の中心に位置するエリアの前記評価値と前記画像の周辺に位置するエリアの前記評価値との比率が、前記画像の周辺に位置するエリアに対応する前記シェーディング補正値の逆数に近似し、かつ、前記画像の周辺に位置するエリアの前記エッジ量が閾値以下である場合に、シェーディング補正を行うと判定しても良い。   Preferably, the image processing apparatus further includes an edge amount calculation unit that calculates an edge amount for each area based on the data of the image generated by the imaging unit, and the determination unit includes an area located at the center of the image. The ratio between the evaluation value and the evaluation value of the area located around the image approximates the reciprocal of the shading correction value corresponding to the area located around the image, and is located around the image. It may be determined that the shading correction is performed when the edge amount of the area to be processed is equal to or smaller than the threshold value.

また、好ましくは、前記被写体の輝度を測光する測光部と、前記測光部により測光した前記輝度に応じたゲイン値を算出するゲイン値算出部とをさらに備え、前記シェーディング補正部は、前記ゲイン値算出部により算出した前記ゲイン値に基づいて、シェーディング補正を行っても良い。   In addition, preferably, it further includes a photometry unit that measures the luminance of the subject, and a gain value calculation unit that calculates a gain value corresponding to the luminance measured by the photometry unit, and the shading correction unit includes the gain value Shading correction may be performed based on the gain value calculated by the calculation unit.

また、好ましくは、前記撮像部により生成した前記画像に含まれる全エリアの前記評価値の平均値を算出する平均値算出部と、前記平均値算出部により算出した前記平均値に応じたゲイン値を算出するゲイン値算出部とをさらに備え、前記シェーディング補正部は、前記ゲイン値算出部により算出した前記ゲイン値に基づいて、シェーディング補正を行っても良い。   Preferably, an average value calculation unit that calculates an average value of the evaluation values of all areas included in the image generated by the imaging unit, and a gain value corresponding to the average value calculated by the average value calculation unit And a shading correction unit that performs shading correction based on the gain value calculated by the gain value calculation unit.

本発明のデジタルカメラによれば、撮像シーンに応じた適切なシェーディング補正を行うことができる。   According to the digital camera of the present invention, it is possible to perform appropriate shading correction according to the imaging scene.

以下、図面を用いて本発明の実施形態について説明する。図1は、本発明の実施形態におけるデジタルカメラ1の構成を示すブロック図である。図1に示すように、デジタルカメラ1は、撮像レンズ2、撮像素子3、A/D変換部4、画像処理部5、バッファメモリ6、メモリ7、制御部8、表示部9、記録I/F部10、記録媒体11、操作部12、バス13を備える。   Hereinafter, embodiments of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing a configuration of a digital camera 1 according to an embodiment of the present invention. As shown in FIG. 1, the digital camera 1 includes an imaging lens 2, an imaging device 3, an A / D conversion unit 4, an image processing unit 5, a buffer memory 6, a memory 7, a control unit 8, a display unit 9, a recording I / O. An F unit 10, a recording medium 11, an operation unit 12, and a bus 13 are provided.

撮像レンズ2は、撮像素子3の撮像面に被写体像を結像する。撮像素子3は、撮像レンズ2を通過した光束による被写体像を光電変換し、R,G,Bの各色に対応するアナログ画像信号を出力する。ここで、撮像モードにおいて、撮像素子3は、後述のレリーズ釦が全押しされると記録用画像(本画像)を撮像する。また、撮像素子3は、撮像待機時にも所定間隔ごとに間引き読み出しでスルー画像を撮像する。撮像素子3の出力は、A/D変換部4に接続される。A/D変換部4は、撮像素子3の出力信号のA/D変換を行う。   The imaging lens 2 forms a subject image on the imaging surface of the imaging element 3. The image sensor 3 photoelectrically converts a subject image formed by a light beam that has passed through the imaging lens 2 and outputs an analog image signal corresponding to each of R, G, and B colors. Here, in the imaging mode, the imaging device 3 captures a recording image (main image) when a release button described later is fully pressed. Further, the imaging device 3 captures a through image by thinning-out reading at predetermined intervals even during standby for imaging. The output of the image sensor 3 is connected to the A / D converter 4. The A / D conversion unit 4 performs A / D conversion of the output signal of the image sensor 3.

画像処理部5は、A/D変換部4から出力されたデータに各種の画像処理(ホワイトバランス調整、シェーディング補正、色補間、階調変換処理、輪郭強調処理など)を施す。また、画像処理部5は、記録媒体11に画像のデータを記録する前にJPEG形式などで圧縮する処理や、圧縮された上記のデータを伸長復元する処理をも実行する。バッファメモリ6は、画像処理部5による画像処理の前工程や後工程で画像のデータを一時的に記録する。   The image processing unit 5 performs various types of image processing (white balance adjustment, shading correction, color interpolation, gradation conversion processing, contour enhancement processing, etc.) on the data output from the A / D conversion unit 4. The image processing unit 5 also executes a process of compressing the image data in the JPEG format before recording the image data on the recording medium 11 and a process of decompressing and restoring the compressed data. The buffer memory 6 temporarily records image data in the pre-process and post-process of the image processing by the image processing unit 5.

メモリ7は、画像周辺の光量落ちを補正するためのシェーディング補正テーブル7aを有する。シェーディング補正テーブル7aの詳細については、後述する。制御部8は、所定のシーケンスプログラムにしたがって、デジタルカメラ1の統括的な制御を行うプロセッサである。制御部8は、撮像時に必要となる各種演算や、後述するシェーディング補正値の演算などを行う。   The memory 7 has a shading correction table 7a for correcting a light amount drop around the image. Details of the shading correction table 7a will be described later. The control unit 8 is a processor that performs overall control of the digital camera 1 in accordance with a predetermined sequence program. The control unit 8 performs various calculations required at the time of imaging, calculation of shading correction values described later, and the like.

表示部9は、制御部8の制御により各種の画像を表示する。表示部9に表示される各種の画像は、本画像、スルー画像、記録媒体11に記録した画像、メニュー画面などを含む。記録I/F部10は、記録媒体11を接続するためのコネクタが形成される。そして、記録I/F部10は、コネクタに接続された記録媒体11に対してデータの書き込み/読み出しを実行する。操作部12は、レリーズ釦、操作釦などを有する。レリーズ釦は、レリーズ指示の入力をユーザーから受け付ける。操作釦は、上記のメニュー画面等での操作入力をユーザから受け付ける。なお、操作部12の状態は制御部8により検知される。   The display unit 9 displays various images under the control of the control unit 8. Various images displayed on the display unit 9 include a main image, a through image, an image recorded on the recording medium 11, a menu screen, and the like. The recording I / F unit 10 is formed with a connector for connecting the recording medium 11. Then, the recording I / F unit 10 executes data writing / reading with respect to the recording medium 11 connected to the connector. The operation unit 12 includes a release button, an operation button, and the like. The release button receives an input of a release instruction from the user. The operation button receives an operation input on the menu screen or the like from the user. The state of the operation unit 12 is detected by the control unit 8.

なお、画像処理部5、バッファメモリ6、メモリ7、制御部8、記録I/F部10はそれぞれバス13を介して相互に接続される。A/D変換部4の出力はバス13を介して画像処理部5に接続される。また、画像処理部5、記録I/F部10の出力はそれぞれバス13を介して表示部9に接続される。   The image processing unit 5, the buffer memory 6, the memory 7, the control unit 8, and the recording I / F unit 10 are connected to each other via a bus 13. The output of the A / D conversion unit 4 is connected to the image processing unit 5 via the bus 13. The outputs of the image processing unit 5 and the recording I / F unit 10 are connected to the display unit 9 via the bus 13.

図2は、デジタルカメラ1における撮像時の制御部8の動作を示すフローチャートである。なお、以下、画像を35個のエリアに分割する例を示す。   FIG. 2 is a flowchart showing the operation of the control unit 8 at the time of imaging in the digital camera 1. An example in which an image is divided into 35 areas will be described below.

ステップS1で、制御部8は、撮像モードを開始する。例えば、制御部8は、撮像素子3を制御して、スルー画像の撮像を開始する。   In step S1, the control unit 8 starts an imaging mode. For example, the control unit 8 controls the imaging device 3 to start capturing a through image.

ステップS2で、制御部8は、露出演算を行う。例えば、制御部8は、ステップS1で撮像したスルー画像のデータに基づいて、Bv値(被写体輝度)を算出する。そして、制御部8は、Bv値、操作釦を介してメニュー画面により設定された撮像感度や露出モード(例えば、プログラム優先の露出モード、絞り優先の露出モード、シャッター速度優先の露出モードなど)などの撮像条件に基づいて、シャッター速度、絞り値を算出する。   In step S2, the control unit 8 performs an exposure calculation. For example, the control unit 8 calculates a Bv value (subject brightness) based on the data of the through image captured in step S1. Then, the control unit 8 sets the Bv value, the imaging sensitivity and the exposure mode set on the menu screen via the operation buttons (for example, the program priority exposure mode, the aperture priority exposure mode, the shutter speed priority exposure mode, etc.). The shutter speed and aperture value are calculated based on the imaging conditions.

ステップS3で、制御部8は、レリーズ釦が全押しされたか否かを判定する。レリーズ釦が全押しされた場合(YES)には、ステップS4に移行する。一方、レリーズ釦が全押しされない場合(NO)には、レリーズ釦が全押しされるまで待機する。   In step S3, the control unit 8 determines whether or not the release button has been fully pressed. If the release button is fully pressed (YES), the process proceeds to step S4. On the other hand, if the release button is not fully pressed (NO), the process waits until the release button is fully pressed.

ステップS4で、制御部8は、本画像を撮像する。ステップS4で撮像した本画像の例を図3に示す。   In step S4, the control unit 8 captures the main image. An example of the main image captured in step S4 is shown in FIG.

ここで、シェーディング補正テーブル7aについて説明する。シェーディング補正テーブル7aは、エリアごとにそれぞれ対応するシェーディング補正値を格納する。シェーディング補正テーブル7aの例を図4に示す。以下、いずれかのエリアの輝度をYn、画像の中心部分に位置するエリアの輝度をYとし、上記いずれかのエリアに対応するシェーディング補正値をGn、画像の中心部分に位置するエリアに対応するシェーディング補正値をGとする。なお、均一輝度面を撮像した場合には、YとYnとの比率(Yn/Y)と、GnとGとの比率(G/Gn)とは一致する。   Here, the shading correction table 7a will be described. The shading correction table 7a stores a shading correction value corresponding to each area. An example of the shading correction table 7a is shown in FIG. In the following, the luminance of any area is Yn, the luminance of the area located in the center of the image is Y, the shading correction value corresponding to any of the above areas is Gn, and the area located in the central part of the image corresponds to Let G be the shading correction value. When a uniform luminance surface is imaged, the ratio of Y and Yn (Yn / Y) and the ratio of Gn and G (G / Gn) coincide.

ところで、デジタルカメラ1により撮像する画像は、均一輝度面だけではなく、例えば、周辺に高輝度の被写体がある画像、夜景など全体的に暗い画像、上方は平面的で下方にエッジがある風景の画像など様々である。このように様々な画像のデータに対して一律にシェーディング補正を行うと、周辺に高輝度の被写体がある場合には、高輝度の被写体が飽和するおそれがある。また、夜景など全体的に暗い画像は、全体的に明るくなり、ユーザが違和感を感じることがある。さらに、エッジがある部分についてはノイズが目立つ場合がある。なお、このノイズを抑制するためにノイズ低減処理を強めると、ディテールが損なわれるという問題が生じる。   By the way, the image captured by the digital camera 1 is not limited to a uniform luminance surface, for example, an image having a high-luminance subject in the periphery, a dark image such as a night scene, a landscape with a flat upper side and an edge on the lower side. There are various images. If shading correction is uniformly performed on various image data in this way, if there is a high-luminance subject in the vicinity, the high-luminance subject may be saturated. Also, an overall dark image such as a night view is generally brighter and the user may feel uncomfortable. Further, noise may be conspicuous in a portion having an edge. Note that if the noise reduction processing is strengthened to suppress this noise, there is a problem that details are lost.

そこで、本実施形態のデジタルカメラ1は、以下の処理を行って、撮像シーンに応じた適切なシェーディング補正を行う。   Therefore, the digital camera 1 of the present embodiment performs the following processing to perform appropriate shading correction according to the imaging scene.

ステップS5で、制御部8は、ステップS4で撮像した本画像に含まれる全エリアについて、エリアごとに輝度を算出する。   In step S5, the control unit 8 calculates the luminance for each area for all areas included in the main image captured in step S4.

ステップS6で、制御部8は、画像全体の明るさに応じたゲイン値を算出する。なお、画像全体の明るさとゲイン値との関係は、予めメモリ7に記録される。図5は、画像全体の明るさとゲイン値との関係を示す図である。例えば、制御部8は、ステップS5で算出したエリアごとの輝度の総和を全エリア数35で割り、全エリアの輝度の平均値を算出し、画像全体の明るさとする。そして、制御部8は、メモリ7に記録した関係に基づいて、ゲイン値を算出する。なお、制御部8は、ステップS2で算出したBv値を画像全体の明るさとしても良い。   In step S6, the control unit 8 calculates a gain value corresponding to the brightness of the entire image. The relationship between the brightness of the entire image and the gain value is recorded in the memory 7 in advance. FIG. 5 is a diagram illustrating the relationship between the brightness of the entire image and the gain value. For example, the control unit 8 divides the total luminance for each area calculated in step S5 by the total number of areas 35, calculates the average value of the luminance of all the areas, and sets the brightness of the entire image. Then, the control unit 8 calculates a gain value based on the relationship recorded in the memory 7. Note that the control unit 8 may use the Bv value calculated in step S2 as the brightness of the entire image.

ステップS7で、制御部8は、シェーディング補正テーブル7aから全エリアのシェーディング補正値を読み出す。そして、制御部8は、ステップS5で算出した輝度と読み出したシェーディング補正値とをエリアごとに比較する。例えば、制御部8は、エリアごとに以下の式を満たすか否かを判定する。なお、Thは閾値である。   In step S7, the control unit 8 reads the shading correction values for all areas from the shading correction table 7a. Then, the control unit 8 compares the luminance calculated in step S5 with the read shading correction value for each area. For example, the control unit 8 determines whether or not the following expression is satisfied for each area. Note that Th is a threshold value.

|Yn/Y−G/Gn|≦Th
ステップS8で、制御部8は、ステップS7で判定した結果に基づいて、シェーディング補正を行うか否かのフラグAをエリアごとに設定する。例えば、制御部8は、上記の式を満たす場合には、シェーディング補正を行うと判定し、フラグAを1に設定する。一方、制御部8は、上記の式を満たさない場合には、シェーディング補正を行わないと判定し、フラグAを0に設定する。これにより、画像中の高輝度の被写体が飽和するおそれを減らすことができる。エリアごとにフラグAを設定した例を図6(a)に示す。
| Yn / YG / Gn | ≦ Th
In step S8, the control unit 8 sets a flag A for determining whether or not to perform shading correction for each area based on the result determined in step S7. For example, if the above equation is satisfied, the control unit 8 determines to perform shading correction and sets the flag A to 1. On the other hand, if the above equation is not satisfied, the control unit 8 determines that the shading correction is not performed, and sets the flag A to 0. Thereby, a possibility that the high-intensity subject in the image is saturated can be reduced. An example in which the flag A is set for each area is shown in FIG.

ステップS9で、制御部8は、ステップS4で撮像した本画像に含まれる全エリアについて、エリアごとにエッジ量を算出する。例えば、制御部8は、エリアに含まれる各画素の輝度と当該画素に隣接する画素の輝度の差分に基づいて、エッジ量を算出する。   In step S9, the control unit 8 calculates an edge amount for each area for all areas included in the main image captured in step S4. For example, the control unit 8 calculates the edge amount based on the difference between the luminance of each pixel included in the area and the luminance of the pixel adjacent to the pixel.

ステップS10で、制御部8は、ステップS9で算出したエッジ量が閾値以下か否かをエリアごとに判定する。   In step S10, the control unit 8 determines for each area whether or not the edge amount calculated in step S9 is equal to or less than a threshold value.

ステップS11で、制御部8は、ステップS10で判定した結果に基づいて、シェーディング補正を行うか否かのフラグBをエリアごとに設定する。例えば、制御部8は、エッジ量が閾値以下である場合には、シェーディング補正を行うと判定し、フラグBを1に設定する。エッジ量が小さいエリアは、平面的でのっぺりとしており、シェーディングが目立ちやすいためである。   In step S11, the control unit 8 sets, for each area, a flag B indicating whether or not to perform shading correction based on the result determined in step S10. For example, if the edge amount is less than or equal to the threshold, the control unit 8 determines that shading correction is to be performed, and sets the flag B to 1. This is because an area with a small edge amount is flat and smooth, and shading is conspicuous.

一方、制御部8は、エッジ量が閾値より大きい場合には、シェーディング補正を行わないと判定し、フラグBを0に設定する。エッジ量が大きいエリアは、凹凸があるため、シェーディングが目立たない。また、シェーディング補正値を掛ける分のノイズを増やさないようにするためである。エリアごとにフラグBを設定した例を図6(b)に示す。   On the other hand, when the edge amount is larger than the threshold value, the control unit 8 determines that the shading correction is not performed, and sets the flag B to 0. In areas where the amount of edges is large, shading is inconspicuous due to irregularities. Another reason is not to increase the noise multiplied by the shading correction value. An example in which the flag B is set for each area is shown in FIG.

ステップS12で、制御部8は、ステップS8で設定したフラグAおよびステップS11で設定したフラグBに基づいて、シェーディング補正を行うか否かの最終的なフラグCをエリアごとに設定する。例えば、制御部8は、フラグAが1、かつ、フラグBが1であるエリアには、シェーディング補正を行うと判定し、フラグCを1に設定する。一方、制御部8は、フラグAが0、または、フラグBが0であるエリアには、シェーディング補正を行わないと判定し、フラグCを0に設定する。エリアごとにフラグCを設定した例を図6(c)に示す。   In step S12, the control unit 8 sets a final flag C for determining whether to perform shading correction for each area based on the flag A set in step S8 and the flag B set in step S11. For example, the control unit 8 determines that shading correction is performed for an area where the flag A is 1 and the flag B is 1, and sets the flag C to 1. On the other hand, the control unit 8 determines that no shading correction is performed in an area where the flag A is 0 or the flag B is 0, and sets the flag C to 0. An example in which the flag C is set for each area is shown in FIG.

ステップS13で、制御部8は、シェーディング補正テーブル7aから全エリアのシェーディング補正値を読み出す。そして、制御部8は、ステップS6で算出したゲイン値に基づいて、読み出したシェーディング補正値をエリアごとに変更する。変更後のシェーディング補正値をG'nとすると、G'nは以下の式で表される。   In step S13, the control unit 8 reads the shading correction values for all areas from the shading correction table 7a. And the control part 8 changes the read shading correction value for every area based on the gain value calculated by step S6. When the shading correction value after change is G′n, G′n is expressed by the following equation.

G'n=(Gn−1)×(ゲイン値)+1
これにより、画像全体の明るさに応じてシェーディング補正値を変更することができる。例えば、図5に示すように、画像全体が暗くなるほどゲイン値が0に近づくため、シェーディング補正値は小さくなる。したがって、例えば、全体的に暗い夜景を撮像した場合には、全体的に明るくならず、夜景の雰囲気が損なわれない。
G′n = (Gn−1) × (gain value) +1
Thereby, the shading correction value can be changed according to the brightness of the entire image. For example, as shown in FIG. 5, the gain value approaches 0 as the entire image becomes darker, so the shading correction value becomes smaller. Therefore, for example, when a dark night scene is imaged as a whole, the entire scene is not bright and the night scene atmosphere is not impaired.

ステップS14で、制御部8は、シェーディング補正を行うエリアと行わないエリアとの境界にあるエリア(以下、境界エリアという)のシェーディング補正値を再算出する。例えば、制御部8は、ステップS12で設定したフラグCが0であるエリアのうち、隣接するエリアのフラグCが1であるエリアを抽出して、境界エリアとする。そして、制御部8は、境界エリアごとに、ステップS13で変更した境界エリアのシェーディング補正値と、シェーディング補正を行わない場合のシェーディング補正値「1」との平均値を算出する。再算出後の境界エリアのシェーディング補正値をG''nとすると、G''nは以下の式で表される。   In step S14, the control unit 8 recalculates the shading correction value of an area at the boundary between the area where shading correction is performed and the area where shading correction is not performed (hereinafter referred to as a boundary area). For example, the control unit 8 extracts an area where the flag C of the adjacent area is 1 from the areas where the flag C set in step S12 is 0, and sets it as a boundary area. Then, for each boundary area, the control unit 8 calculates an average value of the shading correction value of the boundary area changed in step S13 and the shading correction value “1” when no shading correction is performed. If the shading correction value of the boundary area after recalculation is G ″ n, G ″ n is expressed by the following equation.

G''n=(G'n+1)/2
これにより、境界エリアのシェーディング補正値が平滑化されるため、シェーディング補正を行うエリアと行わないエリアとの境界が目立ちにくくなる。
G ″ n = (G′n + 1) / 2
Thereby, since the shading correction value of the boundary area is smoothed, the boundary between the area where the shading correction is performed and the area where the shading correction is not performed becomes inconspicuous.

ステップS15で、制御部8は、最終的なシェーディング補正テーブルを作成する。例えば、制御部8は、ステップS12で設定したフラグCが1であるエリアに対して、ステップS13で変更したシェーディング補正値を設定する。また、制御部8は、ステップS14で抽出した境界エリアに対して、ステップS14で再算出したシェーディング補正値を設定する。そして、制御部8は、上記以外のエリア、すなわち、フラグCが0であり、かつ、隣接するエリアのフラグCが0であるエリアに対して、「1」を設定する。最終的なシェーディング補正テーブルの例を図6(d)に示す。   In step S15, the control unit 8 creates a final shading correction table. For example, the control unit 8 sets the shading correction value changed in step S13 for the area where the flag C set in step S12 is 1. Further, the control unit 8 sets the shading correction value recalculated in step S14 for the boundary area extracted in step S14. Then, the control unit 8 sets “1” for an area other than the above, that is, an area where the flag C is 0 and the flag C of the adjacent area is 0. An example of the final shading correction table is shown in FIG.

ステップS16で、制御部8は、画像処理部5を制御して、ステップS4で撮像した本画像のデータに各種の画像処理を行うとともに、ステップS15で作成した最終的なシェーディング補正テーブルに基づいて、エリアごとに対応するシェーディング補正値を掛ける。   In step S16, the control unit 8 controls the image processing unit 5 to perform various types of image processing on the main image data captured in step S4, and based on the final shading correction table created in step S15. Multiply the shading correction value corresponding to each area.

ステップS17で、制御部8は、ステップS16で処理を行った本画像のデータを記録媒体11に記録する。   In step S17, the control unit 8 records the data of the main image processed in step S16 on the recording medium 11.

以上説明したように、本実施形態のデジタルカメラによれば、エリアごとにシェーディング補正を行うか否かを判定する。そして、シェーディング補正を行うと判定したエリアにシェーディング補正を行い、シェーディング補正を行わないと判定したエリアにシェーディング補正を行わない。したがって、撮像シーンに応じた適切なシェーディング補正を行うことができる。   As described above, according to the digital camera of this embodiment, it is determined whether or not to perform shading correction for each area. Then, the shading correction is performed on the area determined to perform the shading correction, and the shading correction is not performed on the area determined not to perform the shading correction. Therefore, appropriate shading correction according to the imaging scene can be performed.

なお、ステップS8において、ステップS5で算出した輝度とシェーディング補正値とを比較することにより、フラグAを設定したが、これに限らない。例えば、制御部8は、ステップS5で算出した輝度が閾値以下か否かをエリアごとに判定する。そして、ステップS5で算出した輝度が閾値以下の場合には、フラグAを1に設定する。一方、ステップS5で算出した輝度が閾値より大きい場合には、フラグAを0に設定しても良い。また、ステップS2で算出したBv値が閾値以下か否かをエリアごとに判定して、上記と同様に、フラグAを設定しても良い。   In step S8, the flag A is set by comparing the luminance calculated in step S5 with the shading correction value. However, the present invention is not limited to this. For example, the control unit 8 determines for each area whether or not the luminance calculated in step S5 is equal to or less than a threshold value. If the brightness calculated in step S5 is equal to or less than the threshold, the flag A is set to 1. On the other hand, if the luminance calculated in step S5 is greater than the threshold, the flag A may be set to 0. Further, it may be determined for each area whether or not the Bv value calculated in step S2 is equal to or less than a threshold value, and the flag A may be set in the same manner as described above.

また、上記の実施形態において、制御部8は、スルー画像のデータに基づいてBv値を算出したが、これに限らない。例えば、デジタルカメラ1は、被写体の輝度を測光する測光センサを備える。そして、制御部8は、測光センサの出力に基づいて、Bv値を算出しても良い。   In the above embodiment, the control unit 8 calculates the Bv value based on the data of the through image. However, the present invention is not limited to this. For example, the digital camera 1 includes a photometric sensor that measures the luminance of a subject. Then, the control unit 8 may calculate the Bv value based on the output of the photometric sensor.

また、ステップS14において、制御部8は、境界エリアのシェーディング補正値を用たが、これに限らない。例えば、制御部8は、境界エリアのシェーディング補正値の代わりに、境界エリアに隣接し、かつ、ステップS12で設定したフラグCが1であるエリアのステップS13で変更したシェーディング補正値を用いても良い。   In step S14, the control unit 8 uses the shading correction value of the boundary area, but the present invention is not limited to this. For example, the control unit 8 may use the shading correction value changed in step S13 in the area adjacent to the boundary area and having the flag C set to 1 in step S12, instead of the shading correction value in the boundary area. good.

また、上記の実施形態では、ステップS4で撮像した本画像に対してシェーディング補正を行う例を示したが、これに限らない。例えば、制御部8は、記録媒体11に記録した画像に対してシェーディング補正を行っても良い。この場合、制御部8は、記録媒体11に記録した画像のファイルから機種名を読み出す。そして、デジタルカメラ1と同じ機種のデジタルカメラにより撮像した画像であると判定した場合には、記録媒体11に記録した画像のデータに基づいて、ステップS5からステップS17までの処理を行っても良い。   In the above embodiment, an example in which shading correction is performed on the main image captured in step S4 has been described. However, the present invention is not limited to this. For example, the control unit 8 may perform shading correction on the image recorded on the recording medium 11. In this case, the control unit 8 reads the model name from the image file recorded on the recording medium 11. If it is determined that the image is captured by a digital camera of the same model as the digital camera 1, the processing from step S5 to step S17 may be performed based on the image data recorded on the recording medium 11. .

また、上記の実施形態では、制御部8は、ステップS16で画像処理部5を制御することによりシェーディング補正を行ったが、これに限らない。例えば、撮像素子3がCMOS(Complementary Metal Oxide Semiconductor)イメージセンサの場合には、画素ごとに予め露光時間を設定することができる。そのため、制御部8は、撮像素子3がCMOSイメージセンサの場合には、ステップS3でレリーズ釦が全押される直前のスルー画像のデータに基づいて、ステップS5からステップS15までの処理を行い、最終的なシェーディング補正テーブルを作成する。そして、制御部8は、この最終的なシェーディング補正テーブルに基づいて、各画素の露光時間を設定する。その後、制御部8は、ステップS3でレリーズ釦が全押しされた場合には、設定した露光時間ごとに撮像素子3からアナログ画像信号を読み出しても良い。なお、この場合、ステップS16において、制御部8は、画像処理部5を制御して、シェーディング補正を行わない。したがって、シェーディング補正値を掛ける分のノイズを減らすことができる。   In the above embodiment, the control unit 8 performs the shading correction by controlling the image processing unit 5 in step S <b> 16, but is not limited thereto. For example, when the imaging device 3 is a CMOS (Complementary Metal Oxide Semiconductor) image sensor, the exposure time can be set in advance for each pixel. Therefore, when the image pickup device 3 is a CMOS image sensor, the control unit 8 performs the processing from step S5 to step S15 based on the data of the through image immediately before the release button is fully pressed in step S3. A typical shading correction table. Then, the control unit 8 sets the exposure time of each pixel based on this final shading correction table. Thereafter, when the release button is fully pressed in step S3, the control unit 8 may read an analog image signal from the image sensor 3 for each set exposure time. In this case, in step S16, the control unit 8 controls the image processing unit 5 and does not perform shading correction. Therefore, it is possible to reduce noise corresponding to the shading correction value.

また、上記の実施形態では、エリアごとに1つずつシェーディング補正を設定したが、これに限らない。例えば、エリアごとにR,G,Bの各色に対応するシェーディング補正値を設定しても良い。なお、シェーディング補正値は、デジタルカメラ1の個体調整による値、製造ばらつきの中心値、撮像レンズ2および不図示の鏡筒設定値から得られる値などに基づいて設定しても良い。   In the above embodiment, one shading correction is set for each area, but the present invention is not limited to this. For example, shading correction values corresponding to R, G, and B colors may be set for each area. The shading correction value may be set based on a value obtained by individual adjustment of the digital camera 1, a center value of manufacturing variation, a value obtained from the imaging lens 2 and a lens barrel setting value (not shown), and the like.

本発明の実施形態におけるデジタルカメラ1の構成を示すブロック図である。It is a block diagram which shows the structure of the digital camera 1 in embodiment of this invention. デジタルカメラ1における撮像時の制御部8の動作を示すフローチャートである。4 is a flowchart illustrating an operation of the control unit 8 at the time of imaging in the digital camera 1. ステップS4で撮像した本画像の例を示す図である。It is a figure which shows the example of the main image imaged in step S4. シェーディング補正テーブル7aの例を示す図である。It is a figure which shows the example of the shading correction table 7a. 画像全体の明るさとゲイン値との関係を示す図である。It is a figure which shows the relationship between the brightness of the whole image, and a gain value. エリアごとにフラグを設定した例を示す図と最終的なシェーディング補正テーブルとを示す図である。It is a figure which shows the example which set the flag for every area, and a figure which shows the final shading correction table.

符号の説明Explanation of symbols

3…撮像素子、4…A/D変換部、5…画像処理部、7…メモリ、7a…シェーディング補正テーブル、8…制御部
DESCRIPTION OF SYMBOLS 3 ... Imaging device, 4 ... A / D conversion part, 5 ... Image processing part, 7 ... Memory, 7a ... Shading correction table, 8 ... Control part

Claims (7)

被写体を撮像して画像のデータを生成する撮像部と、
撮像画面を複数のエリアに分割し、前記撮像部により生成した前記画像のデータに基づいて前記エリアごとに評価値を算出する評価値算出部と、
前記評価値算出部により算出した前記評価値に基づいて、前記エリアごとにシェーディング補正を行うか否かを判定する判定部と、
前記判定部によりシェーディング補正を行うと判定したエリアにシェーディング補正を行い、シェーディング補正を行わないと判定したエリアにシェーディング補正を行わないシェーディング補正部と
を備えることを特徴とするデジタルカメラ。
An imaging unit that images a subject and generates image data;
An evaluation value calculation unit that divides an imaging screen into a plurality of areas and calculates an evaluation value for each area based on data of the image generated by the imaging unit;
A determination unit for determining whether to perform shading correction for each area based on the evaluation value calculated by the evaluation value calculation unit;
A digital camera comprising: a shading correction unit that performs shading correction on an area that is determined to be subjected to shading correction by the determination unit, and that does not perform shading correction on an area that is determined not to perform shading correction.
請求項1に記載のデジタルカメラにおいて、
前記エリアごとにそれぞれ対応するシェーディング補正値を予め格納するメモリをさらに備え、
前記判定部は、前記評価値算出部により算出した前記評価値と前記メモリに格納された前記シェーディング補正値とを比較することにより、前記エリアごとにシェーディング補正を行うか否かを判定する
ことを特徴とするデジタルカメラ。
The digital camera according to claim 1, wherein
A memory for storing in advance a shading correction value corresponding to each area;
The determination unit determines whether to perform shading correction for each area by comparing the evaluation value calculated by the evaluation value calculation unit and the shading correction value stored in the memory. A featured digital camera.
請求項1に記載のデジタルカメラにおいて、
前記判定部は、前記評価値算出部により算出した前記評価値と閾値とを比較することにより、前記エリアごとにシェーディング補正を行うか否かを判定する
ことを特徴とするデジタルカメラ。
The digital camera according to claim 1, wherein
The determination unit determines whether to perform shading correction for each area by comparing the evaluation value calculated by the evaluation value calculation unit with a threshold value.
請求項1に記載のデジタルカメラにおいて、
前記撮像部により生成した前記画像のデータに基づいて、前記エリアごとにエッジを検出するエッジ検出部をさらに備え、
前記判定部は、前記エッジ検出部により前記エッジを検出したエリアにシェーディング補正を行い、前記エッジを検出しないエリアにシェーディング補正を行わないと判定する
ことを特徴とするデジタルカメラ。
The digital camera according to claim 1, wherein
Based on the data of the image generated by the imaging unit, further comprising an edge detection unit for detecting an edge for each area,
The digital camera according to claim 1, wherein the determination unit performs shading correction on an area where the edge is detected by the edge detection unit, and determines not to perform shading correction on an area where the edge is not detected.
請求項1に記載のデジタルカメラにおいて、
前記撮像部により生成した前記画像のデータに基づいて、前記エリアごとにエッジ量を算出するエッジ量算出部をさらに備え、
前記判定部は、前記画像の中心に位置するエリアの前記評価値と前記画像の周辺に位置するエリアの前記評価値との比率が、前記画像の周辺に位置するエリアに対応する前記シェーディング補正値の逆数に近似し、かつ、前記画像の周辺に位置するエリアの前記エッジ量が閾値以下である場合に、シェーディング補正を行うと判定する
ことを特徴とするデジタルカメラ。
The digital camera according to claim 1, wherein
An edge amount calculation unit that calculates an edge amount for each area based on the image data generated by the imaging unit;
The determination unit is configured such that a ratio between the evaluation value of the area located at the center of the image and the evaluation value of the area located around the image corresponds to the shading correction value corresponding to the area located around the image. The digital camera is characterized in that shading correction is determined to be performed when the edge amount of an area that is close to the reciprocal of the image and is located around the image is equal to or smaller than a threshold value.
請求項1から請求項3のいずれか一項に記載のデジタルカメラにおいて、
前記被写体の輝度を測光する測光部と、
前記測光部により測光した前記輝度に応じたゲイン値を算出するゲイン値算出部とをさらに備え、
前記シェーディング補正部は、前記ゲイン値算出部により算出した前記ゲイン値に基づいて、シェーディング補正を行う
ことを特徴とするデジタルカメラ。
The digital camera according to any one of claims 1 to 3,
A metering unit for metering the luminance of the subject;
A gain value calculation unit that calculates a gain value corresponding to the luminance measured by the photometry unit;
The digital camera according to claim 1, wherein the shading correction unit performs shading correction based on the gain value calculated by the gain value calculation unit.
請求項1から請求項3のいずれか一項に記載のデジタルカメラにおいて、
前記撮像部により生成した前記画像に含まれる全エリアの前記評価値の平均値を算出する平均値算出部と、
前記平均値算出部により算出した前記平均値に応じたゲイン値を算出するゲイン値算出部とをさらに備え、
前記シェーディング補正部は、前記ゲイン値算出部により算出した前記ゲイン値に基づいて、シェーディング補正を行う
ことを特徴とするデジタルカメラ。
The digital camera according to any one of claims 1 to 3,
An average value calculating unit that calculates an average value of the evaluation values of all areas included in the image generated by the imaging unit;
A gain value calculation unit that calculates a gain value according to the average value calculated by the average value calculation unit;
The digital camera according to claim 1, wherein the shading correction unit performs shading correction based on the gain value calculated by the gain value calculation unit.
JP2008182357A 2008-07-14 2008-07-14 Digital camera Withdrawn JP2010021915A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008182357A JP2010021915A (en) 2008-07-14 2008-07-14 Digital camera

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008182357A JP2010021915A (en) 2008-07-14 2008-07-14 Digital camera

Publications (1)

Publication Number Publication Date
JP2010021915A true JP2010021915A (en) 2010-01-28

Family

ID=41706353

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008182357A Withdrawn JP2010021915A (en) 2008-07-14 2008-07-14 Digital camera

Country Status (1)

Country Link
JP (1) JP2010021915A (en)

Similar Documents

Publication Publication Date Title
KR101900097B1 (en) Image capturing method and image capturing apparatus
US8982232B2 (en) Image processing apparatus and image processing method
JP6720881B2 (en) Image processing apparatus and image processing method
JP5939705B2 (en) Subject determination device, subject determination method, and program
JP4948591B2 (en) Image processing apparatus, image processing method, and program
JP4595569B2 (en) Imaging device
US20230196530A1 (en) Image processing apparatus, image processing method, and image capture apparatus
JP6904788B2 (en) Image processing equipment, image processing methods, and programs
JP5225137B2 (en) Imaging apparatus, image processing method, and program
JP2007188126A (en) Image brightness calculation device, method, and program
JP5589660B2 (en) Image processing apparatus, imaging apparatus, and image processing program
JP5132470B2 (en) Image processing device
JP2014179920A (en) Imaging apparatus, control method thereof, program, and storage medium
JP2006287814A (en) Imaging apparatus and method of determining motion vector
JP2010183460A (en) Image capturing apparatus and method of controlling the same
JP5743456B2 (en) Image processing apparatus, image processing method, and imaging apparatus
JP6492452B2 (en) Control system, imaging apparatus, control method, and program
JP5693647B2 (en) Image processing method, image processing apparatus, and imaging apparatus
JP2010021915A (en) Digital camera
JP2008252227A (en) Image processor, imaging apparatus, and image processing program
JP2007267170A (en) Electronic camera with chroma saturation regulating function and image processing program
US20230199319A1 (en) Image capturing apparatus and control method thereof and storage medium
JP5351663B2 (en) Imaging apparatus and control method thereof
JP5943682B2 (en) Imaging apparatus, control method thereof, and program
JP6601062B2 (en) Imaging control apparatus, imaging control method, and program

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20111004