[go: up one dir, main page]

JP2013161348A - Image correction device, method, program, and recording medium - Google Patents

Image correction device, method, program, and recording medium Download PDF

Info

Publication number
JP2013161348A
JP2013161348A JP2012024131A JP2012024131A JP2013161348A JP 2013161348 A JP2013161348 A JP 2013161348A JP 2012024131 A JP2012024131 A JP 2012024131A JP 2012024131 A JP2012024131 A JP 2012024131A JP 2013161348 A JP2013161348 A JP 2013161348A
Authority
JP
Japan
Prior art keywords
area
color
correction
shine
pixel
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
Application number
JP2012024131A
Other languages
Japanese (ja)
Inventor
Tomoko Sugawara
知子 菅原
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nikon Corp
Original Assignee
Nikon Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nikon Corp filed Critical Nikon Corp
Priority to JP2012024131A priority Critical patent/JP2013161348A/en
Publication of JP2013161348A publication Critical patent/JP2013161348A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Processing (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Image Analysis (AREA)

Abstract

【課題】元の明るさのバランスを維持し立体感を損なうことなくテカリ領域を補正する。
【解決手段】顔検出部は、入力された画像から顔画像領域を検出する。テカリ領域検出部は、顔画像領域で所定の明るさより明るい領域をテカリ領域として検出する。平均色取得部18は、テカリ領域の周囲の肌の色を平均した平均色を取得する。明るさ分類部19は、テカリ領域内の全画素の明るさを検出して、各画素を明るさに応じて複数のグループに分類する。最明画素検出部21は、テカリ領域の中で補正していない画素のうちの最も明るい画素の色を取得する。補正色決定部22は、平均色とテカリ領域内の最も明るい画素の色との合成比率を補正の回数に応じて変えて補正色を作る。塗りつぶし補正部23は、作成した補正色で画素を明るいグループに属する画素から順に塗りつぶす。
【選択図】図2
The present invention corrects a shine area without losing the stereoscopic effect while maintaining the original brightness balance.
A face detection unit detects a face image region from an input image. The shine area detection unit detects an area brighter than a predetermined brightness in the face image area as a shine area. The average color acquisition unit 18 acquires an average color obtained by averaging the skin colors around the shine area. The brightness classification unit 19 detects the brightness of all the pixels in the shine area, and classifies each pixel into a plurality of groups according to the brightness. The brightest pixel detection unit 21 acquires the color of the brightest pixel among the pixels not corrected in the shine area. The correction color determination unit 22 creates a correction color by changing the synthesis ratio of the average color and the color of the brightest pixel in the shine area according to the number of corrections. The fill correction unit 23 paints pixels in order from the pixels belonging to the bright group with the created correction color.
[Selection] Figure 2

Description

本発明は、顔画像のテカリを補正する画像補正装置、方法、及びプログラム、並びに記録媒体に関する。   The present invention relates to an image correction apparatus, a method, a program, and a recording medium for correcting the shine of a face image.

従来、人物が撮像された画像において、いわゆる「テカリ」の発生が問題となっている。テカリとは、写真撮像時に発せられるストロボ等の光が、被写体人物の肌の表面で反射(特に鏡面反射)することにより、肌の一部が白く撮像されてしまうことである。このため、テカリが発生した部位(以下、「テカリ部位」と呼ぶ)は、周囲の肌に比べて高輝度に撮像されてしまう。このようなテカリは、その画像を見る者に対して不快な印象を与える。このため、テカリが発生してしまった画像において、テカリを除去若しくは軽減する技術が要求されている。   Conventionally, the occurrence of so-called “shine” has been a problem in an image in which a person is imaged. The term “shine” means that a part of the skin is imaged white because light such as a strobe emitted at the time of taking a picture is reflected (particularly specularly reflected) on the surface of the skin of the subject person. For this reason, a site where shine occurs (hereinafter referred to as “shine site”) is imaged with higher brightness than the surrounding skin. Such shine gives an unpleasant impression to those who see the image. For this reason, there is a demand for a technique for removing or reducing shine in an image where shine has occurred.

このような要求に対し、従来、オペレータが目視で高輝度の部位を見つけフォトレタッチソフト等を使用することにより手動で高輝度の部位の明るさや輝度を下げることによりテカリを抑制する補正方法が実現されている。   In response to such demands, conventionally, a correction method has been realized that suppresses shine by manually reducing the brightness and brightness of high-brightness parts by manually finding high-brightness parts and using photo retouching software. Has been.

また、画像の中から被写体人物の目が含まれる顔画像領域を検出し、検出された顔画像領域の中からテカリ領域を検出し、テカリ領域内で最大明度を抑制する補正を行う発明が提案されている(特許文献1)。   Further, an invention is proposed in which a face image area including the eyes of a subject person is detected from an image, a shine area is detected from the detected face image area, and correction is performed to suppress the maximum brightness in the shine area. (Patent Document 1).

特開2007−190885号公報JP 2007-190885 A

しかしながら、特許文献1に記載の発明では、最大明度を抑制する補正として、テカリ領域内の画像データをたんに平滑化している。このため、テカリ領域の立体感が損なわれ、テカリ領域の明るさ(輝度)のバランスが変わってしまうおそれがある。   However, in the invention described in Patent Document 1, image data in the shine area is simply smoothed as correction for suppressing the maximum brightness. For this reason, the stereoscopic effect of the shine area may be impaired, and the balance of brightness (luminance) of the shine area may be changed.

本発明は、かかる点に鑑みてなされたものであり、原画通りのテカリの明るさのバランスを維持して立体感を損なうことなく補正するようにした画像補正装置、方法、及びプログラム、並びに記録媒体を提供することを目的とする。   The present invention has been made in view of the above points, and is an image correction apparatus, method, program, and recording that maintain the brightness balance of the shine as in the original image without correcting the stereoscopic effect. The purpose is to provide a medium.

本発明では、入力された画像から顔画像領域を検出する顔検出手段と、顔画像領域で所定の明るさより明るい領域又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出手段と、テカリ領域を最も明るい領域から周囲に向けて周囲の色に徐々に近づくように塗りつぶす補正を行うテカリ補正手段と、を備えたものである。   In the present invention, face detection means for detecting a face image area from an input image, and a shine area detection for detecting, as a shine area, an area brighter than a predetermined brightness in the face image area or an area brighter than a surrounding by a predetermined brightness. And a shine correction means for correcting the shine area so as to gradually approach the surrounding color from the brightest area toward the periphery.

テカリ補正手段としては、テカリ領域を最も明るい領域から周囲に向けて徐々に塗りつぶす補正色を、テカリ領域内の塗りつぶし対象となる画素の色に対して、テカリ領域の周囲の画素の色を平均した平均色を混合する割合を徐々に増やして作成する。   As a shine correction means, the correction color that gradually fills the shine area from the brightest area to the periphery is averaged over the color of the pixels that are the target of filling in the shine area. Create by gradually increasing the ratio of mixing average colors.

具体的には、テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得部と、テカリ領域を画素の明るさに応じて複数のグループに分類する分類部と、前記平均色を塗りつぶし対象となるグループの画素の色に前記平均色の合成比率が徐々に増えるように合成して補正色を作成し作成した補正色で最も明るいグループの画素から順に塗りつぶす補正部と、でテカリ補正手段を構成するのが好適である。   Specifically, an average color acquisition unit that acquires an average color obtained by averaging the colors of pixels around the shine area, a classification unit that classifies the shine area into a plurality of groups according to pixel brightness, and the average color A correction unit that creates a correction color by combining the average pixel color with the color of the pixel of the group to be filled and gradually increases the average color composition ratio. It is preferable to constitute the correcting means.

また、テカリ補正手段としては、テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得部と、テカリ領域のうちの最も明るい画素を検出する最明画素検出部と、前記平均色と塗りつぶし対象となる画素の色とを前記周囲との間の距離が短い画素ほど前記平均色の合成比率が徐々に増えるように合成して補正色を作成し作成した補正色で前記最も明るい画素から周囲の画素に向けて順に画素を塗りつぶす補正部と、で構成してもよい。   Further, as the shine correction means, an average color acquisition unit that acquires an average color obtained by averaging the colors of pixels around the shine area, a brightest pixel detection unit that detects the brightest pixel in the shine area, and the average A correction color is created by combining a color and the color of a pixel to be filled so that the pixel having a shorter distance from the surrounding area gradually increases the composite ratio of the average color. You may comprise by the correction | amendment part which paints a pixel in order toward a surrounding pixel from a pixel.

また、本発明としては、画像補正方法としてもよい。さらに本発明は、画像補正方法を実行させるコンピュータが読み取り可能なプログラム、並びにコンピュータが読み取り可能なプログラムを記録した記録媒体の発明としてもよい。   In the present invention, an image correction method may be used. Furthermore, the present invention may be a computer-readable program for executing the image correction method and a recording medium on which the computer-readable program is recorded.

本発明によれば、テカリ領域を最も明るい領域から周囲に向けて周囲の色に徐々に近づくように塗りつぶすため、テカリ領域を元の明るさのバランスを維持して、立体感を損なうことなく補正することができる。   According to the present invention, the shining area is filled from the brightest area toward the surroundings so as to gradually approach the surrounding colors, so that the shining area is corrected without losing the stereoscopic effect while maintaining the original brightness balance. can do.

本発明の画像補正装置の概略を示すブロック図である。It is a block diagram which shows the outline of the image correction apparatus of this invention. テカリ領域補正部の概略を示すブロック図である。It is a block diagram which shows the outline of a shine area correction | amendment part. 図1で説明した画像補正装置の処理手順を示すフローチャートである。3 is a flowchart illustrating a processing procedure of the image correction apparatus described in FIG. 1. 明るさに応じて分類した複数のグループを示すヒストグラムである。It is a histogram which shows the some group classified according to the brightness. テカリ領域とテカリ領域のうちの複数のグループの領域とを示す説明図である。It is explanatory drawing which shows the area | region of several groups among a shine area and a shine area. 分類数が「5」のときの補正回数に対する合成比率の一例を示す説明図である。It is explanatory drawing which shows an example of the synthetic | combination ratio with respect to the frequency | count of correction | amendment when the number of classification is "5". 塗りつぶす画素に対してテカリ領域の周囲までの距離に応じて合成比率を変える他の例の処理手順を示すフローチャートである。It is a flowchart which shows the process sequence of the other example which changes a composition ratio according to the distance to the circumference | surroundings of a shine area | region with respect to the pixel to fill. テカリ領域のうちの最も明るい画素に隣接する画素とテカリ領域の周囲の画素との最短距離の概略を示す説明図である。It is explanatory drawing which shows the outline of the shortest distance of the pixel adjacent to the brightest pixel of a shine area | region, and the surrounding pixel of a shine area | region. 図7で説明した装置での合成比率の一例を示す説明図である。It is explanatory drawing which shows an example of the synthetic | combination ratio with the apparatus demonstrated in FIG.

本発明の画像補正装置10は、周知のように、バスを介して接続されるCPU、ROM、RAM、記憶部、操作部、及び外部I/F等を備える。記憶部には、各種のプログラム(OS、アプリケーション等)が記憶されており、操作部から起動操作に応答してCPUにロードされ、CPUにより実行されることによって、図1に示すように、画像入力部11、顔検出部12、目・口検出部13、テカリ領域検出部14、テカリ領域補正部15、及び補正画像出力部16等を含む装置として機能する。   As is well known, the image correction apparatus 10 of the present invention includes a CPU, a ROM, a RAM, a storage unit, an operation unit, an external I / F, and the like connected via a bus. Various programs (OS, applications, etc.) are stored in the storage unit, loaded into the CPU in response to the start operation from the operation unit, and executed by the CPU, as shown in FIG. It functions as an apparatus including an input unit 11, a face detection unit 12, an eye / mouth detection unit 13, a shine area detection unit 14, a shine area correction unit 15, a corrected image output unit 16, and the like.

これら顔検出部12、目・口検出部13、テカリ領域検出部14、及びテカリ領域補正部15は、プログラムがCPUによって実行されることにより実現される。なお、顔検出部12、目・口検出部13、テカリ領域検出部14、及びテカリ領域補正部15は、専用のチップに記憶されたものでも良い。   The face detection unit 12, the eye / mouth detection unit 13, the shine area detection unit 14, and the shine area correction unit 15 are realized by executing a program by the CPU. The face detection unit 12, the eye / mouth detection unit 13, the shine area detection unit 14, and the shine area correction unit 15 may be stored in a dedicated chip.

画像入力部11は、原画像のデータを画像補正装置10へ入力するためのインターフェースとして機能する。例えば、記録媒体(例えば電子カメラに内蔵するものも含む各種メモリやフレキシブルディスクやCD(Compact Disk)、DVD(Digital Versatile Disc、Digital Video Disc))に記録された原画像のデータが画像補正装置10へ入力される。この場合、画像入力部11は、記録媒体からデータを読み出す装置(例えばメモリリーダやフレキシブルディスク、CDドライブ、及びDVDドライブ)を用いて構成される。   The image input unit 11 functions as an interface for inputting original image data to the image correction apparatus 10. For example, data of an original image recorded on a recording medium (for example, various memories including those incorporated in an electronic camera, a flexible disk, a CD (Compact Disk), a DVD (Digital Versatile Disc, Digital Video Disc)) is converted into the image correction apparatus 10. Is input. In this case, the image input unit 11 is configured using a device (for example, a memory reader, a flexible disk, a CD drive, and a DVD drive) that reads data from a recording medium.

顔検出部12は、原画像から人の顔画像を含む領域を顔画像領域として検出し、顔画像領域の位置や大きさ等を示す顔画像情報を特定する。顔検出部12は、例えば、顔全体の輪郭に対応した基準テンプレートを用いたテンプレートマッチングによって顔を検出するように構成されている。   The face detection unit 12 detects an area including a human face image from the original image as a face image area, and specifies face image information indicating the position and size of the face image area. The face detection unit 12 is configured to detect a face by template matching using a reference template corresponding to the outline of the entire face, for example.

目・口検出部13は、顔画像領域から目及び口の画像を含む領域を目及び口画像領域として検出し、目及び口画像領域の位置や大きさ等を示す目及び口画像情報を特定する。   The eye / mouth detection unit 13 detects an area including an eye and mouth image area from the face image area as an eye and mouth image area, and identifies eye and mouth image information indicating the position and size of the eye and mouth image area. To do.

テカリ領域検出部14は、顔画像領域のうちの目及び口画像領域を除外した領域の中で著しく明るい部分を、テカリ領域として検出する。著しく明るい部分の検出としては、例えば所定の明るさより明るく写っている領域をテカリ領域として検出すればよい。所定の明るさは、予め設定しておいた固定値としてもよいし、白目の部分や歯の部分の明度を基準として設定することもできる。また、周りの領域よりも明るさが所定以上明るい領域をテカリ領域として検出してもよい。   The shine area detection unit 14 detects, as a shine area, a remarkably bright portion of the face image area excluding the eye and mouth image areas. As a detection of a remarkably bright part, for example, an area that appears brighter than a predetermined brightness may be detected as a shine area. The predetermined brightness may be a fixed value set in advance, or may be set on the basis of the brightness of the white eye part or the tooth part. In addition, an area that is brighter than a surrounding area by a predetermined brightness or more may be detected as a shine area.

テカリ領域補正部15は、テカリ領域を明るい画素から順に、テカリ領域の周囲の肌の色に徐々に近づく色で補正する。補正した画像データは、補正画像出力部16から出力される。ここで、記録部等から読み出した画像データの場合には、上書き保存、又は新たな名前を付けて保存される。   The shining area correction unit 15 corrects the shining area in order from light pixels to a color that gradually approaches the skin color around the shining area. The corrected image data is output from the corrected image output unit 16. Here, in the case of image data read from a recording unit or the like, it is overwritten or saved with a new name.

テカリ領域補正部15は、図2に示すように、平均色取得部18、明るさ分類部19、及び補正部20とで構成されている。平均色取得部18は、テカリ領域の周囲の肌の色を平均した平均色aを取得する。   As shown in FIG. 2, the shine area correction unit 15 includes an average color acquisition unit 18, a brightness classification unit 19, and a correction unit 20. The average color acquisition unit 18 acquires an average color a obtained by averaging the skin colors around the shine area.

明るさ分類部19は、テカリ領域内の全画素の明るさ(輝度)を検出して、各画素を明るさに応じて複数のグループに分類する。明るさの程度は、各画素が表現できる階調に対する数値として表現される。8ビット256階調の場合、各画素の明るさの最小値は「0」、最大値は「255」になる。カラー画像では、R,G,Bの色成分毎に0〜255値を持っている。このRGB値の平均値が各画素における明るさになる。   The brightness classification unit 19 detects the brightness (luminance) of all pixels in the shine area, and classifies each pixel into a plurality of groups according to the brightness. The degree of brightness is expressed as a numerical value for the gradation that can be expressed by each pixel. In the case of 8-bit 256 gradation, the minimum value of the brightness of each pixel is “0” and the maximum value is “255”. The color image has 0 to 255 values for each of the R, G, and B color components. The average value of the RGB values is the brightness at each pixel.

補正部20は、最明画素検出部21、補正色決定部22、及び塗りつぶし補正部23とで構成されており、テカリ領域内を明るい画素から順に、補正の回数に応じて決められる補正色cで塗りつぶしていく。最明画素検出部21は、テカリ領域の中で補正していない画素のうちの最も明るい画素の色bを取得する。補正色決定部22は、前述した平均色aとテカリ領域内の最も明るい画素の色bとの合成比率を補正の回数iに応じて変えて補正色cを作る。合成比率は、[数1]に示す式に基づいて決められる。   The correction unit 20 includes a brightest pixel detection unit 21, a correction color determination unit 22, and a fill correction unit 23, and a correction color c determined according to the number of corrections in order from a bright pixel in the shine area. Fill with. The brightest pixel detection unit 21 acquires the color b of the brightest pixel among the pixels not corrected in the shine area. The correction color determination unit 22 creates a correction color c by changing the composition ratio of the average color a and the color b of the brightest pixel in the shine area according to the number of corrections i. The composition ratio is determined based on the formula shown in [Formula 1].

[数1]
c=a・(i+1)/2・x+b・(i−1)/2・x
[Equation 1]
c = a · (i + 1) / 2 · x + b · (i−1) / 2 · x

[数1]に記載の「c」は補正色(塗りつぶす色)、「a」はテカリ領域の周囲の肌の色を平均した平均色、「b」はテカリ領域内のうちの補正していない画素のうちの最も明るい画素の色、「x」は分類数、「i」は補正の回数である。   “C” described in [Equation 1] is a correction color (filling color), “a” is an average color obtained by averaging skin colors around the shine area, and “b” is not corrected in the shine area. The color of the brightest pixel among the pixels, “x” is the number of classifications, and “i” is the number of corrections.

[数1]に記載の式は、補正の回数iに応じて、その時点で最も明るい画素の色bに対して平均色aを少しずつ混合して補正色cを作る式である。塗りつぶし補正部23は、明るいグループで分類される画素群から順に補正色cで塗りつぶす。   The equation described in [Equation 1] is an equation for making the correction color c by mixing the average color a little by little with the color b of the brightest pixel at that time according to the number of corrections i. The fill correction unit 23 fills with the correction color c in order from the pixel group classified by the bright group.

分類数xは、補正の回数iの最大数と同じである。最初に補正をする時には、補正の回数iに「0」が代入される。ここで、最初に補正するテカリ領域のうちの最も明るい画素の色を「b0」、最初に塗りつぶす(補正する)補正色cを「c0」、次に補正するテカリ領域のうちの補正していない最も明るい画素の色を「b1」、塗りつぶす補正色を「c1」とすると、補正色c1は、2回目の補正である(補正の回数iを「1」として計算する)ため、最初の補正色c0に対して平均色aが少し多く混合されており、かつ明るい画素の色b1も最初の明るい画素の色b0よりも少し暗い色であるため、テカリ領域の周囲の画素の平均色aに近づく色になる。このような作業を分類数xの分だけ繰り返し行うことで、テカリ領域を、光の当たる方向、及びテカリのバランスを変えずに補正することができる。   The classification number x is the same as the maximum number of corrections i. When the correction is performed for the first time, “0” is substituted for the number of corrections i. Here, the color of the brightest pixel in the shining area to be corrected first is “b0”, the correction color c to be filled (corrected) first is “c0”, and the correction in the shining area to be corrected next is not corrected. Assuming that the color of the brightest pixel is “b1” and the correction color to be filled is “c1”, the correction color c1 is the second correction (the number of corrections i is calculated as “1”). Since the average color a is slightly mixed with c0, and the bright pixel color b1 is also slightly darker than the first bright pixel color b0, it approaches the average color a of the surrounding pixels of the shine area. Become a color. By repeating such operations for the number of classifications x, the shine area can be corrected without changing the direction of light and the balance of the shine.

次に、上記構成の作用を、図3を参照しながら説明する。画像入力部11により入力される画像データは、顔検出部12により顔画像領域が検出される(S−1)。顔画像領域が検出されると、目・口検出部13が顔画像領域内から目・口の画像領域を検出する(S−2)。   Next, the operation of the above configuration will be described with reference to FIG. In the image data input by the image input unit 11, a face image region is detected by the face detection unit 12 (S-1). When the face image area is detected, the eye / mouth detection unit 13 detects the eye / mouth image area from within the face image area (S-2).

顔画像領域内に目・口画像領域を検出した場合、テカリ領域検出部14は、顔画像領域のうちの目・口画像領域以外の領域で、所定の明るさより明るく写っている領域をテカリ領域として検出する(S−3)。目・口画像領域を検出していない場合には、顔画像領域で、所定の明るさより明るく写っている領域をテカリ領域として検出する(S−4)。   When the eye / mouth image area is detected in the face image area, the shine area detection unit 14 determines an area that is brighter than a predetermined brightness in the area other than the eye / mouth image area in the face image area. (S-3). When the eye / mouth image area is not detected, an area that is brighter than a predetermined brightness in the face image area is detected as a shine area (S-4).

テカリ領域の補正は、まず、平均色取得部18が、テカリ領域の周り(周辺部)の肌の色、すなわち、図4に示すように、テカリ領域25の境界に隣接する画素26の色の平均色aを取得する(S−5)。   In the correction of the shine area, first, the average color acquisition unit 18 determines the color of the skin around (peripheral area) around the shine area, that is, the color of the pixel 26 adjacent to the boundary of the shine area 25 as shown in FIG. The average color a is acquired (S-5).

その後、明るさ分類部19は、テカリ領域25内の全画素の明るさを調べ、メモリ等の記憶部に一時的に保存する。そして、テカリ領域内の全画素の明るさを予め決めた閾値に基づいて複数のグループに分類する(S−6)。また、取得した画素と直前に取得した画素との明るさを順に比較していき、最も明るい画素の色を検出する(S−7)。   Thereafter, the brightness classification unit 19 examines the brightness of all the pixels in the shine area 25 and temporarily stores it in a storage unit such as a memory. Then, the brightness of all the pixels in the shine area is classified into a plurality of groups based on a predetermined threshold value (S-6). Further, the brightness of the acquired pixel and the pixel acquired immediately before are compared in order, and the color of the brightest pixel is detected (S-7).

例えば5つの分類になった場合、テカリ領域25の全画素は、5つのグループ27〜31に分類される。第1〜第5グループ27〜31は、図5に示す横軸の明るさの範囲ごとに分類されている。なお、図5に示すグラフの縦軸は、画素数を示している。図5のヒストグラムに示される第1〜第5グループ27〜31に属する画素群は、図4に示すテカリ領域25のうちの第1〜第5の領域27〜31に対応するものとする。   For example, in the case of five classifications, all pixels in the shine area 25 are classified into five groups 27 to 31. The first to fifth groups 27 to 31 are classified according to the brightness range on the horizontal axis shown in FIG. Note that the vertical axis of the graph shown in FIG. 5 indicates the number of pixels. The pixel groups belonging to the first to fifth groups 27 to 31 shown in the histogram of FIG. 5 correspond to the first to fifth regions 27 to 31 in the glossy region 25 shown in FIG.

補正部20は、平均色aと最も明るい画素(第1領域27の画素A)の色bとの合成比率を補正の回数iに応じて変えて補正色cを作り(S−8)、作成した補正色cで前記画素A(第1領域27の画素)を塗りつぶす。補正色cは、[数1]に示す式に基づいて決められる。   The correction unit 20 creates a correction color c by changing the composition ratio of the average color a and the color b of the brightest pixel (the pixel A of the first area 27) according to the number of corrections i (S-8). The pixel A (pixels in the first region 27) is filled with the corrected color c. The correction color c is determined based on the formula shown in [Formula 1].

例えば、前述したように分類数xが「5」である場合、[数1]の式に基づいて最初の補正で塗りつぶす補正色c0を求める。最初の補正であるので補正の回数iに「0」を代入し、またテカリ領域25内で最も明るい画素(第1の領域27の画素)の色bを「b0」とすると、最初に塗りつぶす補正色c0はc0=[1/2・a+1/2・(b0)]となる。つまり、最初の補正で塗りつぶす補正色c0は、平均色aと最も明るい画素の色b0とを半分ずつ合成して作られる。したがって、最初の補正では、図4に示す第1の領域27が補正色c0で塗りつぶされる(S−9)。   For example, as described above, when the classification number x is “5”, the correction color c0 to be filled in by the first correction is obtained based on the formula [Equation 1]. Since this is the first correction, if “0” is substituted for the number of corrections i, and the color b of the brightest pixel (the pixel in the first area 27) in the shine area 25 is “b0”, the correction is performed to fill first. The color c0 is c0 = [1/2 · a + 1/2 · (b0)]. That is, the correction color c0 to be filled in at the first correction is created by combining the average color a and the color b0 of the brightest pixel in half. Therefore, in the first correction, the first area 27 shown in FIG. 4 is filled with the correction color c0 (S-9).

その後、補正部20は、テカリ領域内で補正していない画素がある場合(S−10)、テカリ領域25内で補正していない画素のうちの最も明るい画素(第2領域28の画素)の色bを「b1」として取得する。そして、[数1]を用い、補正の回数iに「1」を代入すると(S−11)、2回目に塗りつぶす補正色c1は、C1=[3/5・a+2/5・(b1)]となる。つまり、2回目の補正で作られる補正色c1は、最初に作った補正色c0に対して、次に明るい画素(第2領域28の画素)の色b1の割合を少し減し、かつ平均色aの割合を少し増やした混合比で作られている。これにより、図4に示す次に明るい画素群(第2領域28)は、作成した補正色c1により塗りつぶされる。   Thereafter, when there is a pixel that has not been corrected in the shine area 25 (S-10), the correction unit 20 determines the brightest pixel (pixels in the second area 28) among the pixels that have not been corrected in the shine area 25. The color b is acquired as “b1”. Then, using [Equation 1] and substituting “1” for the number of corrections i (S-11), the correction color c1 to be painted second time is C1 = [3/5 · a + 2/5 · (b1)] It becomes. That is, the correction color c1 created by the second correction is obtained by slightly reducing the ratio of the color b1 of the next bright pixel (the pixel in the second region 28) to the correction color c0 created first, and the average color. It is made with a mixing ratio with the ratio of a slightly increased. As a result, the next brightest pixel group (second region 28) shown in FIG. 4 is filled with the created correction color c1.

このように前述した作業を分類数xの分だけ繰り返すことで、明るさに応じて分類した画素(グループ)を、補正の回数に応じて合成比率を変えた補正色cで、明るさの高い画素群から順に塗りつぶしていく。ここで、補正の回数iに応じて[数1]の式から算出される補正色c0〜c4の合成比率を図6に記載する。   In this way, by repeating the above-described operation for the number of classifications x, pixels (groups) classified according to the brightness have a high brightness with the correction color c in which the composition ratio is changed according to the number of corrections. Paint sequentially from the pixel group. Here, the composition ratio of the correction colors c0 to c4 calculated from the equation [Equation 1] according to the number of corrections i is shown in FIG.

なお、テカリ領域は、顔画像領域に対して複数検出される場合がある。検出されたテカリ領域に対して、テカリ領域補正部15は、順にテカリ補正を行う(S−12)。   Note that a plurality of shine areas may be detected for the face image area. With respect to the detected shine area, the shine area correction unit 15 sequentially performs the shine correction (S-12).

このように、補正色cは、補正の回数iが増すことに応じて平均色aを徐々に増やし、逆にその時点で最も明るい画素の色bの合成を減して作られる。テカリ領域25は、明るい領域27から暗い領域31に向けて平均色aに徐々に近づく補正色で、1画素分のステップずつ塗りつぶされる。これにより、立体感を損なわず、テカリ領域の周りになじむ自然なグラデーションで補正される。   In this way, the correction color c is created by gradually increasing the average color a as the number of corrections i increases, and conversely reducing the composition of the color b of the brightest pixel at that time. The shine area 25 is a correction color that gradually approaches the average color a from the bright area 27 toward the dark area 31 and is filled step by step for one pixel. As a result, correction is made with a natural gradation that fits around the shine area without impairing the stereoscopic effect.

なお、上記実施形態のテカリ補正では、テカリ領域を画素の明るさに応じて分類した複数のグループを最も明るい画素のグループから順に、前述した平均色aに徐々に近づくように補正色cで塗りつぶす補正を行っているが、本発明ではこれに限らず、平均色と塗りつぶし対象となる画素の色とを、最も明るい画素とテカリ領域の周囲の画素との間隔に応じて平均色aの合成比率を変えて作成した補正色で最も明るい画素から順に塗りつぶしてもよい。   In the shine correction of the above-described embodiment, a plurality of groups in which the shine area is classified according to the brightness of the pixels are filled with the correction color c so as to gradually approach the above-described average color a in order from the brightest pixel group. Although the correction is performed, the present invention is not limited to this, and the average color and the color of the pixel to be filled are determined by combining the average color a with the interval between the brightest pixel and the surrounding pixels of the shine area. It is also possible to paint in order from the brightest pixel in the correction color created by changing the.

例えば、最も明るい画素とテカリ領域の周囲との間隔が短い領域にある画素ほど、基準の補正色に対して1回の補正で平均色aを混合する量を多めにして作成した補正色で塗りつぶし、また、逆に前記距離が長い領域にある画素ほど、基準の補正色に対して1回の補正で平均色aを混合する量を少なくして作成した補正色で徐々に塗りつぶす。このため、最も明るい画素の領域がテカリ領域の中で偏った位置に存在していても、最も明るい画素の領域と周囲との間隔が短い領域では基準の補正色から平均色aに向けて、色の連続した変化が早い階調で補正され、また、間隔の長い領域では基準の補正色から平均色aに向けて、色の連続した変化が遅い階調で補正される。よって、最も明るい画素の領域と周囲との間の間隔に応じて自然なグラデーションになるようにテカリ領域を補正することができる。   For example, a pixel in a region where the distance between the brightest pixel and the periphery of the shine area is short is filled with a correction color created with a larger amount of the average color a mixed by one correction with respect to the reference correction color. On the contrary, as the pixel is located in the region with the longer distance, the correction color is gradually filled with the correction color created by reducing the amount of mixing the average color a by one correction with respect to the reference correction color. For this reason, even if the brightest pixel area exists at a position biased in the shine area, in the area where the distance between the brightest pixel area and the surrounding area is short, the reference correction color is shifted toward the average color a. A continuous change in color is corrected with a fast gradation, and in a long interval, a continuous change in color is corrected with a slow gradation from the reference correction color toward the average color a. Therefore, it is possible to correct the shine area so that a natural gradation is obtained according to the interval between the brightest pixel area and the surrounding area.

この場合、補正部は、[数2]に記載の式を用いて距離に応じて画素を塗りつぶす補正色dを決める。   In this case, the correction unit determines the correction color d for painting the pixel according to the distance using the equation described in [Equation 2].

[数2]
d=a・(0.5+0.5/n)+e・(0.5−0.5/n)
ここで、dは補正色、eは塗りつぶした画素に隣接する画素の色、nは塗りつぶし対象の画素と周囲との最短距離k/「1画素の大きさ」、つまり画素数(ドット数)である。
[Equation 2]
d = a · (0.5 + 0.5 / n) + e · (0.5−0.5 / n)
Here, d is the correction color, e is the color of the pixel adjacent to the filled pixel, n is the shortest distance k / “size of one pixel” between the pixel to be filled and the surroundings, that is, the number of pixels (number of dots) is there.

補正部は、図7及び図8に示すように、テカリ領域40の周囲の肌の色を平均した平均色aを取得し(S−13)、テカリ領域40内の全画素の明るさを取得してテカリ領域40内で一番明るい画素fの色wを取得する(S−14)。そして、平均色aと一番明るい画素fの色wとを1対1の比率で合成して補正色dを作成する(S−15)。そして、作成した補正色dで一番明るい画素fを塗りつぶす(S−16)。つまり、テカリ領域40のうちの一番明るい画素f(一番最初に塗りつぶす画素)は、0.5a+0.5eの合成比率で作成した基準の補正色dで塗りつぶされる。   As shown in FIGS. 7 and 8, the correction unit acquires an average color a obtained by averaging the skin colors around the shine area 40 (S-13), and acquires the brightness of all pixels in the shine area 40. Then, the color w of the brightest pixel f in the shine area 40 is acquired (S-14). Then, the correction color d is created by synthesizing the average color a and the color w of the brightest pixel f at a ratio of 1: 1 (S-15). Then, the brightest pixel f is filled with the created correction color d (S-16). That is, the brightest pixel f (the pixel to be filled first) in the shine area 40 is filled with the reference correction color d created at a composite ratio of 0.5a + 0.5e.

2回目の補正では、先に塗りつぶした画素fに隣接する画素z1の色eを取得し(S−17)、その画素z1に対して最も近くにある周囲の画素p1を検出し、これらの間の最短距離k1を算出する(S−18)。基準の補正色に対して最短距離k1に応じた比率で平均色aを混合して補正色dを作成する(S−19)。   In the second correction, the color e of the pixel z1 adjacent to the previously filled pixel f is acquired (S-17), the surrounding pixel p1 closest to the pixel z1 is detected, and the interval between them is detected. The shortest distance k1 is calculated (S-18). A correction color d is created by mixing the average color a at a ratio corresponding to the shortest distance k1 with respect to the reference correction color (S-19).

例えば図8に示す例では、最も明るい画素fの群41は、前述した基準の補正色dで塗りつぶされる。2回目の補正では、画素群41に隣接する画素z1の色eを取得し、その後、画素z1と周囲の画素p1との最短距離k1を算出する。そして、[数2]に記載の式に画素z1の色eと距離k1との値を代入して、補正色d1を算出する。そして、算出した補正色d1で画素z1を塗りつぶす(S−20)。   For example, in the example shown in FIG. 8, the brightest pixel f group 41 is filled with the reference correction color d described above. In the second correction, the color e of the pixel z1 adjacent to the pixel group 41 is acquired, and then the shortest distance k1 between the pixel z1 and the surrounding pixel p1 is calculated. Then, the correction color d1 is calculated by substituting the values of the color e of the pixel z1 and the distance k1 into the equation described in [Equation 2]. Then, the pixel z1 is painted with the calculated correction color d1 (S-20).

n回目の補正では、画素群41に隣接する画素znの色eを取得し、その後、画素znと周囲の画素pnとの最短距離knを算出する。そして、[数2]に記載の式に画素znの色eと距離knとの値を代入して、補正色dnを算出する。そして、算出した補正色dnで画素znを塗りつぶす。   In the n-th correction, the color e of the pixel zn adjacent to the pixel group 41 is acquired, and then the shortest distance kn between the pixel zn and the surrounding pixel pn is calculated. Then, the correction color dn is calculated by substituting the values of the color e and the distance kn of the pixel zn into the equation described in [Equation 2]. Then, the pixel zn is filled with the calculated correction color dn.

以後、前述した手順を繰り返して先に塗りつぶした画素の隣の画素から順に塗りつぶしていくことで、テカリ領域の全部の画素を補正する(S−21)。   Thereafter, the above-described procedure is repeated, and the pixels adjacent to the previously painted pixel are painted in order to correct all the pixels in the shine area (S-21).

平均色aは、基準の補正色dに対して距離kに応じた比率で合成される。[数2]の式を用いる場合、図9に示すように、塗りつぶし対象の画素と周囲の画素との距離kが短くなるほど、平均色aの比率を増やして補正色dが作成される。なお、これに伴って補正対象となる画素の色eの合成比率を減らしていくのは勿論である。そして、n=1のときには、平均色aで塗りつぶすことになる。   The average color a is synthesized at a ratio corresponding to the distance k with respect to the reference correction color d. When using the formula [2], as shown in FIG. 9, the correction color d is created by increasing the ratio of the average color a as the distance k between the pixel to be filled and the surrounding pixels becomes shorter. Along with this, it goes without saying that the composition ratio of the color e of the pixel to be corrected is reduced. When n = 1, the color is painted with the average color a.

ところで、補正色dを作る平均色aの合成比率を、口・目以外の部位に応じて変えるのが望ましい場合がある。例えば鼻の領域にテカリ領域が有る場合には、前述した[数1]又は[数2]に記載の式を用いて補正すると、平均色aを少なくとも半分混合した基準の補正色で最も明るい領域を塗りつぶすとともに、この領域から周囲に向かって基準の補正色に対して平均色aの比率を徐々に上げて作成した補正色で塗りつぶしていくため、平均色の合成比率が最初から多く、よって、立体感が得られなくなる不都合が生じる。   Incidentally, there are cases where it is desirable to change the composition ratio of the average color a that forms the correction color d in accordance with the part other than the mouth and eyes. For example, when there is a shine area in the nose area, the brightest area of the reference correction color in which the average color a is mixed at least half is corrected by using the formula described in [Expression 1] or [Expression 2]. In addition, the ratio of the average color a is gradually increased with respect to the reference correction color from this region toward the periphery, and the correction color is created, so that the composite ratio of the average color is large from the beginning. There is an inconvenience that the stereoscopic effect cannot be obtained.

そこで、この場合には、平均色aを少なくとも半分以下の比率で合成した第2基準の補正色で最も明るい領域を塗りつぶすとともに、この領域から周囲に向かって前記第2基準の補正色に対して平均色の比率を徐々に上げた補正色で塗りつぶしていけばよい。   Therefore, in this case, the brightest area is filled with the second reference correction color obtained by synthesizing the average color a at a ratio of at least half or less, and the second reference correction color is extended from this area toward the periphery. What is necessary is just to paint with the correction color which gradually increased the ratio of the average color.

勿論この場合には、テカリ領域が鼻領域であるか否かを判定する判定部を設け、鼻の領域にテカリ領域が存在する場合の補正である。また、前述したような合成比率になるように、予め決めた補正係数を前述した[数1]又は[数2]の式のうちの平均色aの比率を求める部分に掛けて補正するようにしてもよい。これにより、鼻の立体感が無くなることを防ぐことができる。   Of course, in this case, a determination unit that determines whether or not the shine area is a nose area is provided, and correction is performed when the shine area exists in the nose area. In addition, a correction coefficient determined in advance is corrected by multiplying the portion for obtaining the ratio of the average color a in the above-described equation [Equation 1] or [Equation 2] so that the composition ratio as described above is obtained. May be. Thereby, it can prevent that a nose three-dimensional effect is lost.

10 画像補正装置
12 顔検出部
14 テカリ領域検出部
15 テカリ領域補正部
DESCRIPTION OF SYMBOLS 10 Image correction apparatus 12 Face detection part 14 Detective area detection part 15 Detective area correction part

Claims (12)

入力された画像から顔画像領域を検出する顔検出手段と、
顔画像領域で所定の明るさより明るい領域、又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出手段と、
前記テカリ領域を最も明るい領域から周囲に向けて周囲の色に徐々に近づくように塗りつぶす補正を行うテカリ補正手段と、
を備えたことを特徴とする画像補正装置。
Face detection means for detecting a face image area from the input image;
A shine area detection means for detecting, as a shine area, an area brighter than a predetermined brightness in the face image area or an area brighter than the surrounding area by a predetermined amount;
Shine correction means for correcting the shine area so as to gradually approach the surrounding color from the brightest area toward the periphery; and
An image correction apparatus comprising:
請求項1に記載の画像補正装置において、
前記テカリ補正手段は、
前記テカリ領域を最も明るい領域から周囲に向けて徐々に塗りつぶす補正色を、前記テカリ領域内の塗りつぶし対象となる画素の色に対して、前記テカリ領域の周囲の画素の色を平均した平均色を混合する割合を徐々に増やして作成することを特徴とする画像補正装置。
The image correction apparatus according to claim 1,
The shine correction means is
A correction color that gradually fills the shine area from the brightest area to the periphery, and an average color obtained by averaging the colors of the pixels around the shine area with respect to the color of the pixel to be filled in the shine area. An image correction apparatus characterized by gradually increasing the mixing ratio.
請求項1又は2に記載の画像補正装置において、
前記テカリ補正手段は、
前記テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得部と、
前記テカリ領域を画素の明るさに応じて複数のグループに分類する分類部と、
前記平均色を、塗りつぶし対象となるグループの画素の色に、前記平均色の比率が徐々に増えるように合成して補正色を作成し、作成した補正色で最も明るいグループの画素から順に塗りつぶす補正部と、
で構成されていることを特徴とする画像補正装置。
The image correction apparatus according to claim 1 or 2,
The shine correction means is
An average color acquisition unit that acquires an average color obtained by averaging the colors of pixels around the shine area;
A classification unit for classifying the shine area into a plurality of groups according to pixel brightness;
A correction color is created by combining the average color with the color of the pixel of the group to be filled so that the ratio of the average color gradually increases, and the correction is performed by filling the pixels in order from the brightest group of the created correction color. And
An image correction apparatus comprising:
請求項1又は2に記載の画像補正装置において、
前記テカリ補正手段は、
テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得部と、
テカリ領域のうちの最も明るい画素を検出する最明画素検出部と、
前記平均色と塗りつぶし対象となる画素の色とを、前記周囲との間の距離が短い画素ほど前記平均色の比率が徐々に増えるように合成して補正色を作成し、作成した補正色で前記最も明るい画素から周囲の画素に向けて順に画素を塗りつぶす補正部と、
で構成されていることを特徴とする画像補正装置。
The image correction apparatus according to claim 1 or 2,
The shine correction means is
An average color acquisition unit that acquires an average color obtained by averaging the colors of pixels around the shine area;
The brightest pixel detection unit for detecting the brightest pixel in the shine area;
The correction color is created by combining the average color and the color of the pixel to be filled so that the ratio of the average color gradually increases as the distance from the surrounding area becomes shorter. A correction unit that fills pixels in order from the brightest pixel to surrounding pixels;
An image correction apparatus comprising:
入力された画像から顔画像領域を検出する顔検出ステップと、
顔画像領域で所定の明るさより明るい領域、又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出ステップと、
前記テカリ領域を最も明るい領域から周囲に向けて周囲の色に徐々に近づくように塗りつぶす補正を行うテカリ補正ステップと、
を含むことを特徴とする画像補正方法。
A face detection step for detecting a face image area from the input image;
A shining area detecting step for detecting, as a shining area, an area brighter than a predetermined brightness in the face image area or an area brighter than the surrounding area by a predetermined amount;
A shine correction step for correcting the shine area so as to gradually approach the surrounding color from the brightest area toward the periphery,
An image correction method comprising:
請求項5に記載の画像補正方法において、
前記テカリ補正ステップは、
前記テカリ領域を最も明るい領域から周囲に向けて徐々に塗りつぶす補正色を、前記テカリ領域内の塗りつぶし対象となる画素の色に対して、前記テカリ領域の周囲の画素の色を平均した平均色を混合する割合を徐々に増やして作成することを特徴とする画像補正方法。
The image correction method according to claim 5,
The shine correction step includes
A correction color that gradually fills the shine area from the brightest area to the periphery, and an average color obtained by averaging the colors of the pixels around the shine area with respect to the color of the pixel to be filled in the shine area. A method for correcting an image, characterized by gradually increasing the mixing ratio.
請求項5又は6に記載の画像補正方法において、
前記テカリ補正ステップは、
テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得ステップと、
テカリ領域を画素の明るさに応じて複数のグループに分類する分類ステップと、
前記平均色と塗りつぶし対象となるグループの画素の色とを、前記平均色の合成比率が徐々に増えるように合成して補正色を作成し、作成した補正色で最も明るいグループの画素から順に塗りつぶす補正ステップと、
を含むことを特徴とする画像補正方法。
The image correction method according to claim 5 or 6,
The shine correction step includes
An average color acquisition step of acquiring an average color obtained by averaging the colors of pixels around the shine area;
A classification step of classifying the shine area into a plurality of groups according to pixel brightness;
The average color and the colors of the pixels of the group to be filled are synthesized so that the synthesis ratio of the average color gradually increases to create a correction color, and the correction color thus created is filled in order from the brightest group of pixels. A correction step;
An image correction method comprising:
請求項5又は6に記載の画像補正方法において、
前記テカリ補正ステップは、
テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得ステップと、
テカリ領域のうちの最も明るい画素を検出する最明画素検出ステップと、
前記平均色と塗りつぶし対象となる画素の色とを、前記周囲との間の距離が短い画素ほど前記平均色の合成比率が徐々に増えるように合成して補正色を作成し、作成した補正色で前記最も明るい画素から周囲の画素に向けて順に画素を塗りつぶす補正ステップと、
を含むことを特徴とする画像補正方法。
The image correction method according to claim 5 or 6,
The shine correction step includes
An average color acquisition step of acquiring an average color obtained by averaging the colors of pixels around the shine area;
A brightest pixel detection step for detecting the brightest pixel in the shine area;
A correction color is created by combining the average color and the color of the pixel to be filled so that a pixel having a shorter distance from the surrounding area gradually increases the average color combination ratio, A correction step of filling the pixels in order from the brightest pixel to the surrounding pixels;
An image correction method comprising:
入力された画像から顔画像領域を検出する顔検出ステップと、
顔画像領域で所定の明るさより明るい領域、又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出ステップと、
前記テカリ領域を最も明るい領域から周囲に向けて周囲の色に徐々に近づくように塗りつぶす補正を行うテカリ補正ステップと、
をコンピュータに実行せるためのプログラム。
A face detection step for detecting a face image area from the input image;
A shining area detecting step for detecting, as a shining area, an area brighter than a predetermined brightness in the face image area or an area brighter than the surrounding area by a predetermined amount;
A shine correction step for correcting the shine area so as to gradually approach the surrounding color from the brightest area toward the periphery,
A program that allows a computer to execute.
入力された画像から顔画像領域を検出する顔検出ステップと、
顔画像領域で所定の明るさより明るい領域、又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出ステップと、
テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得ステップと、
前記テカリ領域を画素の明るさに応じて複数のグループに分類する分類ステップと、
前記平均色と塗りつぶし対象となるグループの画素の色とを、前記平均色の合成比率が徐々に増えるように合成して補正色を作成し、作成した補正色で最も明るいグループの画素から順に塗りつぶす補正ステップと、
をコンピュータに実行せるためのプログラム。
A face detection step for detecting a face image area from the input image;
A shining area detecting step for detecting, as a shining area, an area brighter than a predetermined brightness in the face image area or an area brighter than the surrounding area by a predetermined amount;
An average color acquisition step of acquiring an average color obtained by averaging the colors of pixels around the shine area;
A classification step of classifying the shine area into a plurality of groups according to pixel brightness;
The average color and the colors of the pixels of the group to be filled are synthesized so that the synthesis ratio of the average color gradually increases to create a correction color, and the correction color thus created is filled in order from the brightest group of pixels. A correction step;
A program that allows a computer to execute.
入力された画像から顔画像領域を検出する顔検出ステップと、
顔画像領域で所定の明るさより明るい領域、又は周囲よりも明るさが所定以上明るい領域をテカリ領域として検出するテカリ領域検出ステップと、
テカリ領域の周囲の画素の色を平均した平均色を取得する平均色取得ステップと、
テカリ領域のうちの最も明るい画素を検出する最明画素検出ステップと、
前記平均色と塗りつぶし対象となる画素の色とを、前記周囲との間の距離が短い画素ほど前記平均色の合成比率が徐々に増えるように合成して補正色を作成し、作成した補正色で前記最も明るい画素から周囲の画素に向けて順に画素を塗りつぶす補正ステップと、
をコンピュータに実行せるためのプログラム。
A face detection step for detecting a face image area from the input image;
A shining area detecting step for detecting, as a shining area, an area brighter than a predetermined brightness in the face image area or an area brighter than the surrounding area by a predetermined amount;
An average color acquisition step of acquiring an average color obtained by averaging the colors of pixels around the shine area;
A brightest pixel detection step for detecting the brightest pixel in the shine area;
A correction color is created by combining the average color and the color of the pixel to be filled so that a pixel having a shorter distance from the surrounding area gradually increases the average color combination ratio, A correction step of filling the pixels in order from the brightest pixel to the surrounding pixels;
A program that allows a computer to execute.
請求項9ないし11いずれか1項に記載のプログラムを実行させるためのプログラムを記録したコンピュータ読み取り可能な記録媒体。   The computer-readable recording medium which recorded the program for performing the program of any one of Claim 9 thru | or 11.
JP2012024131A 2012-02-07 2012-02-07 Image correction device, method, program, and recording medium Pending JP2013161348A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012024131A JP2013161348A (en) 2012-02-07 2012-02-07 Image correction device, method, program, and recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012024131A JP2013161348A (en) 2012-02-07 2012-02-07 Image correction device, method, program, and recording medium

Publications (1)

Publication Number Publication Date
JP2013161348A true JP2013161348A (en) 2013-08-19

Family

ID=49173524

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012024131A Pending JP2013161348A (en) 2012-02-07 2012-02-07 Image correction device, method, program, and recording medium

Country Status (1)

Country Link
JP (1) JP2013161348A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018005573A (en) * 2016-07-01 2018-01-11 キヤノン株式会社 Image processing apparatus, image processing method, program, and storage medium
JP2018041380A (en) * 2016-09-09 2018-03-15 キヤノン株式会社 Image processing apparatus, image processing method, and program
JP2018198029A (en) * 2017-05-25 2018-12-13 キヤノン株式会社 Image processing apparatus, image processing method, and program
US10248843B2 (en) 2015-03-12 2019-04-02 Omron Corporation Image processing apparatus and method for removing a facial object
JP2021128791A (en) * 2016-12-02 2021-09-02 キヤノン株式会社 Image processing apparatus, image processing method, and program

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10248843B2 (en) 2015-03-12 2019-04-02 Omron Corporation Image processing apparatus and method for removing a facial object
JP2018005573A (en) * 2016-07-01 2018-01-11 キヤノン株式会社 Image processing apparatus, image processing method, program, and storage medium
JP2018041380A (en) * 2016-09-09 2018-03-15 キヤノン株式会社 Image processing apparatus, image processing method, and program
JP2021128791A (en) * 2016-12-02 2021-09-02 キヤノン株式会社 Image processing apparatus, image processing method, and program
JP7129520B2 (en) 2016-12-02 2022-09-01 キヤノン株式会社 Image processing device, image processing method, and program
JP2018198029A (en) * 2017-05-25 2018-12-13 キヤノン株式会社 Image processing apparatus, image processing method, and program

Similar Documents

Publication Publication Date Title
JP5889431B2 (en) Image processing apparatus and image processing method
CN101483711B (en) Gradation correction device, gradation correction method
JP5960513B2 (en) Video processing apparatus and method
US10291823B2 (en) Apparatus and method for color calibration
CN103679733B (en) A kind of signal lamp image processing method and its device
KR100901353B1 (en) Image processing apparatus and method
US8737762B2 (en) Method for enhancing image edge
US9185265B2 (en) Image processing method and image processing apparatus for performing a tone correction to acquire a combined image
US9449375B2 (en) Image processing apparatus, image processing method, program, and recording medium
JP2013161348A (en) Image correction device, method, program, and recording medium
JP4066803B2 (en) Image processing apparatus, image processing program, image processing method, and electronic camera
CN108337450A (en) Image processing apparatus, image processing method and recording medium
US9299003B2 (en) Image processing apparatus, non-transitory computer readable medium, and image processing method
CN105338214B (en) Image processing method and image processing apparatus
JP6365355B2 (en) Image generating apparatus and image generating method
US9235773B2 (en) Image processing device capable of determining types of images accurately
US11636576B2 (en) Image processing apparatus for reducing influence of fine particle in an image, control method of same, and non-transitory computer-readable storage medium
KR20150037203A (en) Device for correcting depth map of three dimensional image and method for correcting the same
JP6889336B2 (en) Image demosaic processing system and method
JP5884605B2 (en) Image processing apparatus and program
CN114240800A (en) Scattering scene-oriented coded camera image enhancement method and device
JP5147912B2 (en) Image processing method, image processing apparatus, program, and recording medium
KR101488641B1 (en) Image processing apparatus and Image processing method
JP2000099701A (en) Image color processor, image color processing method and recording medium
JP4831344B2 (en) Eye position detection method