JP2006094000A - Image processing method, image processing apparatus, and image processing program - Google Patents
Image processing method, image processing apparatus, and image processing program Download PDFInfo
- Publication number
- JP2006094000A JP2006094000A JP2004275576A JP2004275576A JP2006094000A JP 2006094000 A JP2006094000 A JP 2006094000A JP 2004275576 A JP2004275576 A JP 2004275576A JP 2004275576 A JP2004275576 A JP 2004275576A JP 2006094000 A JP2006094000 A JP 2006094000A
- Authority
- JP
- Japan
- Prior art keywords
- gradation correction
- image data
- index
- unit
- 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.)
- Pending
Links
- 238000012545 processing Methods 0.000 title claims abstract description 188
- 238000003672 processing method Methods 0.000 title claims description 16
- 238000012937 correction Methods 0.000 claims abstract description 443
- 238000011156 evaluation Methods 0.000 claims abstract description 15
- 238000000034 method Methods 0.000 claims description 153
- 238000004364 calculation method Methods 0.000 claims description 116
- 230000008569 process Effects 0.000 claims description 65
- 230000009467 reduction Effects 0.000 claims description 9
- 230000006870 function Effects 0.000 description 53
- 230000014509 gene expression Effects 0.000 description 20
- 238000004891 communication Methods 0.000 description 15
- 238000006243 chemical reaction Methods 0.000 description 12
- 238000004458 analytical method Methods 0.000 description 11
- 230000001186 cumulative effect Effects 0.000 description 11
- 230000008859 change Effects 0.000 description 10
- 238000012546 transfer Methods 0.000 description 10
- 230000003287 optical effect Effects 0.000 description 9
- 238000009826 distribution Methods 0.000 description 8
- 239000000463 material Substances 0.000 description 8
- 238000010586 diagram Methods 0.000 description 7
- 238000012986 modification Methods 0.000 description 7
- 230000004048 modification Effects 0.000 description 7
- 238000003860 storage Methods 0.000 description 7
- 238000010606 normalization Methods 0.000 description 6
- 230000006835 compression Effects 0.000 description 4
- 238000007906 compression Methods 0.000 description 4
- 238000013500 data storage Methods 0.000 description 4
- 230000009466 transformation Effects 0.000 description 4
- 230000015572 biosynthetic process Effects 0.000 description 3
- 238000011068 loading method Methods 0.000 description 3
- 238000013519 translation Methods 0.000 description 3
- 239000000428 dust Substances 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 238000003384 imaging method Methods 0.000 description 2
- GGCZERPQGJTIQP-UHFFFAOYSA-N sodium;9,10-dioxoanthracene-2-sulfonic acid Chemical compound [Na+].C1=CC=C2C(=O)C3=CC(S(=O)(=O)O)=CC=C3C(=O)C2=C1 GGCZERPQGJTIQP-UHFFFAOYSA-N 0.000 description 2
- 238000003786 synthesis reaction Methods 0.000 description 2
- 241000723369 Cocculus trilobus Species 0.000 description 1
- 230000002411 adverse Effects 0.000 description 1
- 238000012512 characterization method Methods 0.000 description 1
- 230000000295 complement effect Effects 0.000 description 1
- 239000002131 composite material Substances 0.000 description 1
- 238000013523 data management Methods 0.000 description 1
- 230000007423 decrease Effects 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000012217 deletion Methods 0.000 description 1
- 230000037430 deletion Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000007599 discharging Methods 0.000 description 1
- 238000001035 drying Methods 0.000 description 1
- 229910044991 metal oxide Inorganic materials 0.000 description 1
- 150000004706 metal oxides Chemical class 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 235000012736 patent blue V Nutrition 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 238000003825 pressing Methods 0.000 description 1
- 238000010187 selection method Methods 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 238000005549 size reduction Methods 0.000 description 1
- 238000005092 sublimation method Methods 0.000 description 1
- 230000001629 suppression Effects 0.000 description 1
- 238000000844 transformation Methods 0.000 description 1
Images
Landscapes
- Color Image Communication Systems (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
- Facsimile Image Signal Circuits (AREA)
Abstract
Description
本発明は、画像処理を行う画像処理方法、画像処理装置及び画像処理プログラムに関する。 The present invention relates to an image processing method, an image processing apparatus, and an image processing program for performing image processing.
近年、デジタルスチルカメラ(携帯電話やラップトップパソコン等の機器に組み込まれたものも含み、以下DSC(Digital Still Camera)と略称する。)が広く普及し、従来のカラー写真フィルムのシステムと同様に、ハードコピー画像として出力したり、CRT(Cathode Ray Tube)等の媒体に表示したり、CD−R(CD-recordable)等の記録媒体に記録するシステムが広く知られている。 In recent years, digital still cameras (including those incorporated in devices such as mobile phones and laptop computers, hereinafter abbreviated as DSC (Digital Still Camera)) have become widespread and, like conventional color photographic film systems, A system for outputting as a hard copy image, displaying on a medium such as a CRT (Cathode Ray Tube), or recording on a recording medium such as a CD-R (CD-recordable) is widely known.
一般的にDSCで撮影された画像は、撮影時の露出調整の不備等により、そのままでは鑑賞する画像として最適な画像を得ることは出来ない場合が多い。このような問題点を解決するために、種々の提案がなされている。例えば、撮影画像データを解析する事により画像のシーンを判別し、その画像のシーンによって最適な画像処理を自動的に施す方法が提案されている(例えば、特許文献1参照)。また、弓形の階調補正曲線を用いて、画像データを階調補正する構成が考えられている(例えば、特許文献2、3参照)。
さらに、上記撮影画像データの画像のシーンを判別する構成において、その判別されたシーンに応じて撮影画像データに適切な階調補正をする構成も考えられる。画像のシーンが適切に判定できた場合、例えばアンダーシーンであれば、画像の主要部(例えば顔)が適切な明るさになるように、画像を明るくする様に階調補正を行う。また近接ストロボ撮影等によるハイコントラストシーンでは、逆に画像を暗くする様に階調補正を行うことが一般的である。この時の階調補正方法としては、一般的に、画像を明るくするような階調補正で有れば、上に凸になるような階調補正カーブを適用し、画像を暗くする場合であれば、下に凸の階調補正カーブを適用する。 Further, in the configuration for discriminating the scene of the image of the captured image data, a configuration in which appropriate gradation correction is performed on the captured image data according to the determined scene is also conceivable. If the scene of the image can be determined appropriately, for example, if it is an underscene, gradation correction is performed so that the image is brightened so that the main part (for example, the face) of the image has appropriate brightness. On the other hand, in a high-contrast scene such as close-up flash photography, it is common to perform tone correction so as to darken the image. As a gradation correction method at this time, generally, if the gradation correction is to brighten the image, a gradation correction curve that is convex upward is applied to darken the image. For example, a downward convex tone correction curve is applied.
しかしながら、上記のシーン判別結果に応じて撮影画像データに適切な階調補正をする構成では、本発明者が検討した結果、アンダーシーンにおいて、画像を最適な明るさになるように明るくする様な階調補正を行うことによって、画像の種類、撮影したDSCの性能、撮像素子としてのCCD(Charge-Coupled Devices)やCMOS(Complementary Metal-Oxide Semiconductor)の性能によっては、画像のシャドー部のノイズが目立ってしまい、むしろ好ましい画像とならない場合があることが判明した。 However, in the configuration in which appropriate gradation correction is performed on the captured image data in accordance with the above-described scene determination result, as a result of studies by the present inventors, an image is brightened so as to have optimum brightness in an underscene. Depending on the type of image, the performance of the captured DSC, and the performance of CCD (Charge-Coupled Devices) or CMOS (Complementary Metal-Oxide Semiconductor) as the image sensor, the noise in the shadow part of the image may be affected by performing tone correction. It has been found that the image may be noticeable and may not be a preferable image.
本発明の課題は、画像データに対して、ノイズが目立つことのない適切な階調補正を行うことである。 An object of the present invention is to perform appropriate gradation correction on image data so that noise is not noticeable.
上記課題を解決するため、請求項1に記載の発明は、
複数画素の信号からなる画像データから画像の撮影シーンを判別するシーン判別工程と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価する工程と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整工程と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正工程と、
を含むことを特徴とする画像処理方法である。
In order to solve the above-mentioned problem, the invention described in
A scene discriminating step for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
Evaluating the amount of noise increase when the gradation correction condition is applied to the image data;
A gradation correction condition adjusting step of adjusting the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction step of applying a gradation correction process to the image data using the adjusted gradation correction condition;
The image processing method characterized by including.
請求項2に記載の発明は、請求項1に記載の画像処理方法において、
前記シーン判別工程は、
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出工程と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出工程と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出工程と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出工程と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別する工程と、を含むことを特徴とする。
The invention according to
The scene discrimination step includes
A first occupancy ratio calculating step of dividing the image data into areas each including a combination of predetermined brightness and hue, and calculating a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy calculation process;
A second index calculating step of calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating step of calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
And determining a shooting scene of the image data based on the calculated first, second, third, and fourth indices.
請求項3に記載の発明は、請求項1又は2に記載の画像処理方法において、
前記階調補正条件決定工程は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整工程は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正工程は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする。
The invention according to
The gradation correction condition determination step determines a gradation correction method and a gradation correction amount as gradation correction conditions,
The gradation correction condition adjustment step adjusts the determined gradation correction amount based on the noise increase amount,
In the gradation correction step, gradation correction processing is performed on the image data using the determined gradation correction method and the adjusted gradation correction amount.
請求項4に記載の発明は、
複数画素の信号からなる第1の画像データから、画像サイズを縮小した第2の画像データを取得する工程と、
前記第2の画像データから画像の撮影シーンを判別するシーン判別工程と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価する工程と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整工程と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正工程と、
を含むことを特徴とする画像処理方法である。
The invention according to
Obtaining second image data with a reduced image size from first image data composed of signals of a plurality of pixels;
A scene discriminating step for discriminating a photographing scene of the image from the second image data;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
Evaluating a noise increase amount when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment step of adjusting the gradation correction condition based on the noise increase amount;
A gradation correction step of applying a gradation correction process to the first image data using the adjusted gradation correction condition;
The image processing method characterized by including.
請求項5に記載の発明は、請求項4に記載の画像処理方法において、
前記シーン判別工程は、
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出工程と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出工程と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出工程と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出工程と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別する工程と、を含むことを特徴とする。
The invention according to
The scene discrimination step includes
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. Rate calculation process;
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy calculation process;
A second index calculating step of calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating step of calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
And determining a shooting scene of the second image data based on the calculated first, second, third and fourth indices.
請求項6に記載の発明は、請求項4又は5に記載の画像処理方法において、
前記階調補正条件決定工程は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整工程は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正工程は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする。
The invention according to claim 6 is the image processing method according to
The gradation correction condition determination step determines a gradation correction method and a gradation correction amount as gradation correction conditions,
The gradation correction condition adjustment step adjusts the gradation correction amount based on the noise increase amount,
In the gradation correction step, gradation correction processing is performed on the first image data by using the determined gradation correction method and the adjusted gradation correction amount.
請求項7に記載の発明は、
複数画素の信号からなる画像データから画像の撮影シーンを判別するシーン判別部と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定部と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価するノイズ評価部と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整部と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正部と、
を備えることを特徴とする画像処理装置である。
The invention described in
A scene discriminating unit for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determination unit that determines gradation correction conditions based on the result of the scene determination;
A noise evaluation unit that evaluates a noise increase amount when the gradation correction condition is applied to the image data;
A gradation correction condition adjusting unit that adjusts the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction unit that performs a gradation correction process on the image data using the adjusted gradation correction condition;
An image processing apparatus comprising:
請求項8に記載の発明は、請求項7に記載の画像処理装置において、
前記シーン判別部は、
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出部と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出部と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出部と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出部と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出部と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別するシーン判別実行部と、を備えることを特徴とする。
The invention according to
The scene discrimination unit
A first occupancy ratio calculation unit that divides the image data into areas each including a combination of predetermined brightness and hue, and calculates a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculation unit for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy rate calculator,
A second index calculating unit that calculates a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating unit that calculates a fourth index by multiplying an average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
A scene discrimination execution unit that discriminates a shooting scene of the image data based on the calculated first, second, third, and fourth indices.
請求項9に記載の発明は、請求項7又は8に記載の画像処理装置において、
前記階調補正条件決定部は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整部は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正部は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする。
The invention according to
The gradation correction condition determining unit determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment unit adjusts the determined gradation correction amount based on the noise increase amount,
The gradation correction unit performs a gradation correction process on the image data using the determined gradation correction method and the adjusted gradation correction amount.
請求項10に記載の発明は、
複数画素の信号からなる第1の画像データから、画像サイズを縮小した第2の画像データを取得する画像縮小部と、
前記第2の画像データから画像の撮影シーンを判別するシーン判別部と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定部と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価するノイズ評価部と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整部と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正部と、
を備えることを特徴とする画像処理装置である。
The invention according to
An image reduction unit for obtaining second image data obtained by reducing the image size from the first image data including signals of a plurality of pixels;
A scene discriminating unit for discriminating a photographing scene of the image from the second image data;
A gradation correction condition determination unit that determines gradation correction conditions based on the result of the scene determination;
A noise evaluation unit that evaluates a noise increase amount when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment unit that adjusts the gradation correction condition based on the noise increase amount;
A gradation correction unit that performs a gradation correction process on the first image data using the adjusted gradation correction condition;
An image processing apparatus comprising:
請求項11に記載の発明は、請求項10に記載の画像処理装置において、
前記シーン判別部は、
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出部と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出部と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出部と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出部と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別するシーン判別実行部と、を備えることを特徴とする。
The invention according to
The scene discrimination unit
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. A rate calculator,
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy rate calculator,
A second index calculating unit that calculates a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating unit that calculates a fourth index by multiplying an average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
A scene discrimination execution unit that discriminates a shooting scene of the second image data based on the calculated first, second, third, and fourth indices.
請求項12に記載の発明は、請求項10又は11に記載の画像処理装置において、
前記階調補正条件決定部は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整部は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正部は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする。
The invention described in
The gradation correction condition determining unit determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment unit adjusts the gradation correction amount based on the noise increase amount,
The gradation correction unit performs gradation correction processing on the first image data using the determined gradation correction method and the adjusted gradation correction amount.
請求項13に記載の発明は、
コンピュータに、
複数画素の信号からなる画像データから画像の撮影シーンを判別するシーン判別機能と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価する機能と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整機能と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正機能と、
を実現させるための画像処理プログラムである。
The invention according to claim 13
On the computer,
A scene discrimination function for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
A function of evaluating the amount of noise increase when the gradation correction condition is applied to the image data;
A gradation correction condition adjustment function for adjusting the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction function for performing a gradation correction process on the image data using the adjusted gradation correction condition;
Is an image processing program for realizing the above.
請求項14に記載の発明は、請求項13に記載の画像処理プログラムにおいて、
前記シーン判別機能は、
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出機能と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出機能と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出機能と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出機能と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出機能と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別する機能と、を有することを特徴とする。
The invention described in
The scene discrimination function is
A first occupancy ratio calculation function that divides the image data into areas each including a combination of predetermined brightness and hue, and calculates a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculation function for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 Occupancy rate calculation function,
A second index calculation function for calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculation function for calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
And a function of discriminating a photographing scene of the image data based on the calculated first, second, third and fourth indices.
請求項15に記載の発明は、請求項13又は14に記載の画像処理プログラムにおいて、
前記階調補正条件決定機能は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整機能は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正機能は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする。
The invention according to
The gradation correction condition determination function determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment function adjusts the determined gradation correction amount based on the noise increase amount,
The gradation correction function performs gradation correction processing on the image data using the determined gradation correction method and the adjusted gradation correction amount.
請求項16に記載の発明は、
コンピュータに、
複数画素の信号からなる第1の画像データから、画像サイズを縮小した第2の画像データを取得する機能と、
前記第2の画像データから画像の撮影シーンを判別するシーン判別機能と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定機能と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価する機能と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整機能と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正機能と、
を実現させるための画像処理プログラムである。
The invention described in claim 16
On the computer,
A function of acquiring second image data obtained by reducing the image size from the first image data including signals of a plurality of pixels;
A scene discrimination function for discriminating a shooting scene of an image from the second image data;
A gradation correction condition determination function for determining a gradation correction condition based on the result of the scene determination;
A function of evaluating an amount of increase in noise when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment function for adjusting the gradation correction condition based on the noise increase amount;
A gradation correction function for applying a gradation correction process to the first image data using the adjusted gradation correction condition;
Is an image processing program for realizing the above.
請求項17に記載の発明は、請求項16に記載の画像処理プログラムにおいて、
前記シーン判別機能は、
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出機能と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出機能と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出機能と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出機能と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出機能と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別する機能と、を有することを特徴とする。
The invention according to claim 17 is the image processing program according to claim 16,
The scene discrimination function is
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. Rate calculation function,
A first index calculation function for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 Occupancy rate calculation function,
A second index calculation function for calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculation function for calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
And a function of discriminating a shooting scene of the second image data based on the calculated first, second, third and fourth indices.
請求項18に記載の発明は、請求項16又は17に記載の画像処理プログラムにおいて、
前記階調補正条件決定機能は、階調補正条件として階調補正方法及びその階調補正量を決定し、
前記階調補正条件調整機能は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正機能は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする。
The invention according to claim 18 is the image processing program according to claim 16 or 17,
The gradation correction condition determination function determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment function adjusts the gradation correction amount based on the noise increase amount,
The gradation correction function performs gradation correction processing on the first image data using the determined gradation correction method and the adjusted gradation correction amount.
請求項1、7又は13に記載の発明によれば、画像データのシーン判別の結果により階調補正条件を決定し、その決定した階調補正条件で階調補正した画像データのノイズ増加量に基づいて階調補正条件を調整し、その調整した階調補正条件で画像データを階調補正するので、ノイズが目立ってしまうことなく、適正に画像データを階調補正できる。例えば、アンダーシーン等の画像データについて、シーン判別の結果により自動的に画像を明るくする様に階調補正する場合にも、ノイズ増加量に基づく階調補正条件の調整及びその階調補正により、シャドー部にノイズが目立ってしまうことなく、適正な画像データを得ることができる。 According to the first, seventh, or thirteenth aspect of the invention, the tone correction condition is determined based on the scene discrimination result of the image data, and the noise increase amount of the image data subjected to the tone correction using the determined tone correction condition is determined. Since the gradation correction conditions are adjusted based on the image data and the gradation correction is performed on the image data using the adjusted gradation correction conditions, the gradation correction of the image data can be performed appropriately without making noise conspicuous. For example, for image data such as an underscene, even when tone correction is performed so that the image is automatically brightened based on the result of scene determination, adjustment of tone correction conditions based on the amount of increase in noise and tone correction thereof, Appropriate image data can be obtained without making noise conspicuous in the shadow portion.
請求項2、8又は14に記載の発明によれば、画像データの撮影シーンを定量的に示す第1、第2、第3及び第4の指標を算出し、それらの指標に基づいて画像データの撮影シーンを決定するので、画像データの撮影シーンを正確に特定することができる。
According to the invention of
請求項3、9又は15に記載の発明によれば、画像データのシーン判別の結果により階調補正条件として階調補正方法及びその階調補正量を決定し、その決定した階調補正条件で階調補正した画像データのノイズ増加量に基づいて階調補正量を調整し、その階調補正方法及び階調補正量を用いて、画像データを階調補正するので、ノイズが目立ってしまうことなく、さらに適正に画像データを階調補正できる。
According to the invention of
請求項4、10又は16に記載の発明によれば、縮小した第2の画像データのシーン判別の結果により階調補正条件を決定し、その決定した階調補正条件で階調補正した第1の画像データのノイズ増加量に基づいて階調補正条件を調整し、その調整した階調補正条件で第1の画像データを階調補正するので、ノイズが目立ってしまうことなく、適正に第1の画像データを階調補正できるとともに、第2の画像データを用いることによりシーン判別の計算量及び計算時間を低減できる。
According to the invention of
請求項5、11又は17に記載の発明によれば、第2の画像データの撮影シーンを定量的に示す第1、第2、第3及び第4の指標を算出し、それらの指標に基づいて第2の画像データの撮影シーンを決定するので、第2の画像データの撮影シーンを正確に特定することができる。
According to the invention described in
請求項6、12又は18に記載の発明によれば、第2の画像データのシーン判別の結果により階調補正条件として階調補正方法及びその階調補正量を決定し、その決定した階調補正条件で階調補正した第1の画像データのノイズ増加量に基づいて階調補正量を調整し、その階調補正方法及び階調補正量を用いて、第1の画像データを階調補正するので、ノイズが目立ってしまうことなく、さらに適正に第1の画像データを階調補正できる。
According to the invention described in
以下、添付図を参照して本発明に係る実施の形態及びその変形例を順に詳細に説明する。ただし、発明の範囲は、図示例に限定されない。 DESCRIPTION OF THE PREFERRED EMBODIMENTS Embodiments according to the present invention and modifications thereof will be described in detail below in order with reference to the accompanying drawings. However, the scope of the invention is not limited to the illustrated examples.
図1〜図27を参照して、本発明に係る第1の実施の形態を説明する。 A first embodiment according to the present invention will be described with reference to FIGS.
<画像処理装置1の外観構成>
まず、図1を参照して本実施の形態の画像処理装置1の外観構成を説明する。図1に、本実施の形態における画像処理装置1の外観構成を示す。
<Appearance Configuration of
First, the external configuration of the
画像処理装置1は、図1に示すように、筐体2の一側面に、感光材料を装填するためのマガジン装填部3が備えられている。筐体2の内側には、感光材料に露光する露光処理部4と、露光された感光材料を現像処理して乾燥し、プリントを作成するためのプリント作成部5と、が備えられている。筐体2の他側面には、プリント作成部5で作成されたプリントを排出するためのトレー6が備えられている。
As shown in FIG. 1, the
また、筐体2の上部には、表示装置としてのCRT8、透過原稿を読み込む装置であるフィルムスキャナ部9、反射原稿入力装置10、操作部11が備えられている。このCRT8が、プリントを作成しようとする画像情報の画像を画面に表示する表示手段を構成している。更に、筐体2には、各種デジタル記録媒体に記録された画像情報を読み取り可能な画像読込部14、各種デジタル記録媒体に画像信号を書き込み(出力)可能な画像書込部15が備えられている。また、筐体2の内部には、これらの各部を集中制御する制御部7が備えられている。
Further, a
画像読込部14には、PCカード用アダプタ14a、フロッピー(登録商標)ディスク用アダプタ14bが備えられ、PCカード13aやフロッピー(登録商標)ディスク13bが差し込み可能になっている。PCカード13aは、例えば、デジタルカメラで撮像された複数の駒画像データが記録されたメモリを有する。フロッピー(登録商標)ディスク13bには、例えば、デジタルカメラで撮像された複数の駒画像データが記録される。PCカード13a及びフロッピー(登録商標)ディスク13b以外に駒画像データが記録される記録媒体としては、例えば、マルチメディアカード(登録商標)、メモリースティック(登録商標)、MD(Mini Disc)データ、CD−ROM等がある。
The
画像書込部15には、フロッピー(登録商標)ディスク用アダプタ15a、MO(Magneto Optical Disc)用アダプタ15b、光ディスク用アダプタ15cが備えられ、それぞれ、FD16a、MO16b、光ディスク16cが差し込み可能になっている。光ディスク16cとしては、CD−R、DVD(Digital Versatile Disc)−R等がある。
The
なお、図1では、操作部11、CRT8、フィルムスキャナ部9、反射原稿入力装置10、画像読込部14が、筐体2に一体的に備えられた構造となっているが、これらの何れか1つ以上を別体として設けるようにしてもよい。
In FIG. 1, the
また、図1に示した画像処理装置1では、感光材料に露光して現像してプリントを作成するものが例示されているが、プリント作成方式はこれに限定されず、例えば、インクジェット方式、電子写真方式、感熱方式、昇華方式等の方式を用いてもよい。
Further, in the
<画像処理装置1の主要部構成>
図2に、画像処理装置1の主要部構成を示す。画像処理装置1は、図2に示すように、制御部7、露光処理部4、プリント作成部5、フィルムスキャナ部9、反射原稿入力装置10、画像読込部14、通信手段(入力)32、画像書込部15、データ蓄積手段71、テンプレート記憶手段72、操作部11、CRT8、通信手段(出力)33により構成される。
<Configuration of Main Parts of
FIG. 2 shows a main part configuration of the
制御部7は、マイクロコンピュータにより構成され、ROM(Read Only Memory)等の記憶部(図示略)、RAM(Random Access Memory)(図示略)、CPU(Central Processing Unit)(図示略)により構成され、記憶部に記憶されている各種制御プログラムがRAMに展開され、その展開された各種制御プログラムと、CPUとの協働により、画像処理装置1を構成する各部の動作を制御する。
The
制御部7は、画像処理部70を有し、操作部11からの入力信号(指令情報)に基づいて、フィルムスキャナ部9や反射原稿入力装置10から読み取られた画像信号、画像読込部14から読み込まれた画像信号、外部機器から通信手段32を介して入力された画像信号に対して、画像処理を施して露光用画像情報を形成し、露光処理部4に出力する。また、画像処理部70は、画像処理された画像信号に対して出力形態に応じた変換処理を施して出力する。画像処理部70の出力先としては、CRT8、画像書込部15、通信手段(出力)33等がある。
The
露光処理部4は、感光材料に画像の露光を行い、この感光材料をプリント作成部5に出力する。プリント作成部5は、露光された感光材料を現像処理して乾燥し、プリントP1、P2、P3を作成する。プリントP1は、サービスサイズ、ハイビジョンサイズ、パノラマサイズ等のプリントであり、プリントP2は、A4サイズのプリントであり、プリントP3は、名刺サイズのプリントである。
The
フィルムスキャナ部9は、アナログカメラにより撮像された現像済みのネガフィルムN、リバーサルフィルム等の透過原稿に記録された駒画像を読み取り、駒画像のデジタル画像信号を取得する。反射原稿入力装置10は、フラットベットスキャナにより、プリントP(写真プリント、書画、各種の印刷物)上の画像を読み取り、デジタル画像信号を取得する。
The
画像読込部14は、PCカード13aやフロッピー(登録商標)ディスク13bに記録された駒画像情報を読み出して制御部7に転送する。この画像読込部14は、画像転送手段30として、PCカード用アダプタ14a、フロッピー(登録商標)ディスク用アダプタ14b等を有する。画像読込部14は、PCカード用アダプタ14aに差し込まれたPCカード13aや、フロッピー(登録商標)ディスク用アダプタ14bに差し込まれたフロッピー(登録商標)ディスク13bに記録された駒画像情報を読み取り、制御部7に転送する。PCカード用アダプタ14aとしては、例えばPCカードリーダやPCカードスロット等が用いられる。
The
通信手段(入力)32は、画像処理装置1が設置された施設内の別のコンピュータや、インターネット等を介した遠方のコンピュータから、撮像画像を表す画像信号やプリント命令信号を受信する。
The communication means (input) 32 receives an image signal representing a captured image and a print command signal from another computer in the facility where the
画像書込部15は、画像搬送部31として、フロッピー(登録商標)ディスク用アダプタ15a、MO用アダプタ15b、光ディスク用アダプタ15cを備えている。画像書込部15は、制御部7から入力される書込信号に従って、フロッピー(登録商標)ディスク用アダプタ15aに差し込まれたフロッピー(登録商標)ディスク16a、MO用アダプタ15bに差し込まれたMO16b、光ディスク用アダプタ15cに差し込まれた光ディスク16cに、本発明における画像処理方法によって生成された画像信号を書き込む。
The
データ蓄積手段71は、画像情報とそれに対応する注文情報(どの駒の画像から何枚プリントを作成するかの情報、プリントサイズの情報等)とを記憶し、順次蓄積する。
The
テンプレート記憶手段72は、サンプル識別情報D1、D2、D3に対応するサンプル画像データである背景画像、イラスト画像等と合成領域を設定する少なくとも1個のテンプレートのデータを記憶している。オペレータの操作によりセットしてテンプレート記憶手段72に予め記憶された複数のテンプレートから所定のテンプレートを選択し、駒画像情報は選択されたテンプレートにより合成し、指定されるサンプル識別情報D1、D2、D3に基づいて選択されたサンプル画像データと、注文に基づく画像データ及び/又は文字データとを合成し、指定によるサンプルに基づくプリントを作成する。このテンプレートによる合成は、周知のクロマキー法によって行なわれる。 The template storage means 72 stores at least one template data for setting a synthesis area and a background image, an illustration image, and the like, which are sample image data corresponding to the sample identification information D1, D2, and D3. A predetermined template is selected from a plurality of templates that are set by the operation of the operator and stored in advance in the template storage means 72, and the frame image information is synthesized by the selected template and designated sample identification information D1, D2, D3 The sample image data selected on the basis of the image data and the image data and / or character data based on the order are combined to create a print based on the specified sample. The synthesis using this template is performed by a well-known chroma key method.
なお、プリントのサンプルを指定するサンプル識別情報D1、D2、D3は、操作部211から入力されるように構成されているが、これらのサンプル識別情報は、プリントのサンプル又は注文シートに記録されているため、OCR等の読み取り手段により読み取ることができる。或いは、オペレータのキーボード操作により入力することもできる。 Note that sample identification information D1, D2, and D3 for specifying a print sample is configured to be input from the operation unit 211. These sample identification information is recorded on a print sample or an order sheet. Therefore, it can be read by reading means such as OCR. Or it can also input by an operator's keyboard operation.
このようにプリントのサンプルを指定するサンプル識別情報D1に対応してサンプル画像データを記録しておき、プリントのサンプルを指定するサンプル識別情報D1を入力し、この入力されるサンプル識別情報D1に基づきサンプル画像データを選択し、この選択されたサンプル画像データと、注文に基づく画像データ及び/又は文字データとを合成し、指定によるサンプルに基づくプリントを作成するため、種々の実物大のサンプルをユーザが実際に手にしてプリントの注文ができ、幅広いユーザの多様な要求に応じることができる。 In this way, sample image data is recorded corresponding to the sample identification information D1 for designating the print sample, the sample identification information D1 for designating the print sample is input, and based on the input sample identification information D1. Select the sample image data, synthesize the selected sample image data with the image data and / or text data based on the order, and create a print based on the specified sample. Can actually place a print order and meet the diverse requirements of a wide range of users.
また、第1のサンプルを指定する第1のサンプル識別情報D2と第1のサンプルの画像データを記憶し、また、第2のサンプルを指定する第2のサンプル識別情報D3と第2のサンプルの画像データを記憶し、指定される第1及び第2のサンプル識別情報D2、D3とに基づいて選択されたサンプル画像データと、注文に基づく画像データ及び/又は文字データとを合成し、指定によるサンプルに基づくプリントを作成するため、さらに多種多様の画像を合成することができ、より一層幅広いユーザの多様な要求に応じたプリントを作成することができる。 Also, the first sample identification information D2 designating the first sample and the image data of the first sample are stored, and the second sample identification information D3 designating the second sample and the second sample The image data is stored, the sample image data selected based on the designated first and second sample identification information D2 and D3, and the image data and / or character data based on the order are synthesized, and according to the designation In order to create a print based on a sample, it is possible to synthesize a wider variety of images, and it is possible to create a print that meets a wider variety of user requirements.
操作部11は、情報入力手段12を有する。情報入力手段12は、例えば、タッチパネル等により構成されており、情報入力手段12の押下信号を入力信号として制御部7に出力する。なお、操作部11は、キーボードやマウス等を備えて構成するようにしてもよい。CRT8は、制御部7から入力された表示制御信号に従って、画像情報等を表示する。
The
通信手段(出力)33は、本発明の画像処理を施した後の撮影画像を表す画像信号と、それに付帯するオーダー情報を、画像処理装置1が設置された施設内の他のコンピュータや、インターネット等を介した遠方のコンピュータに対して送信する。
The communication means (output) 33 sends an image signal representing a photographed image after image processing of the present invention and order information attached thereto to other computers in the facility where the
図2に示すように、画像処理装置1は、各種デジタルメディアの画像及び画像原稿を分割測光して得られた画像情報を取り込む画像入力手段と、画像処理手段と、処理済の画像を表示、プリント出力、画像記録メディアに書き込む画像出力手段と、通信回線を介して施設内の別のコンピュータやインターネット等を介した遠方のコンピュータに対して画像データと付帯するオーダー情報を送信する手段と、を備える。
As shown in FIG. 2, the
<画像処理部70の内部構成>
図3に、画像処理部70の内部構成を示す。画像処理部70は、図3に示すように、画像調整処理部701、フィルムスキャンデータ処理部702、反射原稿スキャンデータ処理部703、画像データ書式解読処理部704、テンプレート処理部705、CRT固有処理部706、プリンタ固有処理部707、プリンタ固有処理部708、画像データ書式作成処理部709により構成される。
<Internal Configuration of
FIG. 3 shows an internal configuration of the
フィルムスキャンデータ処理部702は、フィルムスキャナ部9から入力された画像データに対し、フィルムスキャナ部9固有の校正操作、ネガポジ反転(ネガ原稿の場合)、ゴミキズ除去、コントラスト調整、粒状ノイズ除去、鮮鋭化強調等の処理を施し、処理済の画像データを画像調整処理部701に出力する。また、フィルムサイズ、ネガポジ種別、フィルムに光学的或いは磁気的に記録された主要被写体に関わる情報、撮影条件に関する情報(例えば、APSの記載情報内容)等も併せて画像調整処理部701に出力する。
The film scan
反射原稿スキャンデータ処理部703は、反射原稿入力装置10から入力された画像データに対し、反射原稿入力装置10固有の校正操作、ネガポジ反転(ネガ原稿の場合)、ゴミキズ除去、コントラスト調整、ノイズ除去、鮮鋭化強調等の処理を施し、処理済の画像データを画像調整処理部701に出力する。
The reflection original scan
画像データ書式解読処理部704は、画像転送手段30及び/又は通信手段(入力)32から入力された画像データに対し、その画像データのデータ書式に従って、必要に応じて圧縮符号の復元、色データの表現方法の変換等の処理を施し、画像処理部70内の演算に適したデータ形式に変換し、画像調整処理部701に出力する。また、画像データ書式解読処理部704は、操作部11、通信手段(入力)32、画像転送手段30の何れかから出力画像の大きさが指定された場合、その指定された情報を検出し、画像調整処理部701に出力する。なお、画像転送手段30により指定される出力画像の大きさについての情報は、画像転送手段30が取得した画像データのヘッダ情報、タグ情報に埋め込まれている。
The image data format
画像調整処理部701は、操作部11又は制御部7の指令に基づいて、フィルムスキャナ部9、反射原稿入力装置10、画像転送手段30、通信手段(入力)32、テンプレート処理部705から受け取った画像データに対し、後述の第1の画像処理(図6参照)を施して、出力媒体上での鑑賞に最適化された画像形成用のデジタル画像データを生成し、CRT固有処理部706、プリンタ固有処理部707、プリンタ固有処理部708、画像データ書式作成処理部709、データ蓄積手段71に出力する。
The image
最適化処理においては、例えばsRGB規格に準拠したCRTディスプレイモニタに表示することを前提とした場合、sRGB規格の色域内で最適な色再現が得られるように処理される。銀塩印画紙への出力を前提とした場合、銀塩印画紙の色域内で最適な色再現が得られるように処理される。また前記色域の圧縮の以外にも、16bitから8bitへの階調圧縮、出力画素数の低減、及び出力デバイスの出力特性(LUT:LookUp Table)への対応処理等も含まれる。さらにノイズ抑制、鮮鋭化、グレーバランス調整、彩度調整、或いは覆い焼き処理等の階調圧縮処理が行われることは言うまでもない。 In the optimization process, for example, when it is assumed that the image is displayed on a CRT display monitor compliant with the sRGB standard, the optimal color reproduction is performed within the sRGB standard color gamut. If output to silver salt photographic paper is assumed, processing is performed so that optimum color reproduction is obtained within the color gamut of silver salt photographic paper. In addition to the compression of the color gamut, gradation compression from 16 bits to 8 bits, reduction of the number of output pixels, processing corresponding to output characteristics (LUT: LookUp Table) of the output device, and the like are also included. Furthermore, it goes without saying that tone compression processing such as noise suppression, sharpening, gray balance adjustment, saturation adjustment, or dodging processing is performed.
図4に、画像調整処理部701の内部構成を示す。画像調整処理部701は、図4に示すように、シーン判別部710、階調補正条件決定部730、画像処理実行部740、ノイズ評価部750により構成される。また、階調補正条件決定部730は、階調補正方法決定部731、階調補正パラメータ算出部732、階調補正量決定部733により構成される。
FIG. 4 shows an internal configuration of the image
図5(a)に、シーン判別部710の内部構成を示す。シーン判別部710は、図5(a)に示すように、割合算出部712、指標算出部713、シーン判別実行部714により構成される。図5(b)に、割合算出部712の内部構成を示す。割合算出部712は、図5(b)に示すように、表色系変換部715、ヒストグラム作成部716、占有率演算部717により構成される。
FIG. 5A shows an internal configuration of the
表色系変換部715は、撮影画像データのRGB(Red, Green, Blue)値をHSV表色系に変換する。HSV表色系とは、画像データを、色相(Hue)、彩度(Saturation)、明度(Value又はBrightness)の3つの要素で表すものであり、マンセルにより提案された表色体系を元にして考案されたものである。
The color
なお、本実施形態において、「明度」は特に注釈を設けない限り一般に用いられる「明るさ」の意味である。以下の記載において、HSV表色系のV(0〜255)を「明度」として用いるが、他の如何なる表色系の明るさを表す単位系を用いてもよい。その際、本実施形態で記載する各種係数等の数値を、改めて算出し直すことは言うまでもない。また、本実施の形態における撮影画像データは、人物を主要被写体とする画像データであるものとする。 In this embodiment, “brightness” means “brightness” generally used unless otherwise noted. In the following description, V (0 to 255) of the HSV color system is used as “brightness”, but a unit system representing the brightness of any other color system may be used. At that time, it goes without saying that numerical values such as various coefficients described in the present embodiment are recalculated. In addition, it is assumed that the captured image data in the present embodiment is image data having a person as a main subject.
ヒストグラム作成部716は、撮影画像データを、所定の色相と明度の組み合わせからなる領域に分割し、分割された領域毎に累積画素数を算出することによって2次元ヒストグラムを作成する。また、ヒストグラム作成部716は、撮影画像データを、当該撮影画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、分割された領域毎に累積画素数を算出することによって2次元ヒストグラムを作成する。なお、撮影画像データを、撮影画像データの画面の外縁からの距離、明度及び色相の組み合わせからなる領域に分割し、分割された領域毎に累積画素数を算出することによって3次元ヒストグラムを作成するようにしてもよい。以下では、2次元ヒストグラムを作成する方式を説明する。
The
図5(c)に、占有率演算部717の内部構成を示す。占有率演算部717は、図5(c)に示すように、第1占有率算出部718、第2占有率算出部719により構成される。第1占有率算出部718は、明度と色相との組み合わせによって分割された領域毎に、ヒストグラム作成部716において算出された累積画素数の全画素数(撮影画像データ全体)に占める割合を示す第1の占有率(後述の表1参照)を算出する。第2占有率算出部719は、撮影画像データの画面の外縁からの距離と明度との組み合わせによって分割された領域毎に、ヒストグラム作成部716において算出された累積画素数の全画素数(撮影画像データ全体)に占める割合を示す第2の占有率(後述の表2参照)を算出する。
FIG. 5C shows the internal configuration of the occupation
図5(d)に、指標算出部713の内部構成を示す。指標算出部713は、図5(d)に示すように、第1指標算出部720、第2指標算出部721、第3指標算出部722により構成される。
FIG. 5D shows the internal configuration of the
第1指標算出部720は、第1占有率算出部718において領域毎に算出された第1の占有率に、撮影条件に応じて予め(例えば、判別分析によって)設定された第1の係数(後述の表3参照)を乗算して和をとることにより、撮影シーンを特定するための第1の指標a1を算出する。ここで、撮影シーンとは、順光、逆光、ストロボ等の、被写体を撮影する時の光源条件及び、アンダー撮影等の露出条件を示す。第1の指標a1は、屋内撮影度、近接撮影度、顔色高明度等のストロボ撮影時の特徴を示すもので、「ストロボ」と判別されるべき画像を他の撮影シーンから分離するためのものである。
The first
第1の指標a1の算出の際、第1指標算出部720は、所定の高明度の肌色色相領域と、当該高明度の肌色色相領域以外の色相領域とで、異なる符号の係数を用いる。ここで、所定の高明度の肌色色相領域には、HSV表色系の明度値で170〜224の領域が含まれる。また、所定の高明度の肌色色相領域以外の色相領域には、青色色相領域(色相値161〜250)、緑色色相領域(色相値40〜160)の少なくとも一方の高明度領域が含まれる。
When calculating the first index a1, the first
また、第1指標算出部720は、第1占有率算出部718において領域毎に算出された第1の占有率に、撮影条件に応じて予め(例えば、判別分析によって)設定された第2の係数(後述の表4参照)を乗算して和をとることにより、撮影シーンを特定するための第2の指標a2を算出する。第2の指標a2は、屋外撮影度、空色高明度、顔色低明度等の逆光撮影時の特徴を複合的に示すもので、「逆光」と判別されるべき画像を他の撮影シーンから分離するためのものである。
In addition, the first
第2の指標a2の算出の際、第1指標算出部720は、肌色色相領域(色相値0〜39、330〜359)の中間明度領域と、当該中間明度領域以外の明度領域とで、異なる符号の係数を用いる。この肌色色相領域の中間明度領域には、明度値85〜169の領域が含まれる。また、当該中間明度領域以外の明度領域には、例えば、シャドー領域(明度値26〜84)が含まれる。
When calculating the second index a2, the first
第2指標算出部721は、第2占有率算出部719において領域毎に算出された第2の占有率に、撮影条件に応じて予め(例えば、判別分析によって)設定された第3の係数(後述の表5参照)を乗算して和をとることにより、撮影シーンを特定するための第3の指標a3を算出する。第3の指標a3は、逆光とストロボとの間における、撮影画像データの画面の中心と外側との明暗関係の差異を示すものであり、逆光又はストロボと判別されるべき画像のみを定量的に示すものである。第3の指標a3の算出の際、指標算出部713は、撮影画像データの画面の外縁からの距離に応じて異なる値の係数を用いる。
The second
第3指標算出部722は、少なくとも、撮影画像データの画面中央部における肌色の平均輝度値に、撮影条件に応じて予め(例えば、判別分析によって)設定された第4の係数を乗算して和をとることにより、撮影シーンを特定するための第4の指標a4を算出する。より好ましくは、撮影画像データの画面中央部における肌色の平均輝度値だけでなく、画像の最大輝度値と平均輝度値との差分値(後述の式(8)参照)、輝度標準偏差、画面中央部における輝度平均値、画像の肌色最大輝度値及び肌色最小輝度値の差分値と肌色平均輝度値との比較値(後述の式(9)参照)に、予め設定された第4の係数を乗算して和をとることにより、撮影シーンを特定するための第4の指標a4を算出する。ここで、用いる変数によって第4の係数を変えることは言うまでもない。第4の指標a4は、ストロボ撮影シーンとアンダー撮影シーンにおける、撮影画像データの画面の中心と外側の明暗関係の差異を示すだけでなく、輝度ヒストグラムにおける分布情報を示すものであり、ストロボ撮影シーン又はアンダー撮影シーンと判別されるべき画像のみを定量的に示すものである。
The third
第4の指標a4を算出する際、第3指標算出部722では、撮影画像データの画面中央部における肌色の平均輝度値、画像の最大輝度値と平均輝度値との差分値、輝度標準偏差、画面中央部における輝度平均値、画像の肌色最大輝度値及び肌色最小輝度値の差分値と肌色平均輝度値との比較値を用いているが、ここでいう輝度値とは、明るさを表す指標であり、それ以外の明るさを表す指標(例えば、HSV表色系の明度値等)を用いてもよい。また、最大輝度値、肌色最大輝度値、肌色最小輝度値には、最大及び最小輝度値からの累積画素数が全画素に対して所定の割合に達した画素の輝度値を用いてもよい。
When calculating the fourth index a4, the third
第3指標算出部722は、第1の指標a1、第3の指標a3に、それぞれ、撮影条件に応じて予め(例えば、判別分析によって)設定された係数を乗算して和をとることにより第5の指標a5を算出する。より好ましくは、第1の指標a1、第3の指標a3及び第4’の指標a4’(画面中央部における肌色の平均輝度値)に、それぞれ、撮影条件に応じて予め(例えば、判別分析によって)設定された係数を乗算して和をとることにより第5の指標a5を算出してもよい。更に、第3指標算出部722は、第2の指標a2、第3の指標a3に、それぞれ、撮影条件に応じて予め(例えば、判別分析によって)設定された係数を乗算して合成することにより第6の指標a6を算出する。より好ましくは第2の指標a2、第3の指標a3、第4’の指標a4’に、それぞれ、撮影条件に応じて予め設定された係数を乗算して合成することにより第6の指標a6を算出してもよい。
The third
シーン判別実行部714は、指標算出部713において算出された第4の指標a4、第5の指標a5、第6の指標a6の値に基づいて、撮影画像データの撮影シーン(光源条件及び露出条件)を判別する。
Based on the values of the fourth index a4, the fifth index a5, and the sixth index a6 calculated by the
なお、指標算出部713における第1の指標a1〜第6の指標a6の具体的な算出方法、シーン判別実行部714における撮影シーン(光源条件及び露出条件)の判別方法は、後述の本実施の形態の動作説明において詳細に説明する。
Note that a specific calculation method of the first index a1 to the sixth index a6 in the
図4において、階調補正条件決定部730は、階調補正条件として、階調補正方法及びその階調補正量の決定を行う。階調補正方法決定部731は、シーン判別部710により判別された撮影画像データの撮影シーンに基づいて階調補正方法を決定する。例えば、撮影シーンが順光である場合は、後述の図19(a)に示すように、入力された撮影画像データの画素値を平行移動(オフセット)補正する方法(階調補正方法A)が適用される。撮影シーンが逆光である場合は、後述の図19(b)に示すように、入力された撮影画像データの画素値をガンマ補正する方法(階調補正方法B)が適用される。撮影シーンがストロボである場合、後述の図19(c)に示すように、入力された撮影画像データの画素値をガンマ補正及び平行移動(オフセット)補正する方法(階調補正方法C)が適用される。撮影シーンがアンダーである場合、図19(b)に示すように、入力された撮影画像データの画素値をガンマ補正する方法(階調補正方法B)が適用される。
In FIG. 4, a gradation correction
階調補正パラメータ算出部732は、シーン判別部710により算出された第4の指標a4、第5の指標a5、第6の指標a6の値に基づいて、階調補正に必要なパラメータ(キー補正値等)を算出する。
The gradation correction
階調補正量決定部733は、階調補正パラメータ算出部732により算出されたパラメータに基づいて、階調補正条件決定部730により決定された階調補正方法の階調補正量を仮決定し、またノイズ評価部750により評価されたノイズ増加量に基づいて階調補正量を決定(調整)する階調補正量調整部としても機能する。
The gradation correction
画像処理実行部760は、階調補正条件決定部730により決定された階調補正方法と、階調補正量決定部733により仮決定又は決定された階調補正量とに基づいて、撮影画像データに階調補正処理を施す階調補正部として機能し、さらにその他の画像処理を施す。
The image
ノイズ評価部750は、階調補正を施す前の撮影画像データに対する、階調補正方法決定部731により決定された階調補正方法と階調補正量決定部733により仮決定された階調補正量とに基づいて画像処理実行部760により階調補正が施された撮影画像データのノイズ増加量を評価し、その評価したノイズ増加量を階調補正量決定部733に出力する。
The
図3において、テンプレート処理部705は、画像調整処理部701からの指令に基づいて、テンプレート記憶手段72から所定の画像データ(テンプレート)を読み出して、画像処理対象の画像データとテンプレートを合成するテンプレート処理を行い、テンプレート処理後の画像データを画像調整処理部701に出力する。
In FIG. 3, a
CRT固有処理部706は、画像調整処理部701から入力された画像データに対して、必要に応じて画素数変更やカラーマッチング等の処理を施し、制御情報等表示が必要な情報と合成した表示用の画像データをCRT8に出力する。
The CRT specific processing unit 706 performs a process such as changing the number of pixels and color matching on the image data input from the image
プリンタ固有処理部707は、必要に応じてプリンタ固有の校正処理、カラーマッチング、画素数変更等の処理を行い、処理済の画像データを露光処理部4に出力する。
The printer-
本発明の画像処理装置1に、大判インクジェットプリンタ等の外部プリンタ51が接続可能な場合には、接続するプリンタ装置毎にプリンタ固有処理部708が備えられている。このプリンタ固有処理部708は、プリンタ固有の校正処理、カラーマッチング、画素数変更等の処理を施し、処理済の画像データを外部プリンタ51に出力する。
When an
画像データ書式作成処理部709は、画像調整処理部701から入力された画像データに対して、必要に応じてJPEG、TIFF、Exif等に代表される各種の汎用画像フォーマットへの変換を施し、処理済の画像データを画像搬送部31や通信手段(出力)33に出力する。
The image data format creation processing unit 709 converts the image data input from the image
なお、図3に示したフィルムスキャンデータ処理部702、反射原稿スキャンデータ処理部703、画像データ書式解読処理部704、画像調整処理部701、CRT固有処理部706、プリンタ固有処理部707、プリンタ固有処理部708、画像データ書式作成処理部709、という区分は、画像処理部70の機能の理解を助けるために設けた区分であり、必ずしも物理的に独立したデバイスとして実現される必要はなく、例えば、単一のCPUによるソフトウエア処理の種類の区分として実現されてもよい。
Note that the film scan
次に、本実施の形態における動作について説明する。本実施の形態において撮像画像データを画像処理する第1の画像処理は、操作部11からの第1の画像処理実行入力等をトリガとして、画像処理部70において、記憶部(図示略)から読み出されてRAM(図示略)に展開された画像処理プログラムと、CPU(図示略)との協働で実行される。
Next, the operation in this embodiment will be described. In the present embodiment, the first image processing for image processing of captured image data is read from a storage unit (not shown) in the
図6に、画像処理の流れを示す。図6に示すように、先ず、画像調整処理部701において、フィルムスキャナ部9、反射原稿入力装置10、画像転送手段30、通信手段(入力)32から、フィルムスキャンデータ処理部702、反射原稿スキャンデータ処理部703、画像データ書式解読処理部を介して、撮影画像データが取得される(ステップS1)。本実施の形態の画像処理(階調補正処理)は、DSCで撮影された画像データに対して行うことが特に好ましい。そして、シーン判別部710により、シーン判別処理が実行される(ステップS2)。
FIG. 6 shows the flow of image processing. As shown in FIG. 6, first, in the image
図7に、画像処理中のシーン判別処理の流れを示す。図7に示すように、ステップS2のシーン判別処理では、第1占有率算出部718により、撮影画像データが所定の画像領域に分割され、各分割領域が撮影画像データ全体に占める割合を示す第1の占有率を算出する第1の占有率算出処理が実行される(ステップS21)。
FIG. 7 shows a flow of scene discrimination processing during image processing. As shown in FIG. 7, in the scene determination process in step S <b> 2, the first occupancy
図8に、シーン判別処理中の第1の占有率算出処理の流れを示す。図8に示すように、ステップS21の第1の占有率算出処理では、まず、表色系変換部715により、撮影画像データのRGB値がHSV表色系に変換される(ステップS211)。図9は、RGBからHSV表色系に変換することにより色相値、彩度値、明度値を得る変換プログラム(HSV変換プログラム)の一例を、プログラムコード(C言語)により示したものである。図9に示すHSV変換プログラムでは、入力画像データであるデジタル画像データの値を、InR、InG、InBと定義し、算出された色相値をOutHとし、スケールを0〜360と定義し、彩度値をOutS、明度値をOutVとし、単位を0〜255と定義している。 FIG. 8 shows the flow of the first occupancy rate calculation process during the scene determination process. As shown in FIG. 8, in the first occupancy ratio calculation process in step S21, first, the RGB value of the photographed image data is converted into the HSV color system by the color system conversion unit 715 (step S211). FIG. 9 shows an example of a conversion program (HSV conversion program) that obtains a hue value, a saturation value, and a lightness value by converting from RGB to the HSV color system using program code (C language). In the HSV conversion program shown in FIG. 9, the values of the digital image data as the input image data are defined as InR, InG, and InB, the calculated hue value is defined as OutH, the scale is defined as 0 to 360, and the saturation The value is OutS, the brightness value is OutV, and the unit is defined as 0 to 255.
次いで、ヒストグラム作成部716により、撮影画像データが、所定の明度と色相との組み合わせからなる領域に分割され、分割領域毎に累積画素数を算出することにより2次元ヒストグラムが作成される(ステップS212)。以下、撮影画像データの領域分割について詳細に説明する。
Next, the
明度(V)は、明度値が0〜25(v1)、26〜50(v2)、51〜84(v3)、85〜169(v4)、170〜199(v5)、200〜224(v6)、225〜255(v7)の7つの領域に分割される。色相(H)は、色相値が0〜39、330〜359の肌色色相領域(H1及びH2)、色相値が40〜160の緑色色相領域(H3)、色相値が161〜250の青色色相領域(H4)、赤色色相領域(H5)の4つの領域に分割される。なお、赤色色相領域(H5)は、撮影シーンの判別への寄与が少ないとの知見から、以下の計算では用いていない。肌色色相領域は、更に、肌色領域(H1)と、それ以外の領域(H2)に分割される。以下、肌色色相領域(H=0〜39、330〜359)のうち、下記の式(2)を満たす色相’(H)を肌色領域(H1)とし、式(2)を満たさない領域を(H2)とする。
10<彩度(S)<175、
色相’(H)=色相(H)+60(0≦色相(H)<300のとき)、
色相’(H)=色相(H)−300(300≦色相(H)<360のとき)、
輝度Y=InR×0.30+InG×0.59×InB×0.11 …(1)
として、
色相’(H)/輝度(Y)<3.0×(彩度(S)/255)+0.7 …(2)
従って、撮影画像データの分割領域の数は4×7=28個となる。なお、式(1)、(2)において明度(V)を用いることも可能である。
Lightness (V) is lightness value 0-25 (v1), 26-50 (v2), 51-84 (v3), 85-169 (v4), 170-199 (v5), 200-224 (v6) , 225 to 255 (v7). Hue (H) is a skin hue hue area (H1 and H2) with a hue value of 0 to 39, 330 to 359, a green hue area (H3) with a hue value of 40 to 160, and a blue hue area with a hue value of 161 to 250 It is divided into four areas (H4) and a red hue area (H5). Note that the red hue region (H5) is not used in the following calculation because it is found that the contribution to the discrimination of the shooting scene is small. The flesh-color hue area is further divided into a flesh-color area (H1) and other areas (H2). Hereinafter, among the flesh-colored hue regions (H = 0 to 39, 330 to 359), the hue ′ (H) that satisfies the following formula (2) is defined as the flesh-colored region (H1), and the region that does not satisfy the formula (2) is ( H2).
10 <saturation (S) <175,
Hue '(H) = Hue (H) + 60 (when 0 ≤ Hue (H) <300),
Hue '(H) = Hue (H)-300 (when 300 ≤ Hue (H) <360),
Luminance Y = InR x 0.30 + InG x 0.59 x InB x 0.11 (1)
As
Hue '(H) / Luminance (Y) <3.0 × (Saturation (S) / 255) +0.7 (2)
Therefore, the number of divided areas of the captured image data is 4 × 7 = 28. In addition, it is also possible to use the brightness (V) in the expressions (1) and (2).
2次元ヒストグラムが作成されると、第1占有率算出部718により、分割領域毎に算出された累積画素数の全画素数(撮影画像全体)に占める割合を示す第1の占有率が算出され(ステップS213)、第1の占有率算出処理が終了する。明度領域vi、色相領域Hjの組み合わせからなる分割領域において算出された第1の占有率をRijとすると、各分割領域における第1の占有率は表1のように表される。
次いで、図7において、第2占有率算出部719により、第3の指標a3を算出するために用いる第2の占有率を算出する第2の占有率算出処理が実行される(ステップS22)。
Next, in FIG. 7, the second occupancy
図10に、シーン判別処理中の第2の占有率算出処理の流れを示す。図10に示すように、ステップS22の第1の占有率算出処理では、まず、表色系変換部715により、撮影画像データのRGB値がHSV表色系に変換される(ステップS221)。ステップS221は、ステップS211と共通のステップにしてもよい。次いで、ヒストグラム作成部716により、撮影画像データが、撮影画像画面の外縁からの距離と明度との組み合わせからなる領域に分割され、分割領域毎に累積画素数を算出することにより2次元ヒストグラムが作成される(ステップS222)。以下、撮影画像データの領域分割について詳細に説明する。
FIG. 10 shows the flow of the second occupancy rate calculation process during the scene determination process. As shown in FIG. 10, in the first occupancy ratio calculation process in step S22, first, the RGB value of the photographed image data is converted into the HSV color system by the color system conversion unit 715 (step S221). Step S221 may be a step common to step S211. Next, the
図11(a)〜(d)に、撮影画像データの画面の外縁からの距離に応じて分割された4つの領域n1〜n4を示す。図11(a)に示す領域n1が外枠であり、図11(b)に示す領域n2が、外枠の内側の領域であり、図11(c)に示す領域n3が、領域n2の更に内側の領域であり、図11(d)に示す領域n4が、撮影画像画面の中心部の領域である。また、明度は、上述のようにv1〜v7の7つの領域に分割するものとする。従って、撮影画像データを、撮影画像画面の外縁からの距離と明度との組み合わせからなる領域に分割した場合の分割領域の数は4×7=28個となる。 11A to 11D show four areas n1 to n4 divided according to the distance from the outer edge of the screen of the captured image data. A region n1 shown in FIG. 11A is an outer frame, a region n2 shown in FIG. 11B is a region inside the outer frame, and a region n3 shown in FIG. A region n4 shown in FIG. 11D is an inner region and is a central region of the captured image screen. Further, the lightness is divided into seven regions v1 to v7 as described above. Therefore, when the captured image data is divided into regions composed of combinations of the distance from the outer edge of the captured image screen and the brightness, the number of divided regions is 4 × 7 = 28.
2次元ヒストグラムが作成されると、第2占有率算出部719により、分割領域毎に算出された累積画素数の全画素数(撮影画像全体)に占める割合を示す第2の占有率が算出され(ステップS223)、第2の占有率算出処理が終了する。明度領域vi、画面領域njの組み合わせからなる分割領域において算出された第2の占有率をQijとすると、各分割領域における第2の占有率は表2のように表される。
次いで、図7において、第1指標算出部720により、割合算出部712において算出された第1の占有率に、撮影条件に応じて予め設定された第1、第2の係数がそれぞれ乗算され、撮影シーンを特定する(光源条件を定量的に表す)指標としての第1、第2の指標a1、a2が算出され、第2指標算出部721により、割合算出部712において算出された第2の占有率に、撮影条件に応じて予め設定された第3の係数が乗算され、撮影シーンを特定する指標としての第3の指標a3が算出される(ステップS23)。
Next, in FIG. 7, the first
表3に、ストロボ撮影としての確度、即ち、ストロボ撮影時の顔領域の明度状態を定量的に示す第1の指標a1を算出するために必要な第1の係数を分割領域別に示す。表3に示された各分割領域の係数は、表1に示した各分割領域の第1の占有率Rijに乗算する重み係数である。
図12に、明度(V)−色相(H)平面を示す。表3によると、図12において高明度の肌色色相領域に分布する領域(r1)から算出される第1の占有率には、正(+)の係数が用いられ、それ以外の色相である青色色相領域(r2)から算出される第1の占有率には、負(−)の係数が用いられる。図13は、肌色領域(H1)における第1の係数と、その他の領域(緑色色相領域(H3))における第1の係数を、明度全体に渡って連続的に変化する曲線(係数曲線)として示したものである。表3及び図13によると、高明度(V=170〜224)の領域では、肌色領域(H1)における第1の係数の符号は正(+)であり、その他の領域(例えば、緑色色相領域(H3))における第1の係数の符号は負(−)であり、両者の符号が異なっていることがわかる。 FIG. 12 shows a lightness (V) -hue (H) plane. According to Table 3, a positive (+) coefficient is used for the first occupancy calculated from the region (r1) distributed in the high brightness skin color hue region in FIG. 12, and the other hue is blue. A negative (-) coefficient is used for the first occupancy calculated from the hue region (r2). FIG. 13 shows a curve (coefficient curve) in which the first coefficient in the skin color area (H1) and the first coefficient in the other areas (green hue area (H3)) continuously change over the entire brightness. It is shown. According to Table 3 and FIG. 13, in the region of high brightness (V = 170 to 224), the sign of the first coefficient in the skin color region (H1) is positive (+), and other regions (for example, the green hue region) The sign of the first coefficient in (H3)) is negative (-), and it can be seen that the signs of the two are different.
明度領域vi、色相領域Hjにおける第1の係数をCijとすると、第1の指標a1を算出するためのHk領域の和は、式(3)のように定義される。
H1領域の和=R11×(-44.0)+R21×(-16.0)+(中略)...+R71×(-11.3) …(3−1)
H2領域の和=R12×0.0+R22×8.6+(中略)...+R72×(-11.1) …(3−2)
H3領域の和=R13×0.0+R23×(-6.3)+(中略)...+R73×(-10.0) …(3−3)
H4領域の和=R14×0.0+R24×(-1.8)+(中略)...+R74×(-14.6) …(3−4)
When the first coefficient in the lightness region vi and the hue region Hj is Cij, the sum of the Hk regions for calculating the first index a1 is defined as in Expression (3).
Sum of H1 regions = R11 x (-44.0) + R21 x (-16.0) + (omitted) ... + R71 x (-11.3) ... (3-1)
Sum of H2 regions = R12 x 0.0 + R22 x 8.6 + (omitted) ... + R72 x (-11.1) (3-2)
H3 region sum = R13 x 0.0 + R23 x (-6.3) + (omitted) ... + R73 x (-10.0) ... (3-3)
Sum of H4 region = R14 x 0.0 + R24 x (-1.8) + (omitted) ... + R74 x (-14.6) ... (3-4)
第1の指標a1は、式(3−1)〜(3−4)で示されたH1〜H4領域の和を用いて、式(4)のように定義される。
a1=H1領域の和+H2領域の和+H3領域の和+H4領域の和+4.424 …(4)
The first index a1 is defined as in Expression (4) using the sum of the H1 to H4 regions shown in Expressions (3-1) to (3-4).
a1 = sum of H1 region + sum of H2 region + sum of H3 region + sum of H4 region + 4.424 (4)
表4に、逆光撮影としての確度、即ち、逆光撮影時の顔領域の明度状態を定量的に示す第2の指標a2を算出するために必要な第2の係数を分割領域別に示す。表4に示された各分割領域の係数は、表1に示した各分割領域の第1の占有率Rijに乗算する重み係数である。
図14に、明度(V)−色相(H)平面を示す。表4によると、図14において肌色色相領域の中間明度に分布する領域(r4)から算出される第1の占有率には負(−)の係数が用いられ、肌色色相領域の低明度(シャドー)領域(r3)から算出される第1の占有率には正(+)の係数が用いられる。図15は、肌色領域(H1)における第2の係数を、明度全体に渡って連続的に変化する曲線(係数曲線)として示したものである。表4及び図15によると、肌色色相領域の、明度値が85〜169(v4)の中間明度領域の第2の係数の符号は負(−)であり、明度値が26〜84(v2,v3)の低明度(シャドー)領域の第2の係数の符号は正(+)であり、両領域での係数の符号が異なっていることがわかる。 FIG. 14 shows a lightness (V) -hue (H) plane. According to Table 4, a negative (−) coefficient is used for the first occupancy calculated from the region (r4) distributed in the intermediate lightness of the flesh color hue region in FIG. 14, and the low lightness (shadow) of the flesh color hue region is used. ) A positive (+) coefficient is used for the first occupancy calculated from the region (r3). FIG. 15 shows the second coefficient in the skin color area (H1) as a curve (coefficient curve) that continuously changes over the entire brightness. According to Table 4 and FIG. 15, the sign of the second coefficient of the intermediate lightness region of the flesh-colored hue region having the lightness value of 85 to 169 (v4) is negative (−), and the lightness value is 26 to 84 (v2, It can be seen that the sign of the second coefficient in the low brightness (shadow) region of v3) is positive (+), and the sign of the coefficient in both regions is different.
明度領域vi、色相領域Hjにおける第2の係数をDijとすると、第2の指標a2を算出するためのHk領域の和は、式(5)のように定義される。
H1領域の和=R11×(-27.0)+R21×4.5+(中略)...+R71×(-24.0) …(5−1)
H2領域の和=R12×0.0+R22×4.7+(中略)...+R72×(-8.5) …(5−2)
H3領域の和=R13×0.0+R23×0.0+(中略)...+R73×0.0 …(5−3)
H4領域の和=R14×0.0+R24×(-5.1)+(中略)...+R74×7.2 …(5−4)
When the second coefficient in the lightness area vi and the hue area Hj is Dij, the sum of the Hk areas for calculating the second index a2 is defined as in Expression (5).
Sum of H1 regions = R11 x (-27.0) + R21 x 4.5 + (omitted) ... + R71 x (-24.0) (5-1)
Sum of H2 area = R12 x 0.0 + R22 x 4.7 + (omitted) ... + R72 x (-8.5) (5-2)
Sum of H3 regions = R13 x 0.0 + R23 x 0.0 + (omitted) ... + R73 x 0.0 (5-3)
H4 area sum = R14 x 0.0 + R24 x (-5.1) + (omitted) ... + R74 x 7.2 (5-4)
第2の指標a2は、式(5−1)〜(5−4)で示されたH1〜H4領域の和を用いて、式(6)のように定義される。
a2=H1領域の和+H2領域の和+H3領域の和+H4領域の和+1.554 …(6)
第1及び第2の指標a1,a2は、撮影画像データの明度と色相との分布量に基づいて算出されるため、撮影画像データがカラー画像である場合の撮影シーンの判別に有効である。
The second index a2 is defined as in Expression (6) using the sum of the H1 to H4 regions shown in Expressions (5-1) to (5-4).
a2 = sum of H1 regions + sum of H2 regions + sum of H3 regions + sum of H4 regions + 1.554 (6)
Since the first and second indicators a1 and a2 are calculated based on the distribution amount of the brightness and hue of the photographed image data, they are effective in determining the photographing scene when the photographed image data is a color image.
次いで、表5に、第3の指標a3を算出するために必要な第3の係数を分割領域別に示す。表5に示された各分割領域の係数は、表2に示した各分割領域の第2の占有率Qijに乗算する重み係数であり、撮影条件に応じて予め設定されている。
明度領域vi、画面領域njにおける第3の係数をEijとすると、第3の指標a3を算出するためのnk領域(画面領域nk)の和は、式(7)のように定義される。
n1領域の和=Q11×40.1+Q21×37.0+(中略)...+Q71×22.0 …(7−1)
n2領域の和=Q12×(-14.8)+Q22×(-10.5)+(中略)...+Q72×0.0 …(7−2)
n3領域の和=Q13×24.6+Q23×12.1+(中略)...+Q73×10.1 …(7−3)
n4領域の和=Q14×1.5+Q24×(-32.9)+(中略)...+Q74×(-52.2) …(7−4)
If the third coefficient in the brightness area vi and the screen area nj is Eij, the sum of the nk area (screen area nk) for calculating the third index a3 is defined as in Expression (7).
Sum of n1 regions = Q11 x 40.1 + Q21 x 37.0 + (omitted) ... + Q71 x 22.0 (7-1)
Sum of n2 regions = Q12 x (-14.8) + Q22 x (-10.5) + (omitted) ... + Q72 x 0.0 (7-2)
Sum of n3 regions = Q13 x 24.6 + Q23 x 12.1 + (omitted) ... + Q73 x 10.1 (7-3)
n4 area sum = Q14 x 1.5 + Q24 x (-32.9) + (omitted) ... + Q74 x (-52.2) ... (7-4)
第3の指標a3は、式(7−1)〜(7−4)で示されたn1〜n4領域の和を用いて、式(8)のように定義される。
a3=n1領域の和+n2領域の和+n3領域の和+n4領域の和−12.6201 …(8)
第3の指標a3は、撮影画像データの明度の分布位置による構図的な特徴(撮影画像データの画面の外縁からの距離)に基づいて算出されるため、カラー画像だけでなくモノクロ画像の撮影シーンを判別するのにも有効である。
The third index a3 is defined as in Expression (8) using the sum of the n1 to n4 regions shown in Expressions (7-1) to (7-4).
a3 = sum of n1 regions + sum of n2 regions + sum of n3 regions + sum of n4 regions−12.6201 (8)
Since the third index a3 is calculated based on the compositional feature (distance from the outer edge of the screen of the captured image data) based on the brightness distribution position of the captured image data, the captured scene of the monochrome image as well as the color image is captured. It is also effective in determining
次いで、図7において、第3指標算出部722により、撮影シーンを特定する指標としての第4の指標a4を算出する第4の指標算出処理が実行される(ステップS24)。図17に、シーン判別処理中の第4の指標算出処理の流れを示す。第4の指標算出処理では、図17に示すように、先ず、第3指標算出部722により、撮影画像データのRGB値から、上記式(1)を用いて輝度Yが算出され、撮影画像データの画面中央部における肌色の平均輝度値x1が算出される(ステップS241)。そして、第3指標算出部722により、撮影画像データの画像の最大輝度値と平均輝度値との差分値x2が算出される(ステップS242)。最大輝度値と平均輝度値との差分値x2は、次式(9)のように表される。
x2=Ymax−Yave …(9)
Next, in FIG. 7, the third
x2 = Ymax−Yave (9)
そして、第3指標算出部722により、撮影画像データの輝度標準偏差x3が算出される(ステップS243)。そして、第3指標算出部722により、撮影画像データの画面中央部における輝度平均値x4が算出される(ステップS244)。そして、第3指標算出部722により、撮影画像データの画像の肌色最大輝度値及び肌色最小輝度値の差分値と、肌色平均輝度値と、の比較値x5が算出される(ステップS245)。画像の肌色最大輝度値及び肌色最小輝度値の差分値と肌色平均輝度値との比較値x5は、次式(10)のように表される。
x5=(Yskin_max−Yskin_min)/2−Yskin_ave …(10)
Then, the luminance standard deviation x3 of the captured image data is calculated by the third index calculation unit 722 (step S243). Then, the third
x5 = (Yskin_max−Yskin_min) / 2−Yskin_ave (10)
そして、第3指標算出部722により、画面中央部における肌色の平均輝度値x1、画像の最大輝度値と平均輝度値との差分値x2、輝度標準偏差x3、画面中央部における輝度平均値x4、画像の肌色最大輝度値及び肌色最小輝度値の差分値と肌色平均輝度値との比較値x5の各々に、撮影条件に応じて予め設定された第4の係数が乗算されて和がとられることにより第4の指標a4が算出され(ステップS246)、第4の指標算出処理が終了する。
Then, the third
第4の指標a4は、ステップS241〜S245で算出された値に対し、判別分析によって求められた第4の係数を乗算した和を用いて、式(11)のように定義される。
a4=0.06×x1+1.13×x2+0.02×x3+(-0.01)×x4+0.03×x5−6.50 …(11)
第4の指標a4は、撮影画像データの画面の構図的な特徴だけでなく、輝度ヒストグラム分布情報を持ち合わせており、特にフラッシュ撮影シーン及びアンダー撮影シーンの判別に有効である。
The fourth index a4 is defined as Equation (11) using a sum obtained by multiplying the value calculated in Steps S241 to S245 by the fourth coefficient obtained by discriminant analysis.
a4 = 0.06 × x1 + 1.13 × x2 + 0.02 × x3 + (− 0.01) × x4 + 0.03 × x5−6.50 (11)
The fourth index a4 has not only the compositional characteristics of the screen of the photographed image data but also the luminance histogram distribution information, and is particularly effective for discriminating the flash photographing scene and the under photographing scene.
次いで、図7において、第3指標算出部722により、撮影シーンを特定する指標としての第5の指標a5及び第6の指標a6が算出される(ステップS25)。
Next, in FIG. 7, the third
ここで、撮影画像データの画面中央部における肌色の平均輝度値を第4’の指標a4’とする。ここでの画面中央部とは、例えば、図13の領域n2、領域n3及び領域n4から構成される領域である。第5の指標a5は、第1の指標a1、第3の指標a3及び第4’の指標a4’を用いて式(12)のように定義され、第6の指標a6は、第2の指標a2、第3の指標a3、第4’の指標a4’を用いて式(13)のように定義される。
a5=0.46×a1+0.61×a3+0.01×a4’−0.79 …(12)
a6=0.58×a2+0.18×a3+(-0.03)×a4’+3.34 …(13)
ここで、式(12)、(13)において各指標に乗算される重み係数は、撮影条件に応じて予め設定されている。
Here, the average luminance value of the skin color at the center of the screen of the photographed image data is set as a fourth ′ index a4 ′. Here, the center of the screen is, for example, an area composed of the area n2, the area n3, and the area n4 in FIG. The fifth index a5 is defined as in Expression (12) using the first index a1, the third index a3, and the fourth ′ index a4 ′, and the sixth index a6 is the second index Using the a2, the third index a3, and the fourth ′ index a4 ′, it is defined as in the equation (13).
a5 = 0.46 × a1 + 0.61 × a3 + 0.01 × a4′−0.79 (12)
a6 = 0.58 × a2 + 0.18 × a3 + (− 0.03) × a4 ′ + 3.34 (13)
Here, the weighting coefficient by which each index is multiplied in Expressions (12) and (13) is set in advance according to the shooting conditions.
そして、図7において、シーン判別実行部714により、指標算出部713において算出された第4の指標a4、第5の指標a5、第6の指標a6の値に基づいて、撮影画像データの撮影シーン(光源条件及び露出条件)が判別され(ステップS26)、シーン判別処理が終了される。以下、撮影シーン(光源条件及び露出条件)の判別方法について説明する。
In FIG. 7, the scene
図18(a)は、順光、逆光、ストロボの各光源条件で60枚ずつ撮影し、合計180枚のデジタル画像データについて、第5の指標a5、第6の指標a6を算出し、各光源条件での第5の指標a5、第6の指標a6の値をプロットしたものである。図18(a)によれば、第5の指標a5の値が0.5より大きい場合、ストロボ撮影シーンが多く、第5の指標a5の値が0.5以下で、第6の指標a6の値が−0.5より大きい場合、逆光撮影シーンが多いことがわかる。このように第5の指標a5、第6の指標a6の値により撮影シーン(光源条件及び露出条件)を定量的に判別することができる。 In FIG. 18A, 60 images are shot under each light source condition of forward light, backlight, and strobe, and the fifth index a5 and the sixth index a6 are calculated for a total of 180 digital image data. The values of the fifth index a5 and the sixth index a6 under the conditions are plotted. According to FIG. 18A, when the value of the fifth index a5 is larger than 0.5, there are many flash photography scenes, the value of the fifth index a5 is 0.5 or less, and the sixth index a6 When the value is larger than −0.5, it can be seen that there are many backlight photographing scenes. Thus, the shooting scene (light source condition and exposure condition) can be quantitatively determined based on the values of the fifth index a5 and the sixth index a6.
さらに、順光、逆光、ストロボの各撮影シーンを判別できる第5の指標a5、第6の指標a6に、第4の指標a4を加えることで、3次元で撮影シーン(光源条件及び露出条件)を判別することができるようになり、より判別精度をあげることが可能となる。3次元的に撮影シーンが判別可能となり、撮影シーンの判別精度を一層向上させることが可能となる。第4の指標a4は特に、画像全体を暗くする階調補正が行われるストロボ撮影シーンと、画像全体を明るくする階調補正が行われるアンダー撮影シーンとを判別するのに有効である。 Furthermore, the fourth index a4 is added to the fifth index a5 and the sixth index a6 that can discriminate each of the shooting scenes of the front light, the backlight, and the strobe light, so that the three-dimensional shooting scene (light source condition and exposure condition) Can be discriminated, and the discrimination accuracy can be further increased. The shooting scene can be discriminated three-dimensionally, and the discrimination accuracy of the shooting scene can be further improved. The fourth index a4 is particularly effective for discriminating between a flash photography scene in which gradation correction is performed to darken the entire image and an under photography scene in which gradation correction is performed to brighten the entire image.
図18(b)は、ストロボ撮影シーンとアンダー撮影シーンとの撮影画像データ各60枚のうち、第5の指標a5が0.5より大きい撮影画像データの第4の指標a4及び第5の指標a5を算出しプロットしたものである。図18(b)によれば、第4の指標a4の値が0より大きい場合、ストロボ撮影シーンが多く、第4の指標a4の値が0以下の場合、アンダー撮影シーンが多いことがわかる。表6に、第4の指標a4〜第6の指標a6の値による撮影シーンの判別内容を示す。
そして、図6において、階調補正方法決定部731により、ステップS2で判別された撮影シーンに応じて、撮影画像データに対する階調補正方法が決定され、階調補正パラメータ算出部732により、指標算出部713において算出された指標に基づいて、階調補正に必要なパラメータ(階調補正パラメータ)が算出され、階調補正量決定部733により、その算出された階調補正パラメータに基づいて階調補正量が仮決定される(ステップS3)。
In FIG. 6, the gradation correction
階調補正方法の決定は、図19に示すように、撮影シーンが順光である場合は階調補正方法A(図19(a))が選択され、逆光である場合は階調補正方法B(図19(b))が選択され、ストロボである場合は階調補正方法C(図19(c))が選択され、アンダーである場合は階調補正方法B(図19(b))が選択される。 As shown in FIG. 19, the gradation correction method is determined by selecting the gradation correction method A (FIG. 19A) when the shooting scene is a continuous light, and the gradation correction method B when the shooting scene is a backlight. When (FIG. 19B) is selected and the strobe is selected, the gradation correction method C (FIG. 19C) is selected, and when it is under, the gradation correction method B (FIG. 19B) is selected. Selected.
以下、ステップS3において算出される階調補正パラメータの算出方法について説明する。なお、以下では、8bitの撮影画像データは16bitへと事前に変換されているものとし、撮影画像データの値の単位は16bitであるものとする。 Hereinafter, the calculation method of the gradation correction parameter calculated in step S3 will be described. In the following description, it is assumed that the 8-bit captured image data is converted in advance to 16 bits, and the unit of the value of the captured image data is 16 bits.
階調補正に必要なパラメータ(階調補正パラメータ)として、下記のP1〜P9のパラメータが算出される。
P1:撮影画面全体の平均輝度
P2:ブロック分割平均輝度
P3:肌色領域(H1)の平均輝度
P4:第1の輝度補正値=P1−P2
P5:再現目標修正値=輝度再現目標値(30360)−P4
P6:第1のオフセット値=P5−P1
P7:第1のキー補正値
P7':第2のキー補正値
P8:第2の輝度補正値
P9:第2のオフセット値=P5−P8−P1
The following parameters P1 to P9 are calculated as parameters necessary for tone correction (tone correction parameters).
P1: Average brightness of the entire shooting screen
P2: Block division average brightness
P3: Average brightness of skin tone area (H1)
P4: First brightness correction value = P1-P2
P5: Reproduction target correction value = Brightness reproduction target value (30360)-P4
P6: First offset value = P5-P1
P7: First key correction value
P7 ': Second key correction value
P8: Second brightness correction value
P9: Second offset value = P5-P8-P1
ここで、図20及び図21を参照して、パラメータP2の算出方法について説明する。まず、撮影画像データを正規化するために、CDF(累積密度関数)を作成する。次いで、得られたCDFから最大値と最小値を決定する。この最大値と最小値は、RGB毎に求める。ここで、求められたRGB毎の最大値と最小値を、それぞれ、Rmax、Rmin、Gmax、Gmin、Bmax、Bminとする。 Here, a method for calculating the parameter P2 will be described with reference to FIGS. First, a CDF (cumulative density function) is created in order to normalize captured image data. Next, the maximum value and the minimum value are determined from the obtained CDF. The maximum value and the minimum value are obtained for each RGB. Here, the obtained maximum and minimum values for each RGB are Rmax, Rmin, Gmax, Gmin, Bmax, and Bmin, respectively.
次いで、撮影画像データの任意の画素(Rx,Gx,Bx)に対する正規化画像データを算出する。RプレーンにおけるRxの正規化データをRpoint、GプレーンにおけるGxの正規化データをGpoint、BプレーンにおけるBxの正規化データをBpointとすると、正規化データRpoint、Gpoint、Bpointは、それぞれ、式(14)〜(16)のように表される。
Rpoint={(Rx−Rmin)/(Rmax−Rmin)}×65535 …(14)
Gpoint={(Gx−Gmin)/(Gmax−Gmin)}×65535 …(15)
Bpoint={(Bx−Bmin)/(Bmax−Bmin)}×65535 …(16)
次いで、式(17)により画素(Rx,Gx,Bx)の輝度Npointを算出する。
Npoint=(Bpoint+Gpoint+Rpoint)/3 …(17)
Next, normalized image data for any pixel (Rx, Gx, Bx) of the captured image data is calculated. R point normalization data in R plane is R point , Gx normalization data in G plane is G point , Bx normalization data in B plane is B point , normalization data R point , G point , B point are Are expressed as in the equations (14) to (16), respectively.
R point = {(Rx−Rmin) / (Rmax−Rmin)} × 65535 (14)
G point = {(Gx−Gmin) / (Gmax−Gmin)} × 65535 (15)
B point = {(Bx−Bmin) / (Bmax−Bmin)} × 65535 (16)
Next, the luminance N point of the pixel (Rx, Gx, Bx) is calculated by Expression (17).
N point = (B point + G point + R point ) / 3 (17)
図20(a)は、正規化する前のRGB画素の輝度の度数分布(ヒストグラム)である。図20(a)において、横軸は輝度、縦軸は画素の頻度である。このヒストグラムは、RGB毎に作成する。輝度のヒストグラムが作成されると、式(14)〜(16)により、撮影画像データに対し、プレーン毎に正規化を行う。図20(b)は、式(17)により算出された輝度のヒストグラムを示す。撮影画像データが65535で正規化されている
ため、各画素は、最大値が65535で最小値が0の間で任意の値をとる。
FIG. 20A shows a frequency distribution (histogram) of luminance of RGB pixels before normalization. In FIG. 20A, the horizontal axis represents luminance, and the vertical axis represents pixel frequency. This histogram is created for each RGB. When the luminance histogram is created, normalization is performed for each plane with respect to the captured image data according to equations (14) to (16). FIG. 20B shows a histogram of luminance calculated by the equation (17). Since the captured image data is normalized by 65535, each pixel takes an arbitrary value between the maximum value 65535 and the
図20(b)に示す輝度ヒストグラムを所定の範囲で区切ってブロックに分割すると、図20(c)に示すような度数分布が得られる。図20(c)において、横軸はブロック番号(輝度)、縦軸は頻度である。 When the luminance histogram shown in FIG. 20B is divided into blocks divided by a predetermined range, a frequency distribution as shown in FIG. 20C is obtained. In FIG. 20C, the horizontal axis represents the block number (luminance) and the vertical axis represents the frequency.
次いで、図20(c)に示された輝度ヒストグラムから、ハイライト、シャドー領域を削除する処理を行う。これは、白壁や雪上シーンでは、平均輝度が非常に高くなり、暗闇のシーンでは平均輝度は非常に低くなっているため、ハイライト、シャドー領域は、平均輝度制御に悪影響を与えてしまうことによる。そこで、図20(c)に示した輝度ヒストグラムのハイライト領域、シャドー領域を制限することによって、両領域の影響を減少させる。図21(a)(又は図20(c))に示す輝度ヒストグラムにおいて、高輝度領域(ハイライト領域)及び低輝度領域(シャドー領域)を削除すると、図21(b)のようになる。 Next, a process of deleting highlight and shadow areas is performed from the luminance histogram shown in FIG. This is because the average brightness is very high in white walls and snow scenes, and the average brightness is very low in dark scenes, so highlights and shadow areas adversely affect average brightness control. . Therefore, by limiting the highlight area and the shadow area of the luminance histogram shown in FIG. 20C, the influence of both areas is reduced. When the high luminance region (highlight region) and the low luminance region (shadow region) are deleted from the luminance histogram shown in FIG. 21A (or FIG. 20C), the result is as shown in FIG.
次いで、図21(c)に示すように、輝度ヒストグラムにおいて、頻度が所定の閾値より大きい領域を削除する。これは、頻度が極端に多い部分が存在すると、この部分のデータが、撮影画像全体の平均輝度に強く影響を与えてしまうため、誤補正が生じやすいことによる。そこで、図21(c)に示すように、輝度ヒストグラムにおいて、閾値以上の画素数を制限する。図21(d)は、画素数の制限処理を行った後の輝度ヒストグラムである。 Next, as shown in FIG. 21C, an area having a frequency greater than a predetermined threshold is deleted from the luminance histogram. This is because if there is a part having an extremely high frequency, the data in this part strongly affects the average luminance of the entire captured image, and thus erroneous correction is likely to occur. Therefore, as shown in FIG. 21C, the number of pixels equal to or larger than the threshold is limited in the luminance histogram. FIG. 21D is a luminance histogram after the pixel number limiting process is performed.
正規化された輝度ヒストグラムから、高輝度領域及び低輝度領域を削除し、更に、累積画素数を制限することによって得られた輝度ヒストグラム(図21(d))の各ブロック番号と、それぞれの頻度に基づいて、輝度の平均値を算出したものがパラメータP2である。 Each block number of the luminance histogram (FIG. 21 (d)) obtained by deleting the high luminance region and the low luminance region from the normalized luminance histogram and further limiting the number of accumulated pixels, and the respective frequencies The parameter P2 is obtained by calculating the average luminance value based on the above.
パラメータP1は、撮影画像データ全体の輝度の平均値であり、パラメータP3は、撮影画像データのうち肌色領域(H1)の輝度の平均値である。パラメータP7の第1のキー補正値、パラメータP7'の第2のキー補正値、パラメータP8の第2の輝度補正値は、それぞれ、式(18)〜(20)のように定義される。
P7(第1のキー補正値)={P3−((a6/6)×18000+22000)}/24.78 …(18)
P7’(第2のキー補正値)={P3−((a4/6)×10000+30000)}/24.78 …(19)
P8(第2の輝度補正値)=(a5/6)×17500 …(20)
The parameter P1 is an average value of the brightness of the entire captured image data, and the parameter P3 is an average value of the brightness of the skin color area (H1) in the captured image data. The first key correction value for parameter P7, the second key correction value for parameter P7 ′, and the second luminance correction value for parameter P8 are defined as shown in equations (18) to (20), respectively.
P7 (first key correction value) = {P3 − ((a6 / 6) × 18000 + 22000)} / 24.78 (18)
P7 ′ (second key correction value) = {P3 − ((a4 / 6) × 10000 + 30000)} / 24.78 (19)
P8 (second luminance correction value) = (a5 / 6) × 17500 (20)
算出された階調補正パラメータに基づく、撮影画像データに対する階調補正量の仮決定では、具体的には、決定された階調補正方法に対応して予め設定された複数の階調補正曲線の中から、算出された階調補正パラメータに対応する階調補正曲線が選択(決定)される。なお、算出された階調補正パラメータに基づいて、階調補正曲線(階調補正量)を算出するようにしてもよい。 In the provisional determination of the gradation correction amount for the captured image data based on the calculated gradation correction parameter, specifically, a plurality of gradation correction curves set in advance corresponding to the determined gradation correction method are used. A gradation correction curve corresponding to the calculated gradation correction parameter is selected (determined) from among them. Note that a tone correction curve (tone correction amount) may be calculated based on the calculated tone correction parameter.
以下、各撮影シーン(光源条件及び露出条件)の階調補正曲線の決定方法について説明する。
<順光の場合>
撮影シーンが順光である場合、パラメータP1をP5と一致させるオフセット補正(8bit値の平行シフト)を次式(21)により行う。
出力画像のRGB値=入力画像のRGB値+P6 …(21)
従って、撮影シーンが順光の場合、図19(a)に示す複数の階調補正曲線の中から、式(19)に対応する階調補正曲線が選択される。又は、式(21)に基づいて階調補正曲線を算出(決定)してもよい。
Hereinafter, a method for determining a gradation correction curve for each shooting scene (light source condition and exposure condition) will be described.
<For direct light>
When the shooting scene is front light, offset correction (parallel shift of 8-bit value) for matching the parameter P1 with P5 is performed by the following equation (21).
RGB value of output image = RGB value of input image + P6 (21)
Therefore, when the photographic scene is front light, a gradation correction curve corresponding to Expression (19) is selected from a plurality of gradation correction curves shown in FIG. Alternatively, the gradation correction curve may be calculated (determined) based on the equation (21).
<逆光の場合>
撮影シーンが逆光である場合、図19(b)に示す複数の階調補正曲線の中から、式(18)に示すパラメータP7(第1のキー補正値)に対応する階調補正曲線を選択する。図19(b)の階調補正曲線の具体例を図22に示す。パラメータP7の値と、選択される階調補正曲線の対応関係を以下に示す。
−0.5<P7<+0.5の場合→L3
+0.5≦P7<+1.5の場合→L4
+1.5≦P7<+2.5の場合→L5
−1.5<P7≦−0.5の場合→L2
−2.5<P7≦−1.5の場合→L1
なお、撮影シーンが逆光の場合、この階調補正処理とともに、覆い焼き処理を併せて行うことが好ましい。この場合、逆光度を示す第5の指標a5に応じて覆い焼き処理の程度も調整されることが望ましい。
<In the case of backlight>
When the shooting scene is backlit, a gradation correction curve corresponding to the parameter P7 (first key correction value) shown in Expression (18) is selected from the plurality of gradation correction curves shown in FIG. To do. A specific example of the gradation correction curve of FIG. 19B is shown in FIG. The correspondence relationship between the value of parameter P7 and the selected gradation correction curve is shown below.
If -0.5 <P7 <+ 0.5 → L3
When + 0.5 ≦ P7 <+1.5 → L4
+ 1.5 ≦ P7 <+2.5 → L5
When -1.5 <P7≤-0.5 → L2
When -2.5 <P7≤-1.5 → L1
When the shooting scene is backlit, it is preferable to perform a dodging process together with the gradation correction process. In this case, it is desirable that the degree of the dodging process be adjusted according to the fifth index a5 indicating the backlight intensity.
<アンダーの場合>
撮影シーンがアンダーである場合、図19(b)に示す複数の階調補正曲線の中から、式(19)に示すパラメータP7'(第2のキー補正値)に対応する階調補正曲線が選択される。具体的には、撮影シーンが逆光の場合の階調補正曲線の選択方法と同様に、図22に示す階調補正曲線の中から、パラメータP7'の値に対応した階調補正曲線が選択される。なお、撮影シーンがアンダーである場合は、逆光の場合に示したような覆い焼き処理は行わない。
<In case of under>
When the shooting scene is under, a gradation correction curve corresponding to the parameter P7 ′ (second key correction value) shown in Expression (19) is selected from the plurality of gradation correction curves shown in FIG. Selected. Specifically, the gradation correction curve corresponding to the value of the parameter P7 ′ is selected from the gradation correction curves shown in FIG. 22 in the same manner as the selection method of the gradation correction curve when the shooting scene is backlit. The When the shooting scene is under, the dodging process as shown in the case of backlight is not performed.
<ストロボの場合>
撮影シーンがストロボである場合、オフセット補正(8bit値の平行シフト)を次式(22)により行う。
出力画像のRGB値=入力画像のRGB値+P9 …(22)
従って、撮影シーンがストロボの場合、図19(c)に示す複数の階調補正曲線の中から、式(22)に対応する階調補正曲線が選択される。又は、式(22)に基づいて階調補正曲線を算出(決定)してもよい。なお、式(22)のパラメータP9の値が、予め設定された所定値αを上回った場合、図22に示す曲線L1〜L5の中から、第2のキー補正値=P9−αに対応する曲線を選択する。
<In the case of strobe>
When the shooting scene is a strobe, offset correction (parallel shift of 8-bit value) is performed by the following equation (22).
RGB value of output image = RGB value of input image + P9 (22)
Therefore, when the shooting scene is a strobe, a gradation correction curve corresponding to the equation (22) is selected from a plurality of gradation correction curves shown in FIG. Alternatively, the gradation correction curve may be calculated (determined) based on Expression (22). When the value of the parameter P9 in the equation (22) exceeds a preset predetermined value α, it corresponds to the second key correction value = P9−α from the curves L1 to L5 shown in FIG. Select a curve.
本実施の形態では、実際に撮影画像データに対して階調補正処理を施す場合、上述の各画像処理条件を16bitから8bitへ変更するものとする。 In the present embodiment, when the gradation correction processing is actually performed on the captured image data, each of the image processing conditions described above is changed from 16 bits to 8 bits.
なお、順光、逆光、ストロボ間で階調補正方法が大きく異なる場合、撮影シーンの誤判別時の画質への影響が懸念されるため、順光、逆光、ストロボ間に、階調補正方法が緩やかに移行する中間領域を設定することが望ましい。 Note that if the tone correction method differs greatly between the following light, backlight, and strobe, there is a concern about the effect on image quality when shooting scenes are misidentified.Therefore, there is a tone correction method between the following light, backlight, and strobe. It is desirable to set an intermediate area that moves slowly.
以上のように、ステップS2,S3によれば、撮影画像データの撮影シーンを定量的に示す指標を算出し、その算出された指標に基づいて撮影シーンを判別し、判別結果に応じて撮影画像データに対する階調補正方法を決定し、撮影画像データの階調補正量を仮決定して、被写体の明度を適切に補正する階調補正方法の決定と、階調補正量の仮決定とを行うことが可能となる。 As described above, according to steps S2 and S3, an index that quantitatively indicates the shooting scene of the shot image data is calculated, the shooting scene is determined based on the calculated index, and the shot image is determined according to the determination result. A gradation correction method for data is determined, a gradation correction amount of the captured image data is provisionally determined, a gradation correction method for appropriately correcting the brightness of the subject, and a provisional determination of the gradation correction amount are performed. It becomes possible.
特に、ストロボ撮影としての確度を定量的に示す第1の指標a1と、逆光撮影としての確度を定量的に示す第2の指標a2に加えて、撮影画像データの構図的な要素から導出される第3の指標a3を用いて撮影シーンを判別することにより、撮影シーンの判別精度を向上させることができる。
また、構図的な要素とヒストグラムの分布情報から算出される第4の指標a4を用いることで、画像全体を暗くする階調補正を行うストロボシーンと画像全体を明るく階調補正するアンダー撮影シーンとを判別でき、撮影シーンの判別精度を向上させることができる。
In particular, in addition to the first index a1 that quantitatively indicates the accuracy of flash photography and the second index a2 that quantitatively shows the accuracy of backlight photography, it is derived from the compositional elements of the captured image data. By determining the shooting scene using the third index a3, it is possible to improve the shooting scene determination accuracy.
Further, by using a fourth index a4 calculated from compositional elements and histogram distribution information, a strobe scene that performs gradation correction that darkens the entire image, and an under shooting scene that performs gradation correction that brightens the entire image, and Can be discriminated, and the discrimination accuracy of the shooting scene can be improved.
そして、図6において、画像処理実行部740により、ステップS3で決定された階調補正方法と、仮決定された階調補正量とを用いて、撮影画像データに階調補正(仮階調補正)処理が施される(ステップS4)。そして、ノイズ評価部750により、仮階調補正前の撮影画像データに対する、仮階調補正された撮影画像データのノイズ増加量が評価される(ステップS5)。ここでノイズ増加量の評価は、公知の方法を用いることができる。例えば、特開2004-127064に記載されているような二項ウェーブレット変換を用いてノイズ増加量を評価する方法を用いることができる。ここで、ウェーブレット変換について簡単に説明する。
In FIG. 6, the image
〈ウェーブレット変換の概要〉
ウェーブレット変換とは、多重解像度変換の一つで、1回の変換操作により入力信号を低周波帯域成分信号と高周波帯域成分信号に分解し、得られた低周波帯域成分信号に対して同様の変換操作を行い、周波数帯域が異なる複数の信号からなる多重解像度信号を得るものである。得られた多重解像度信号を加工せずにそのまま逆多重解像度変換した場合、元の信号が再構成される。こうした手法については、例えば、G. Strang、T. Nguyen著"Wavelet and Filter Banks"Wellesley-Cambridge Press(邦訳 G.ストラング、T.グエン共著「ウェーブレット解析とフィルタバンク」培風館)に詳細な解説がなされている。
<Overview of wavelet transform>
Wavelet transform is a multi-resolution transform that decomposes an input signal into a low-frequency band component signal and a high-frequency band component signal by a single conversion operation, and performs the same conversion on the obtained low-frequency band component signal. An operation is performed to obtain a multi-resolution signal composed of a plurality of signals having different frequency bands. When the obtained multiresolution signal is subjected to inverse multiresolution conversion without being processed, the original signal is reconstructed. For example, G. Strang and T. Nguyen “Wavelet and Filter Banks” Wellesley-Cambridge Press (Japanese translation by G. Strang and T. Nguyen “Wavelet Analysis and Filter Bank” Bafukan) provides a detailed explanation. ing.
ウェーブレット変換とは、図23に例示されるような有限範囲で振動するウェーブレット関数(式(23))を用いて、入力信号f(x)に対するウェーブレット変換係数〈f、ψa,b〉を、式(24)のように求めることにより、式(25)で示されるウェーブレット関数の総和に分解する変換である。
式(23)〜(25)において、aはウェーブレット関数のスケールを表し、bはウェーブレット関数の位置を示す。図23に例示するように、スケールaの値が大きいほどウェーブレット関数ψa,b(x)の周波数は小さくなり、位置bの値に従ってウェーブレット関数ψa,b(x)が振動する位置が移動する。従って、式(25)は、入力信号f(x)が、種々のスケールと位置を有するウェーブレット関数ψa,b(x)の総和に分解されることを示している。 In Expressions (23) to (25), a represents the scale of the wavelet function, and b represents the position of the wavelet function. As illustrated in FIG. 23, the larger the value of the scale a, the smaller the frequency of the wavelet function ψ a, b (x), and the position at which the wavelet function ψ a, b (x) oscillates moves according to the value of the position b. To do. Therefore, equation (25) indicates that the input signal f (x) is decomposed into a sum of wavelet functions ψ a, b (x) having various scales and positions.
〈二項ウェーブレット変換〉
次に、ウェーブレット変換の一つである二項ウェーブレット変換について説明する。二項ウェーブレット変換については、S. Mallat、W.L. Hwang著"Singularity detection and processing with the wavelets"IEEE Trans. Inform. Theory、1992年、38、p.617や、S.Mallat、S.Zhong著"Characterization of signals from multiscale edges"IEEE Trans. Pattern Anal. Machine Intel. 14 710 (1992)、S.Mallat著"A wavelet tour of signal processing 2ed." Academic Press に詳細な説明がある。
<Binary wavelet transform>
Next, binary wavelet transformation, which is one of wavelet transformations, will be described. The binomial wavelet transform is described in S. Mallat, WL Hwang, “Singularity detection and processing with the wavelets” IEEE Trans. Inform. Theory, 1992, 38, p. 617, S.Mallat, S.Zhong, "Characterization of signals from multiscale edges" IEEE Trans. Pattern Anal. Machine Intel. 14 710 (1992), S. Mallat, "A wavelet tour of signal processing 2ed." Academic Press There is a detailed explanation.
二項ウェーブレット変換で用いられるウェーブレット関数は、式(26)のように定義される。
入力信号f(x)を、式(26)のウェーブレット関数ψi,j(x)を用いて表すと、下記の式(27)のようになる。
レベルi―1の低周波帯域成分Si-1は、式(28)に示すように、レベルiの高周波帯域成分Wiと低周波帯域成分Siに信号分解される。
二項ウェーブレット変換のウェーブレット関数は、式(26)に示すように、レベルiに関わらず、位置bの最小移動単位が一定であることから、二項ウェーブレット関数は、下記の特徴を有する。 The wavelet function of the binomial wavelet transform has the following characteristics because the minimum moving unit of the position b is constant regardless of the level i as shown in the equation (26).
二項ウェーブレット変換の第一の特徴として、式(28)に示す1レベルの二項ウェーブレット変換で生成される、高周波帯域成分Wiと低周波帯域成分Siの各々の信号量は、変換前の信号Si-1と同一である。 As a first feature of the binomial wavelet transform, each signal amount of the high frequency band component W i and the low frequency band component S i generated by the one-level binomial wavelet transform shown in Expression (28) This is the same as the signal S i-1 .
二項ウェーブレット変換の第二の特徴として、スケーリング関数φi,j(x)とウェーブレット関数ψi,j(x)との間に、下記の関係式(29)が成立する。
二項ウェーブレット変換の第三の特徴として、ウェーブレット変換のレベルiに応じて定められた係数γi(上述の二項ウェーブレットに関する参考文献を参照)を高周波帯域成分に乗じたWi・γi(以下、これを補正済高周波帯域成分と称す)について、入力信号の信号変化の特異性(singularity)に応じて、該変換後の補正済高周波帯域成分Wi・γiの信号強度のレベル間の関係が一定の法則に従う。 As a third feature of the binomial wavelet transform, W i · γ i (which is obtained by multiplying a high frequency band component by a coefficient γ i (see the above-mentioned reference on the binomial wavelet) determined according to the level i of the wavelet transform. Hereinafter, this is referred to as a corrected high-frequency band component), depending on the singularity of the signal change of the input signal, between the signal intensity levels of the corrected high-frequency band component W i · γ i after the conversion. The relationship follows a certain law.
図24に、入力信号S0の波形と、ウェーブレット変換により得られる各レベルの補正済高周波帯域成分の波形を示す。図24において、(a)は入力信号S0を示し、(b)はレベル1の二項ウェーブレット変換により得られる補正済高周波帯域成分W1・γ1を示し、(c)はレベル2の二項ウェーブレット変換により得られる補正済高周波帯域成分W2・γ2を示し、(d)はレベル3の二項ウェーブレット変換により得られる補正済高周波帯域成分W3・γ3を示し、(e)はレベル4の二項ウェーブレット変換により得られる補正済高周波帯域成分W・γ4を示す。
FIG. 24 shows the waveform of the input signal S 0 and the waveform of the corrected high-frequency band component at each level obtained by the wavelet transform. In FIG. 24, (a) shows the input signal S 0 , (b) shows the corrected high frequency band component W 1 · γ 1 obtained by the
各レベルにおける信号強度の変化を見ると、(a)において、"1"や"4"に示すなだらかな(微分可能な)信号変化に対応する補正済高周波帯域成分Wi・γiは、(b)→(e)に示すようにレベル数iが増大するほど信号強度が増大する。 Looking at the change in signal intensity at each level, in (a), the corrected high-frequency band component W i · γ i corresponding to the gentle (differentiable) signal change indicated by “1” or “4” is ( As shown in (b) → (e), the signal intensity increases as the number of levels i increases.
入力信号S0において、"2"に示すステップ状の信号変化に対応する補正済高周波帯域成分Wi・γiは、レベル数iに関わらず信号強度が一定となる。入力信号S0において、"3"に示すδ関数状の信号変化に対応する補正済高周波帯域成分Wi・γiは、(b)→(e)に示すように、レベル数iが増大するほど信号強度が減少する。 In the input signal S 0 , the corrected high frequency band component W i · γ i corresponding to the step-like signal change indicated by “2” has a constant signal intensity regardless of the number of levels i. In the input signal S 0 , the corrected high frequency band component W i · γ i corresponding to the signal change of the δ function indicated by “3” increases the number of levels i as shown in (b) → (e). As the signal intensity decreases.
二項ウェーブレット変換における第四の特徴として、画像信号のような2次元信号における1レベルの二項ウェーブレット変換の方法は、以下の図25に示す方法で行われる。 As a fourth feature of the binomial wavelet transform, a one-level binomial wavelet transform method for a two-dimensional signal such as an image signal is performed by the method shown in FIG. 25 below.
図25に示すように、1レベルの二項ウェーブレット変換により、入力信号Sn-1を、x方向のローパスフィルタLPFx及びy方向のローパスフィルタLPFyで処理することにより、低周波帯域成分Snが得られる。また、入力信号Sn-1を、x方向のハイパスフィルタHPFxで処理することにより、高周波帯域成分Wxnが得られる。更に、入力信号Sn-1を、y方向のハイパスフィルタHPFyで処理することにより、もう一つの高周波帯域成分Wynが得られる。 As shown in FIG. 25, the 1-level dyadic wavelet transform, the input signal S n-1, by treatment with x-direction low pass filter LPFx and y directions of the low-pass filter LPFy, a low frequency band component S n can get. Further, by processing the input signal S n-1 with the high-pass filter HPFx in the x direction, a high frequency band component Wx n is obtained. Furthermore, another high frequency band component Wy n can be obtained by processing the input signal S n-1 by the high-pass filter HPFy in the y direction.
このように、1レベルの二項ウェーブレット変換により、入力信号Sn-1は、2つの高周波帯域成分Wxn、Wynと、1つの低周波帯域成分Snに分解される。2つの高周波帯域成分Wxn、Wynは、低周波帯域成分Snの2次元における変化ベクトルVnのx成分とy成分に相当する。変化ベクトルVnの大きさMnと偏角Anは式(28)及び式(29)で与えられる。
また二項ウェーブレット変換で得られた2つの高周波帯域成分Wxn、Wynと1つの低周波帯域成分Snに、図26に示す二項ウェーブレット逆変換を施すことにより、変換前の信号Sn-1を再構成することができる。すなわち、Snをx方向のローパスフィルタLPFx及びy方向のローパスフィルタLPFyで処理することにより得られる信号と、Wxnをx方向のハイパスフィルタHPFx及びy方向のローパスフィルタLPFyで処理することにより得られる信号と、Wynをx方向のローパスフィルタLPFx及びy方向のハイパスフィルタHPFyで処理することにより得られる信号と、を加算することによって、二項ウェーブレット変換前の信号Sn-1を得ることができる。 The two high frequency band components Wx n obtained in dyadic wavelet transform, the Wy n and one low frequency band component S n, by applying a Dyadic Wavelet inverse transform shown in Figure 26, the pre-conversion signal S n -1 can be reconstructed. In other words, obtained by treating the S n and a signal obtained by processing in the low pass filter LPFy pass filter LPFx and y direction of the x-direction, the Wx n in x direction of the high-pass filter HPFx and y directions of the low-pass filter LPFy And a signal S n−1 before binomial wavelet transform is obtained by adding the signal obtained by processing Wy n with the low-pass filter LPFx in the x direction and the high-pass filter HPFy in the y direction. Can do.
以上説明した二項ウェーブレット変換を用いるノイズ増加量の評価は、具体的には、先ず、仮階調補正後の撮影画像データに対して2レベルの二項ウェーブレット変換を施し、第1レベルの高周波信号と第2レベルの高周波信号とを比較する。第1レベルの信号強度よりも第2レベルの信号強度が低い画素をノイズ画素として特定する。つまり、図24の“3”のケースをノイズ画素として特定する。そして、特定されたノイズ画素に対して、仮階調補正後の第1レベル高周波信号強度と、撮影画像データに二項ウェーブレット変換を行った第1レベルの高周波信号強度とを比較することでノイズの増加量を評価することができる。 Specifically, the evaluation of the noise increase amount using the binomial wavelet transform described above is performed by first applying the two-level binomial wavelet transform to the captured image data after the provisional gradation correction to obtain the first-level high-frequency. The signal and the second level high frequency signal are compared. A pixel having a second level signal strength lower than the first level signal strength is identified as a noise pixel. That is, the case “3” in FIG. 24 is specified as a noise pixel. Then, the noise level of the identified noise pixel is compared by comparing the first level high frequency signal intensity after provisional tone correction with the first level high frequency signal intensity obtained by performing binomial wavelet transform on the captured image data. The amount of increase can be evaluated.
そして、図6において、階調補正量決定部733により、ステップS5で評価されたノイズ増加量が大きいか否か(予め設定された所定の閾値以上であるか否か)が判別される(ステップS6)。
In FIG. 6, the gradation correction
ノイズの増加量が閾値以上である場合(ステップS6;YES)、階調補正量決定部733により、ノイズの増加量に基づいて、ステップS3で仮決定された階調補正量が修正され、その修正後の階調補正量が正式なものとして決定される(ステップS7)。具体的には、階調補正量を減少させる。
When the amount of increase in noise is equal to or greater than the threshold (step S6; YES), the gradation correction
そして、画像処理実行部760により、決定された階調補正方法及びその階調補正量に基づいて、撮影画像データに階調補正処理が施される(ステップS8)。ノイズの増加量が閾値未満である場合(ステップS6;NO)、ステップS3で仮決定された階調補正量が正式なものとして決定され、ステップS8に移行される。そして、画像処理実行部760により、階調補正後の画像データに、階調補正以外の画像処理が施され(ステップS9)、画像処理が終了する。
Then, the image
画像処理が施された画像データは、CRT固有処理部706、プリント固有処理部707,708、画像データ書式作成処理部709を介して、CRT8、露光処理部4、外部プリンタ51、画像搬送部31、通信手段(出力)33に出力される。
The image data subjected to the image processing is sent to the
以上、本実施の形態によれば、撮影画像データのシーン判別の結果により階調補正方法を決定し、その階調補正量を仮決定し、決定した階調補正方法と仮決定した階調補正量とに基づいて階調補正した撮影画像データのノイズ増加量に基づいて階調補正量を決定(調整)し、その決定した階調補正方法及び階調補正量で画像データを階調補正するので、ノイズが目立ってしまうことなく、適正に撮影画像データを階調補正できる。例えば、アンダーシーン等の撮影画像データについて、シーン判別の結果により自動的に画像を明るくする様に階調補正する場合にも、ノイズ増加量に基づく階調補正条件の調整及びその階調補正により、シャドー部にノイズが目立ってしまうことなく、適正な撮影画像データを得ることができる。 As described above, according to the present embodiment, the gradation correction method is determined based on the scene discrimination result of the captured image data, the gradation correction amount is provisionally determined, and the gradation correction method and the provisionally determined gradation correction are determined. The gradation correction amount is determined (adjusted) based on the noise increase amount of the captured image data subjected to the gradation correction based on the amount, and the image data is subjected to gradation correction with the determined gradation correction method and the gradation correction amount. Therefore, it is possible to properly correct the gradation of the captured image data without making noise conspicuous. For example, even when tone correction is performed on captured image data such as an underscene so that the image is automatically brightened according to the result of scene discrimination, adjustment of tone correction conditions based on the amount of noise increase and tone correction thereof Appropriate photographed image data can be obtained without making noise conspicuous in the shadow portion.
また、撮影画像データの撮影シーンを定量的に示す第1、第2、第3及び第4の指標a1,a2,a3,a4を算出し、それらの指標に基づいて撮影画像データの撮影シーンを決定するので、撮影画像データの撮影シーンを正確に特定することができる。 Also, first, second, third, and fourth indices a1, a2, a3, and a4 that quantitatively indicate the photographing scene of the photographed image data are calculated, and the photographing scene of the photographed image data is calculated based on these indices. Therefore, the shooting scene of the shot image data can be specified accurately.
(変形例)
上記実施の形態の変形例を説明する。図27に、画像調整処理部701Aの内部構成を示す。本変形例の装置構成は、第1の実施の形態の画像処理装置1における画像調整処理部701を、図27に示す画像調整処理部701Aに代えたものである。画像調整処理部701Aは、画像縮小部760、シーン判別部710A、階調補正条件決定部730A、画像処理実行部740A、ノイズ評価部750Aにより構成される。また、階調補正条件決定部730Aは、階調補正方法決定部731A、階調補正パラメータ算出部732A、階調補正量決定部733Aにより構成される。
(Modification)
A modification of the above embodiment will be described. FIG. 27 shows an internal configuration of the image
画像縮小部760は、第1の画像データ(元画像データ)としての撮影画像データを縮小して第2の画像データとしての縮小画像データに変換する。画像サイズを縮小する方法としては、公知の方法を用いることができる。公知の画像サイズ縮小方法としては、バイリニア法、バイキュービック法、ニアレストネーバー法等がある。縮小率としては特に限定はないが、処理速度の観点とシーン判別工程の精度の観点で、1/2〜1/10程度が好ましい。
The
シーン判別部710A、階調補正条件決定部730Aは、第1の実施の形態のシーン判別部710、階調補正条件決定部730と同様であるが、撮影画像データでなく、画像縮小部760により出力された縮小画像データについて各種処理を行う。また、画像処理実行部760Aは、縮小画像データに対応して決定された階調補正方法及び仮決定された階調補正量に基づいて、撮影画像データに階調補正処理を施す。ノイズ評価部750Aは、その階調補正された撮影画像データのノイズ評価を行う。さらに、画像処理実行部760Aは、ノイズ評価の結果に対応して階調補正量決定部733Aにより決定された階調補正量及び前記階調補正方法に基づいて、撮影画像データに階調補正処理を施し、さらにその他の画像処理を施す。本変形例では、図6の画像処理において、ステップS1の次に、画像縮小部760により撮影画像データが縮小されて縮小画像データにされ、ステップS3において、縮小画像データに対して処理がなされ、ステップS4〜S9において、撮影画像データに対して各種処理がなされる。
The
以上、本変形例によれば、上記実施の形態の効果とともに、縮小画像データを用いて、シーン判別の処理を行うことによりシーン判別の計算量及び計算時間を低減できる。 As described above, according to the present modification, in addition to the effects of the above-described embodiment, the scene discrimination calculation amount and calculation time can be reduced by performing the scene discrimination process using the reduced image data.
なお、上記実施の形態及びその変形例における記述は、本発明に係る画像処理方法、画像処理装置及び画像処理プログラムの一例を示すものであるが、これに限定されるものではなく、本発明の主旨を逸脱しない範囲で適宜変更可能である。 Note that the descriptions in the above-described embodiment and the modifications thereof show examples of the image processing method, the image processing apparatus, and the image processing program according to the present invention, but the present invention is not limited to this. Changes can be made as appropriate without departing from the spirit of the invention.
例えば、図19(a),(b)、図22では、階調補正曲線の始点、終点(収束点)を、それぞれ、画像データ値のmin値、max値に設定したような階調補正曲線を用いて説明したが、これに限定されるものではない。例えば、図28に示すように、階調補正曲線の始点、終点を、それぞれ、画像データ値のmin値、max値の外側に設定したような階調補正曲線を用いる構成としてもよい。この構成では、階調補正によりmin値、max値付近の画素が多くなることを防ぐことができる。 For example, in FIGS. 19A, 19B, and 22, the tone correction curves in which the start point and end point (convergence point) of the tone correction curve are set to the min value and the max value of the image data value, respectively. However, the present invention is not limited to this. For example, as shown in FIG. 28, a gradation correction curve may be used in which the start point and end point of the gradation correction curve are set outside the min value and the max value of the image data value, respectively. In this configuration, it is possible to prevent an increase in the number of pixels near the min value and the max value due to the gradation correction.
また、上記実施の形態におけるシーン判別処理において、少なくとも撮影画像データの画面中央部における肌色の平均輝度に、第3の係数を乗算することにより第3の指標a3を算出する構成としてもよい。また、同様にシーン判別処理において、第1〜第3の指標a1〜a3に基づいて、撮影シーンを判別するための新たな指標を算出し、その新たな指標に基づいてシーン判別する構成としてもよい。 In the scene determination process in the above embodiment, the third index a3 may be calculated by multiplying the average luminance of the skin color at least in the center of the screen of the captured image data by the third coefficient. Similarly, in the scene determination process, a new index for determining a shooting scene is calculated based on the first to third indexes a1 to a3, and the scene is determined based on the new index. Good.
1 画像処理装置
2 筐体
3 マガジン装填部
4 露光処理部
5 プリント作成部
6 トレー
7 制御部
70 画像処理部
701,701A 画像調整処理部
710,710A シーン判別部
712 割合算出部
713 指標算出部
720 第1指標算出部
721 第2指標算出部
722 第3指標算出部
714 シーン判別実行部
715 表色系変換部
716 ヒストグラム作成部
717 占有率演算部
718 第1占有率演算部
719 第2占有率演算部
730,730A 階調補正条件決定部
731,731A 階調補正方法決定部
732,732A 階調補正パラメータ算出部
733,733A 階調補正量決定部
740,740A 画像処理実行部
750,750A ノイズ評価部
760 画像縮小部
702 フィルムスキャンデータ処理部
703 反射原稿スキャンデータ処理部
704 画像データ書式解読処理部
705 画像調整処理部
706 CRT固有処理部
707,708 プリント固有処理部
709 画像データ書式作成処理部
71 データ蓄積手段
8 CRT
9 フィルムスキャナ部
10 反射原稿入力装置
11 操作部
12 情報入力手段
13a カード
13b FD
14 画像読込部
14a PCカード用アダプタ
14b FD用アダプタ
15 画像書込部
15a FD用アダプタ
15b MO用アダプタ
15c 光ディスク用アダプタ
16a FD
16b MO
16c 光ディスク
30 画像転送手段
31 画像搬送部
32 通信手段(入力)
33 通信手段(出力)
34 外部プリンタ
DESCRIPTION OF
9
14
16b MO
33 Communication means (output)
34 External printer
Claims (18)
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価する工程と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整工程と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正工程と、
を含むことを特徴とする画像処理方法。 A scene discriminating step for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
Evaluating the amount of noise increase when the gradation correction condition is applied to the image data;
A gradation correction condition adjusting step of adjusting the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction step of applying a gradation correction process to the image data using the adjusted gradation correction condition;
An image processing method comprising:
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出工程と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出工程と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出工程と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出工程と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別する工程と、を含むことを特徴とする請求項1に記載の画像処理方法。 The scene discrimination step includes
A first occupancy ratio calculating step of dividing the image data into areas each including a combination of predetermined brightness and hue, and calculating a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy calculation process;
A second index calculating step of calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating step of calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
The image processing method according to claim 1, further comprising: determining a shooting scene of the image data based on the calculated first, second, third, and fourth indices.
前記階調補正条件調整工程は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正工程は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする請求項1又は2に記載の画像処理方法。 The gradation correction condition determination step determines a gradation correction method and a gradation correction amount as gradation correction conditions,
The gradation correction condition adjustment step adjusts the determined gradation correction amount based on the noise increase amount,
The gradation correction process performs gradation correction processing on the image data by using the determined gradation correction method and the adjusted gradation correction amount. Image processing method.
前記第2の画像データから画像の撮影シーンを判別するシーン判別工程と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価する工程と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整工程と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正工程と、
を含むことを特徴とする画像処理方法。 Obtaining second image data with a reduced image size from first image data composed of signals of a plurality of pixels;
A scene discriminating step for discriminating a photographing scene of the image from the second image data;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
Evaluating a noise increase amount when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment step of adjusting the gradation correction condition based on the noise increase amount;
A gradation correction step of applying a gradation correction process to the first image data using the adjusted gradation correction condition;
An image processing method comprising:
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出工程と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出工程と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出工程と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出工程と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別する工程と、を含むことを特徴とする請求項4に記載の画像処理方法。 The scene discrimination step includes
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. Rate calculation process;
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy calculation process;
A second index calculating step of calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating step of calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
The method according to claim 4, further comprising: determining a shooting scene of the second image data based on the calculated first, second, third, and fourth indices. Processing method.
前記階調補正条件調整工程は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正工程は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする請求項4又は5に記載の画像処理方法。 The gradation correction condition determination step determines a gradation correction method and a gradation correction amount as gradation correction conditions,
The gradation correction condition adjustment step adjusts the gradation correction amount based on the noise increase amount,
The gradation correction step performs gradation correction processing on the first image data using the determined gradation correction method and the adjusted gradation correction amount. 6. The image processing method according to 5.
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定部と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価するノイズ評価部と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整部と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正部と、
を備えることを特徴とする画像処理装置。 A scene discriminating unit for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determination unit that determines gradation correction conditions based on the result of the scene determination;
A noise evaluation unit that evaluates a noise increase amount when the gradation correction condition is applied to the image data;
A gradation correction condition adjusting unit that adjusts the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction unit that performs a gradation correction process on the image data using the adjusted gradation correction condition;
An image processing apparatus comprising:
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出部と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出部と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出部と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出部と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出部と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別するシーン判別実行部と、を備えることを特徴とする請求項7に記載の画像処理装置。 The scene discrimination unit
A first occupancy ratio calculation unit that divides the image data into areas each including a combination of predetermined brightness and hue, and calculates a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculation unit for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy rate calculator,
A second index calculating unit that calculates a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating unit that calculates a fourth index by multiplying an average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
The image according to claim 7, further comprising: a scene determination execution unit that determines a shooting scene of the image data based on the calculated first, second, third, and fourth indices. Processing equipment.
前記階調補正条件調整部は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正部は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする請求項7又は8に記載の画像処理装置。 The gradation correction condition determining unit determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment unit adjusts the determined gradation correction amount based on the noise increase amount,
9. The gradation correction unit according to claim 7, wherein the gradation correction unit performs a gradation correction process on the image data using the determined gradation correction method and the adjusted gradation correction amount. Image processing apparatus.
前記第2の画像データから画像の撮影シーンを判別するシーン判別部と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定部と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価するノイズ評価部と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整部と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正部と、
を備えることを特徴とする画像処理装置。 An image reduction unit for obtaining second image data obtained by reducing the image size from the first image data including signals of a plurality of pixels;
A scene discriminating unit for discriminating a photographing scene of the image from the second image data;
A gradation correction condition determination unit that determines gradation correction conditions based on the result of the scene determination;
A noise evaluation unit that evaluates a noise increase amount when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment unit that adjusts the gradation correction condition based on the noise increase amount;
A gradation correction unit that performs a gradation correction process on the first image data using the adjusted gradation correction condition;
An image processing apparatus comprising:
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出部と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出工程と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出部と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出部と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出部と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別するシーン判別実行部と、を備えることを特徴とする請求項10に記載の画像処理装置。 The scene discrimination unit
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. A rate calculator,
A first index calculating step of calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance, respectively;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 occupancy rate calculator,
A second index calculating unit that calculates a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculating unit that calculates a fourth index by multiplying an average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
11. A scene discrimination execution unit that discriminates a shooting scene of the second image data based on the calculated first, second, third, and fourth indices. The image processing apparatus described.
前記階調補正条件調整部は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正部は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする請求項10又は11に記載の画像処理装置。 The gradation correction condition determining unit determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment unit adjusts the gradation correction amount based on the noise increase amount,
11. The gradation correction unit performs gradation correction processing on the first image data using the determined gradation correction method and the adjusted gradation correction amount. The image processing apparatus according to 11.
複数画素の信号からなる画像データから画像の撮影シーンを判別するシーン判別機能と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定工程と、
前記階調補正条件を前記画像データに適用した際のノイズ増加量を評価する機能と、
前記評価されたノイズ増加量に基づいて、前記決定された階調補正条件を調整する階調補正条件調整機能と、
前記調整された階調補正条件を用いて、前記画像データに階調補正処理を施す階調補正機能と、
を実現させるための画像処理プログラム。 On the computer,
A scene discrimination function for discriminating a shooting scene of an image from image data composed of signals of a plurality of pixels;
A gradation correction condition determining step for determining a gradation correction condition based on the result of the scene determination;
A function of evaluating the amount of noise increase when the gradation correction condition is applied to the image data;
A gradation correction condition adjustment function for adjusting the determined gradation correction condition based on the evaluated noise increase amount;
A gradation correction function for performing a gradation correction process on the image data using the adjusted gradation correction condition;
An image processing program for realizing
前記画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出機能と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出機能と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出機能と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出機能と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出機能と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記画像データの撮影シーンを判別する機能と、を有することを特徴とする請求項13に記載の画像処理プログラム。 The scene discrimination function is
A first occupancy ratio calculation function that divides the image data into areas each including a combination of predetermined brightness and hue, and calculates a first occupancy ratio indicating a ratio of the entire image data for each of the divided areas. When,
A first index calculation function for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 Occupancy rate calculation function,
A second index calculation function for calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculation function for calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
The image processing program according to claim 13, further comprising: a function of determining a shooting scene of the image data based on the calculated first, second, third, and fourth indices.
前記階調補正条件調整機能は、前記ノイズ増加量に基づいて、前記決定された階調補正量を調整し、
前記階調補正機能は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記画像データに階調補正処理を施すことを特徴とする請求項13又は14に記載の画像処理プログラム。 The gradation correction condition determination function determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment function adjusts the determined gradation correction amount based on the noise increase amount,
The gradation correction function performs gradation correction processing on the image data using the determined gradation correction method and the adjusted gradation correction amount. Image processing program.
複数画素の信号からなる第1の画像データから、画像サイズを縮小した第2の画像データを取得する機能と、
前記第2の画像データから画像の撮影シーンを判別するシーン判別機能と、
前記シーン判別の結果に基づき階調補正条件を決定する階調補正条件決定機能と、
前記階調補正条件を前記第1の画像データに適用した際のノイズ増加量を評価する機能と、
前記ノイズ増加量に基づいて、前記階調補正条件を調整する階調補正条件調整機能と、
前記調整された階調補正条件を用いて、前記第1の画像データに階調補正処理を施す階調補正機能と、
を実現させるための画像処理プログラム。 On the computer,
A function of acquiring second image data obtained by reducing the image size from the first image data including signals of a plurality of pixels;
A scene discrimination function for discriminating a shooting scene of an image from the second image data;
A gradation correction condition determination function for determining a gradation correction condition based on the result of the scene determination;
A function of evaluating an amount of increase in noise when the gradation correction condition is applied to the first image data;
A gradation correction condition adjustment function for adjusting the gradation correction condition based on the noise increase amount;
A gradation correction function for applying a gradation correction process to the first image data using the adjusted gradation correction condition;
An image processing program for realizing
前記第2の画像データを所定の明度と色相との組み合わせからなる領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第1の占有率を算出する第1占有率算出機能と、
前記第1の占有率に、予め設定された異なる第1及び第2の係数をそれぞれ乗算することにより、第1及び第2の指標を算出する第1指標算出機能と、
前記画像データの画面の外縁からの距離と明度との組み合わせからなる所定の領域に分割し、当該分割された領域毎に、前記画像データ全体に占める割合を示す第2の占有率を算出する第2占有率算出機能と、
前記第2の占有率に、予め設定された第3の係数を乗算することにより、第3の指標を算出する第2指標算出機能と、
少なくとも前記画像データの画面中央部における肌色の平均輝度に、予め設定された第4の係数を乗算することにより、第4の指標を算出する第3指標算出機能と、
前記算出された第1、第2、第3及び第4の指標に基づいて、前記第2の画像データの撮影シーンを判別する機能と、を有することを特徴とする請求項16に記載の画像処理プログラム。 The scene discrimination function is
Dividing the second image data into regions each having a combination of predetermined brightness and hue, and calculating a first occupancy ratio that indicates a proportion of the entire image data for each of the divided regions. Rate calculation function,
A first index calculation function for calculating the first and second indices by multiplying the first occupancy by different first and second coefficients set in advance;
The image data is divided into a predetermined area composed of a combination of the distance from the outer edge of the screen and the brightness, and a second occupancy ratio indicating the ratio of the image data to the entire image data is calculated for each of the divided areas. 2 Occupancy rate calculation function,
A second index calculation function for calculating a third index by multiplying the second occupancy by a preset third coefficient;
A third index calculation function for calculating a fourth index by multiplying the average brightness of the skin color at least in the center of the screen of the image data by a preset fourth coefficient;
17. The image according to claim 16, further comprising: a function of determining a shooting scene of the second image data based on the calculated first, second, third, and fourth indices. Processing program.
前記階調補正条件調整機能は、前記ノイズ増加量に基づいて、前記階調補正量を調整し、
前記階調補正機能は、前記決定された階調補正方法及び前記調整された階調補正量を用いて、前記第1の画像データに階調補正処理を施すことを特徴とする請求項16又は17に記載の画像処理プログラム。 The gradation correction condition determination function determines a gradation correction method and a gradation correction amount as a gradation correction condition,
The gradation correction condition adjustment function adjusts the gradation correction amount based on the noise increase amount,
The gradation correction function performs gradation correction processing on the first image data using the determined gradation correction method and the adjusted gradation correction amount. The image processing program according to 17.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004275576A JP2006094000A (en) | 2004-09-22 | 2004-09-22 | Image processing method, image processing apparatus, and image processing program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004275576A JP2006094000A (en) | 2004-09-22 | 2004-09-22 | Image processing method, image processing apparatus, and image processing program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2006094000A true JP2006094000A (en) | 2006-04-06 |
Family
ID=36234565
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2004275576A Pending JP2006094000A (en) | 2004-09-22 | 2004-09-22 | Image processing method, image processing apparatus, and image processing program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2006094000A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2006120839A1 (en) * | 2005-05-13 | 2006-11-16 | Konica Minolta Photo Imaging, Inc. | Image processing method, image processing device, and image processing program |
JP2007288245A (en) * | 2006-04-12 | 2007-11-01 | Konica Minolta Photo Imaging Inc | Imaging apparatus, image processing method, and image processing program |
JP2007293528A (en) * | 2006-04-24 | 2007-11-08 | Konica Minolta Photo Imaging Inc | Imaging device, image processing device, image processing method and image processing program |
JP2010062911A (en) * | 2008-09-04 | 2010-03-18 | Canon Inc | Image processing apparatus, image processing method, and program |
CN114612345A (en) * | 2022-04-01 | 2022-06-10 | 江苏通纺互联科技有限公司 | Light source detection method based on image processing |
CN114757853A (en) * | 2022-06-13 | 2022-07-15 | 武汉精立电子技术有限公司 | Flat field correction function acquisition method and system and flat field correction method and system |
-
2004
- 2004-09-22 JP JP2004275576A patent/JP2006094000A/en active Pending
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2006120839A1 (en) * | 2005-05-13 | 2006-11-16 | Konica Minolta Photo Imaging, Inc. | Image processing method, image processing device, and image processing program |
US8170364B2 (en) | 2005-05-13 | 2012-05-01 | Konica Minolta Opto, Inc. | Image processing method, image processing device, and image processing program |
JP2007288245A (en) * | 2006-04-12 | 2007-11-01 | Konica Minolta Photo Imaging Inc | Imaging apparatus, image processing method, and image processing program |
JP2007293528A (en) * | 2006-04-24 | 2007-11-08 | Konica Minolta Photo Imaging Inc | Imaging device, image processing device, image processing method and image processing program |
JP2010062911A (en) * | 2008-09-04 | 2010-03-18 | Canon Inc | Image processing apparatus, image processing method, and program |
US8515177B2 (en) | 2008-09-04 | 2013-08-20 | Canon Kabushiki Kaisha | Image processing apparatus, image processing method, and program |
CN114612345A (en) * | 2022-04-01 | 2022-06-10 | 江苏通纺互联科技有限公司 | Light source detection method based on image processing |
CN114757853A (en) * | 2022-06-13 | 2022-07-15 | 武汉精立电子技术有限公司 | Flat field correction function acquisition method and system and flat field correction method and system |
CN114757853B (en) * | 2022-06-13 | 2022-09-09 | 武汉精立电子技术有限公司 | Method and system for acquiring flat field correction function and flat field correction method and system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP2006319714A (en) | Method, apparatus, and program for processing image | |
US8165402B2 (en) | Image processing method, image processing apparatus, image forming apparatus and storage medium | |
US7260266B2 (en) | Image processing method, image processing apparatus, image processing program and image recording apparatus | |
JP2005190435A (en) | Image processing method, image processing apparatus and image recording apparatus | |
WO2006123492A1 (en) | Image processing method, image processing device, imaging device and image processing program | |
JP2002300402A (en) | Image processor, processing method and recording medium | |
JPWO2005112428A1 (en) | Image processing method, image processing apparatus, image recording apparatus, and image processing program | |
US8073251B2 (en) | Image processing apparatus and method including page-background process capability, and non-transitory computer readable storage medium for causing computer to function as the same | |
JP2006318255A (en) | Image processing method, image processor and image processing program | |
JP2006094000A (en) | Image processing method, image processing apparatus, and image processing program | |
WO2006033235A1 (en) | Image processing method, image processing device, imaging device, and image processing program | |
US20040036892A1 (en) | Image processing method, image processing apparatus, image recording apparatus and recording medium | |
JP7382834B2 (en) | Image processing device, image processing method, and program | |
JP2006039666A (en) | Image processing method, image processor and image processing program | |
JP2007312125A (en) | Image processor, image processing method, and image processing program | |
WO2006033236A1 (en) | Image processing method, image processing device, imaging device, and image processing program | |
JP4449619B2 (en) | Image processing method, image processing apparatus, and image processing program | |
JP2006092168A (en) | Image processing method, image processor and picture processing program | |
JP2004297617A (en) | Image processing device, image forming device, image processing method, image processing program, and computer readable recording medium recorded with image processing program | |
JP2006203571A (en) | Imaging apparatus, image processing apparatus, and image recording apparatus | |
JP2005332054A (en) | Image processing method, image processor, image recording device and image processing program | |
JP2006203573A (en) | Imaging apparatus, image processor, and image recording apparatus | |
WO2006033234A1 (en) | Image processing method, image processing device, imaging device, and image processing program | |
JP2004326325A (en) | Method, device and program for processing image and image recording device | |
JP2006293898A (en) | Image processing method, image processing apparatus, and image processing program |