[go: up one dir, main page]

JP2009038582A - Image processing apparatus and image processing method - Google Patents

Image processing apparatus and image processing method Download PDF

Info

Publication number
JP2009038582A
JP2009038582A JP2007200916A JP2007200916A JP2009038582A JP 2009038582 A JP2009038582 A JP 2009038582A JP 2007200916 A JP2007200916 A JP 2007200916A JP 2007200916 A JP2007200916 A JP 2007200916A JP 2009038582 A JP2009038582 A JP 2009038582A
Authority
JP
Japan
Prior art keywords
processing
image processing
image
correction
coefficient
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
JP2007200916A
Other languages
Japanese (ja)
Inventor
Tetsuya Suwa
徹哉 諏訪
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2007200916A priority Critical patent/JP2009038582A/en
Publication of JP2009038582A publication Critical patent/JP2009038582A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Processing Of Color Television Signals (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Color Image Communication Systems (AREA)
  • Image Processing (AREA)
  • Picture Signal Circuits (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To solve the problem wherein flesh color is corrected by an improper correction coefficient by preventing a skin portion from being detected, or by detecting an incorrect place. <P>SOLUTION: In an image processing unit for performing plurality of image processing means to an input image, at least one of the image processing means is first image processing means having processing coefficient determination means for determining coefficients used for the execution of processing, the processing coefficient determination means is processing coefficient determination means for performing determination by utilizing other second image processing means, and a processing coefficient determined by the processing coefficient determination means is used to execute the first image processing means. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、複数の画像処理を施す画像処理装置および方法に関するものである。   The present invention relates to an image processing apparatus and method for performing a plurality of image processing.

ここ数年におけるパーソナルコンピュータの性能向上により、大容量のファイルでさえも容易にかつ高速に扱えるようになった。一般に容量の大きいとされる写真調の自然画像もより多くの人が取り扱うようになってきている。それに加えデジタルカメラやスキャナに代表される入力機器も普及してきたため、さまざまな画像のデジタル化が行われるようになった。   The performance of personal computers over the last few years has made it easier and faster to handle even large files. More and more people are handling photographic-like natural images, which are generally considered to have a large capacity. In addition, input devices represented by digital cameras and scanners have become widespread, and various images have been digitized.

一口に写真画像といってもその中にはプロの撮影した高画質の画像から、あまり品位の良くない画像まで様々である。ここで言う品位の良くない画像とは露出のオーバーしているものやアンダーしているもの、画像全体に色味のつく色かぶりを起こしている画像等である。一般に悪い画像がつくられる原因として考えられるのは、撮影時の光量が適正でないことや蛍光燈下での撮影といった撮影条件によるものと、デジタルカメラのノイズや特性といったデジタル化処理の際に起こる画像の劣化等が挙げられる。これら品位の悪い画像はデジタル化処理をしてパーソナルコンピュータ等に取り込んだ後、補正を施すことによって画像品位を上げることが可能である。   There are various types of photographic images, from high-quality images taken by professionals to images with poor quality. An image with poor quality referred to here is an image that is overexposed or underexposed, an image that causes a tinted color cast on the entire image, and the like. In general, the possible causes of bad images are due to inadequate light intensity during shooting, shooting conditions such as shooting under fluorescent light, and images generated during digitization such as noise and characteristics of digital cameras. Deterioration, etc. These poor quality images can be improved by digitizing the image and taking it into a personal computer or the like and then performing correction.

こうした補正処理は、画像をレタッチするアプリケーションやプリンタに代表される記録装置のドライバの機能として付属しているのが一般的であった。   Such correction processing is generally attached as a function of an application for retouching an image or a driver of a printing apparatus represented by a printer.

昨今、デジタルカメラとプリンタを直接接続し、記録処理を行うPictBridge(登録商標)の規格策定や、カードスロットを持ったプリンタの登場により、画像をPC経由しないで記録する使い方が、広がってきている。こうした背景から、PCを介さないNonPC環境のプリントにおいても、PCのアプリケーションやプリンタドライバと同様な補正処理の実現が求められているのが現状である。   In recent years, with the development of PictBridge (registered trademark) standards in which a digital camera and a printer are directly connected to perform recording processing, and the appearance of printers with card slots, the usage of recording images without going through a PC has become widespread. . Under such circumstances, even in printing in a non-PC environment without using a PC, it is currently required to realize correction processing similar to that of a PC application or printer driver.

一般にPCのCPU能力やメモリ容量、バススピードなどのシステム環境に比べ、プリンタのそれらは大きく劣るものである。これによるパフォーマンス低下を防ぐために、特許文献4ではプリンタ動作のためのCPUのほか、画像処理専用のプロセッサを使用することにより対処を行っている。このほか、高速アクセス可能なメモリの採用、バススピードの高速化、専用ASICの搭載などによっても、画像処理時間の短縮を図ることが可能である。しかし、これら高速化を行うことはコストがかり、最終的にはユーザーにとっての負担となってしまう。つまり、高速化とコストアップは、トレードオフの関係となっている。   In general, printers are significantly inferior to system environments such as PC CPU capacity, memory capacity, and bus speed. In order to prevent performance degradation due to this, Japanese Patent Application Laid-Open No. 2004-151867 takes measures by using a processor dedicated to image processing in addition to a CPU for printer operation. In addition, it is possible to shorten the image processing time by adopting a memory that can be accessed at high speed, increasing the bus speed, and mounting a dedicated ASIC. However, these speeding-ups are costly and ultimately burden the user. In other words, speeding up and cost increase are in a trade-off relationship.

一方、画像補正については、様々な提案がされているが、一般的にこれら補正処理では、補正を施すための補正量を算出する補正量決定部と、求められた補正量に基づいて補正を実行する補正実行部に分けられる。   On the other hand, various proposals have been made for image correction. Generally, in these correction processes, a correction amount determination unit that calculates a correction amount for performing correction, and correction based on the obtained correction amount. It is divided into correction execution units to be executed.

そのうちの補正量決定部では、処理内容により大きく2つに分類できる。一つは画像の累積データを生成し、それを基に補正量を決定する方法と、画像内の特定部分の特徴量を抽出し、その値により補正を行う処理である。   Among them, the correction amount determination unit can be roughly classified into two types according to the processing contents. One is a method of generating accumulated data of an image and determining a correction amount based on the generated data, and a process of extracting a feature amount of a specific part in the image and performing correction based on the value.

前者の累積データを使用する補正方法として、特開2000−13624号公報、特開2000−13616号公報が挙げられる。この処理では、ホワイトバランスの設定が不十分であったり露出が最適でなかったりする画像に対して色かぶりおよびレベル補正が実行されている。補正量を求める累積処理としては、画素毎の輝度値を累積しヒストグラムを作成し、それに基づいて補正の必要有無を判定および補正量の決定を行う。図1(a)に示すような生成された輝度ヒストグラムを図1(b)のように修正するような輝度変換処理を実行することにより補正を実行する。図1(a)のHL、SD点に相当する輝度値の平均色相を算出し、それらが無彩色になるような変換係数を求め、それを施すことにより、適切なグレーバランスを実現している。   JP-A 2000-13624 and JP-A 2000-13616 can be cited as correction methods using the former accumulated data. In this process, color cast and level correction are performed on an image for which white balance setting is insufficient or exposure is not optimal. As the accumulation process for obtaining the correction amount, the luminance value for each pixel is accumulated to create a histogram, and based on this, the necessity of correction is determined and the correction amount is determined. Correction is executed by executing a luminance conversion process for correcting the generated luminance histogram as shown in FIG. 1A as shown in FIG. Appropriate gray balance is realized by calculating an average hue of luminance values corresponding to the HL and SD points in FIG. 1A, obtaining conversion coefficients so that they become achromatic colors, and applying them. .

また、さらに画像をより好適にするコントラスト補正、彩度補正も可能である。取得した輝度ヒストグラムの分布から、S字カーブなどの輝度変換量を決定し、コントラスト補正を行ったり、画像の平均彩度から補正係数量を算出し、画像の色差成分に補正係数を乗じたりすることにより、各補正が行われる。   Further, contrast correction and saturation correction that make the image more suitable are also possible. From the acquired luminance histogram distribution, a luminance conversion amount such as an S-shaped curve is determined and contrast correction is performed, or a correction coefficient amount is calculated from the average saturation of the image, and the color difference component of the image is multiplied by the correction coefficient. Thus, each correction is performed.

一方、後者の特定部分の抽出を行う処理としては、主に人肌など画像の主要部分となる検出処理が一般的である。特登録3203946号公報は、テレビのような映像信号の補正であるが、色差信号と輝度信号から肌色平均輝度レベルを検出し、全画像の輝度レベルの関連でガンマ補正回路に制御信号を加えるものである。   On the other hand, the latter process of extracting a specific part is generally a detection process that is mainly a main part of an image such as human skin. Japanese Patent No. 3203946 is a correction of a video signal such as a television, but detects a skin color average luminance level from a color difference signal and a luminance signal, and adds a control signal to a gamma correction circuit in relation to the luminance level of all images. It is.

この特定部分抽出を伴う処理においては、その部位を検出する検出率が非常に重要となる。検出率が悪いと、補正が適用されないばかりか、誤った補正係数が設定されてしまい、かえって画像を悪化させる場合も発生してしまう。特登録3203946の肌色検出では、輝度・色差成分に分解されている信号値のうち、色差信号を利用して、肌色部分を検出している。   In the process involving extraction of the specific part, the detection rate for detecting the part is very important. If the detection rate is low, not only the correction is not applied, but an incorrect correction coefficient is set, and the image may be deteriorated. In the skin color detection of special registration 3203946, a skin color portion is detected by using a color difference signal among signal values decomposed into luminance and color difference components.

また、別の手段として人肌部分を検出する際、色による判定を下記式(4)   Moreover, when detecting a human skin part as another means, the determination by a color is represented by following formula (4).

Figure 2009038582
により行うものもある。ここで、R、G、Bは画像の画素信号のレッド、グリーン、ブルー信号を表す。色味による検出のほか、DCT変換後の周波数特性を利用して、高精度に人肌部分を検出処理が行うことも可能である。こうした処理により、主被写体である人物が逆光で暗くなった場合やフラッシュにより色飛びを起こした場合に、適切な露出に補正することや、人肌部分にローパスフィルタを適用することにより、肌補正を実現している。
Figure 2009038582
There are also things to do. Here, R, G, and B represent red, green, and blue signals of image pixel signals. In addition to detection by color, it is also possible to detect human skin portions with high accuracy using frequency characteristics after DCT conversion. With this process, when the person who is the main subject becomes dark due to backlighting or when a color jump occurs due to flash, the skin is corrected by applying an appropriate exposure or applying a low-pass filter to the human skin. Is realized.

ローバスフィルタの一例としては、一般的な平均値フィルタやメディアンフィルタなどの平滑化フィルタが挙げられる。フィルタサイズとしては、3x3や5x5と言った固定サイズでも構わないし、検出した人肌領域の大きさに応じてダイナミックに変えて行く方法でも構わない。   As an example of the low-pass filter, a smoothing filter such as a general average value filter or a median filter can be given. The filter size may be a fixed size such as 3 × 3 or 5 × 5, or may be a method of changing dynamically according to the size of the detected human skin area.

また、画像全体に平滑化フィルタをかけ、人肌部分での平滑化強度を変えることで、全体のノイズを除去し、さらに人肌も滑らかにする補正も可能である。平滑化の強度を変える方法としては、フィルタの係数を切り替えることで実現出来る。   Further, by applying a smoothing filter to the entire image and changing the smoothing strength in the human skin part, it is possible to correct the noise by removing the entire noise and further smoothing the human skin. A method of changing the smoothing intensity can be realized by switching the coefficient of the filter.

以上、述べたようにNonPCでの印刷するにおいても、単に印字を行うだけでなく、色被り除去、逆光補正などの肌補正、ノイズ除去と言った画像の補正・加工といったデジタルならではの利点を反映するようになっている。   As described above, when printing with NonPC, as well as performing printing, it reflects the benefits of digital technology such as image correction and processing such as color correction, skin correction such as backlight correction, and noise reduction. It is supposed to be.

また、従来の技術として、最近の特徴的な傾向となっているNonPCの例を挙げたが、画像補正については、PCで同様の処理が可能であることは言うまでもない。
特開2000−13624号公報 特開2000−13616号公報 特登録3203946号公報 特開2003−200621号公報
In addition, as a conventional technique, an example of NonPC, which has been a recent characteristic trend, has been given. Needless to say, the same processing can be performed on a PC for image correction.
JP 2000-13624 A JP 2000-13616 A Special Registration No. 3203946 JP2003-200261A

上述した従来の技術の中で、特定部分の検出を行って処理を加えるものを記述したが、もともとの画像が色被りを起こしている場合やノイズが多く出ている場合などは、特定部分の検出の際に誤検出を起こしやすい。特に特登録3203946や、上記式(4)などのように、色による判定を行っている検出処理においては、色被りは大きく判定結果をずらし、肌部分を検出しなかったり、誤った箇所を検出したりする。この結果、誤った補正係数を算出してしまい、肌色に対する補正を適切にすることが出来ず、かえって画像を悪化させてしまうことがある。   In the conventional technology described above, the specific part is detected and processed. However, if the original image is colored or has a lot of noise, the specific part Misdetection is likely to occur during detection. In particular, in the detection process in which judgment is performed by color as in the special registration 3203946 or the above formula (4), the color covering greatly shifts the judgment result, and the skin part is not detected or an erroneous part is detected. To do. As a result, an incorrect correction coefficient is calculated, the correction for the skin color cannot be made appropriate, and the image may be deteriorated.

本発明では、上記課題を解決するためになされたものであり、
入力された画像に対して、複数の画像処理手段を施す画像処理装置において、
そのうちの少なくとも一つの画像処理手段は、処理を実行する際に使用する係数を決定する処理係数決定手段を有する第一の画像処理手段であり、
前記処理係数決定手段は、他の第二の画像処理手段を利用して決定する処理係数決定手段であり、
前記処理係数決定手段により決定された処理係数を使用して、前記第一の画像処理手段を実行することを特徴とする。
The present invention has been made to solve the above problems,
In an image processing apparatus that applies a plurality of image processing means to an input image,
At least one of the image processing means is a first image processing means having a processing coefficient determining means for determining a coefficient to be used when executing the processing,
The processing coefficient determination means is a processing coefficient determination means that determines using another second image processing means,
The first image processing means is executed using the processing coefficient determined by the processing coefficient determination means.

以上、説明と実施例を挙げたとおり、本発明によれば、複数の画像処理を有し、その一つが画像の中から特定部分を検出する処理である場合に、予め検出処理に用いるデータに補正処理を行うことで、より検出精度の高い検出処理が実現出来る。   As described above, according to the present invention, according to the present invention, when there are a plurality of image processes, and one of them is a process for detecting a specific portion from an image, the data used for the detection process in advance is used. By performing correction processing, detection processing with higher detection accuracy can be realized.

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

[実施形態1]
以下、添付図面を参照して本発明の好適な実施の形態を詳細に説明する。尚、本実施の形態では、通常のPCから印字出来るプリンタだけでなく、PCカードスロットを有し、PCカードに記録されたデジタルカメラで撮影した画像もプリンタ可能である。記録方法としてインクジェット方式を採用している記録装置(フォトダイレクトプリンタ装置)を例に挙げて説明する。
[Embodiment 1]
Preferred embodiments of the present invention will be described below in detail with reference to the accompanying drawings. In the present embodiment, not only a printer capable of printing from a normal PC but also an image taken with a digital camera having a PC card slot and recorded on the PC card can be printed. A recording apparatus (photo direct printer apparatus) that employs an inkjet method as a recording method will be described as an example.

以下、添付図面を参照して本発明の好適な実施の形態を詳細に説明する。   Preferred embodiments of the present invention will be described below in detail with reference to the accompanying drawings.

図2は、本発明の実施の形態に係るフォトダイレクトプリンタ装置1000の概観斜視図である。このフォトダイレクトプリンタは、ホストコンピュータ(PC)からデータを受信して印刷する、通常のPCプリンタとしての機能と、メモリカードなどの記憶媒体に記憶されている画像データを直接読取って印刷したり、或いはデジタルカメラからの画像データを直接受信して印刷する機能を備えている。   FIG. 2 is a schematic perspective view of the photo direct printer 1000 according to the embodiment of the present invention. This photo direct printer receives and prints data from a host computer (PC), functions as a normal PC printer, and directly reads and prints image data stored in a storage medium such as a memory card, Alternatively, it has a function of directly receiving and printing image data from a digital camera.

図2において、本実施の形態に係るフォトダイレクトプリンタ装置1000の外殻をなす本体は、下ケース1001、上ケース1002、アクセスカバー1003及び排出トレイ1004の外装部材を有している。また、下ケース1001は、装置1000の略下半部を、上ケース1002は本体の略上半部をそれぞれ形成しており、両ケースの組合せによって内部に後述の各機構を収納する収納空間を有する中空体構造をなし、その上面部及び前面部にはそれぞれ開口部が形成されている。さらに、排出トレイ1004は、その一端部が下ケース1001に回動自在に保持され、その回動によって下ケース1001の前面部に形成される開口部を開閉させ得るようになっている。このため、記録動作を実行させる際には、排出トレイ1004を前面側へと回動させて開口部を開成させることにより、ここから記録シートが排出可能となると共に、排出された記録シートを順次積載し得るようになっている。また、排紙トレイ1004には、2枚の補助トレイ1004a,1004bが収納されており、必要に応じて各トレイを手前に引き出すことにより、用紙の支持面積を3段階に拡大、縮小させ得るようになっている。   In FIG. 2, the main body that forms the outer shell of the photo direct printer 1000 according to the present embodiment includes a lower case 1001, an upper case 1002, an access cover 1003, and an exterior member for a discharge tray 1004. The lower case 1001 forms a substantially lower half of the apparatus 1000, and the upper case 1002 forms a substantially upper half of the main body. A combination of both cases provides a storage space for storing each mechanism described below. A hollow body structure is formed, and openings are formed on the upper surface portion and the front surface portion, respectively. Further, one end of the discharge tray 1004 is rotatably held by the lower case 1001, and the opening formed in the front surface of the lower case 1001 can be opened and closed by the rotation. For this reason, when executing the recording operation, the discharge tray 1004 is rotated to the front side to open the opening, so that the recording sheets can be discharged from here, and the discharged recording sheets are sequentially discharged. It can be loaded. The paper discharge tray 1004 stores two auxiliary trays 1004a and 1004b. By pulling out the respective trays to the front as needed, the sheet support area can be expanded and reduced in three stages. It has become.

アクセスカバー1003は、その一端部が上ケース1002に回転自在に保持され、上面に形成される開口部を開閉し得るようになっており、このアクセスカバー1003を開くことによって本体内部に収納されている記録ヘッドカートリッジ(図示せず)あるいはインクタンク(図示せず)等の交換が可能となる。なお、ここでは特に図示しないが、アクセスカバー1003を開閉させると、その裏面に形成された突起がカバー開閉レバーを回転させるようになっており、そのレバーの回転位置をマイクロスイッチなどで検出することにより、アクセスカバーの開閉状態を検出し得るようになっている。   One end of the access cover 1003 is rotatably held by the upper case 1002 so that an opening formed on the upper surface can be opened and closed. By opening the access cover 1003, the access cover 1003 is accommodated inside the main body. The recording head cartridge (not shown), the ink tank (not shown), or the like can be replaced. Although not particularly shown here, when the access cover 1003 is opened and closed, the protrusion formed on the back surface rotates the cover opening and closing lever, and the rotation position of the lever is detected by a micro switch or the like. Thus, the open / closed state of the access cover can be detected.

また、上ケース1002の上面には、電源キー1005が押下可能に設けられている。また、上ケース1002の右側には、液晶表示部1006や各種キースイッチ等を備える操作パネル1010が設けられている。この操作パネル1010の構造は、図3を参照して詳しく後述する。1007は自動給送部で、記録シートを装置本体内へと自動的に給送する。1008は紙間選択レバーで、記録ヘッドと記録シートとの間隔を調整するためのレバーである。1009はカードスロットで、ここにメモリカードを装着可能なアダプタが挿入され、このアダプタを介してメモリカードに記憶されている画像データを直接取り込んで印刷することができる。1011はビューワ(液晶表示部)で、この装置本体に着脱可能であり、PCカードに記憶されている画像の中からプリントしたい画像を検索する場合などに、1コマ毎の画像やインデックス画像などを表示するのに使用される。1012は後述するデジタルカメラを接続するための端子、1013は、パーソナルコンピュータ(PC)を接続するためのUSBバスコネクタを示す。   A power key 1005 is provided on the upper surface of the upper case 1002 so that it can be pressed. An operation panel 1010 including a liquid crystal display unit 1006 and various key switches is provided on the right side of the upper case 1002. The structure of the operation panel 1010 will be described in detail later with reference to FIG. An automatic feeding unit 1007 automatically feeds the recording sheet into the apparatus main body. Reference numeral 1008 denotes a paper interval selection lever which is used to adjust the interval between the recording head and the recording sheet. Reference numeral 1009 denotes a card slot, into which an adapter capable of mounting a memory card is inserted, through which image data stored in the memory card can be directly captured and printed. Reference numeral 1011 denotes a viewer (liquid crystal display unit) which can be attached to and detached from the main body of the apparatus. When searching for an image to be printed from images stored in a PC card, an image or index image for each frame is displayed. Used to display. Reference numeral 1012 denotes a terminal for connecting a digital camera, which will be described later, and 1013 denotes a USB bus connector for connecting a personal computer (PC).

図3は、本実施の形態に係る操作パネル1010の概観図である。   FIG. 3 is a schematic view of operation panel 1010 according to the present embodiment.

図において、液晶表示部1006には、その左右に印刷されている項目に関するデータを各種設定するためのメニュー項目が表示される。ここに表示される項目としては、印刷したい範囲の先頭写真番号、指定コマ番号(開始/−指定)、印刷を終了したい範囲の最後の写真番号(終了)、印刷部数(部数)、印刷に使用する用紙(記録シート)の種類(用紙種類)、1枚の用紙に印刷する写真の枚数設定(レイアウト)、印刷の品位の指定(品位)、撮影した日付を印刷するかどうかの指定(日付印刷)、写真を補正して印刷するかどうかの指定(画像補正)、印刷に必要な用紙枚数の表示(用紙枚数)等がある。これら各項目は、カーソルキー2001を用いて選択、或いは指定される。従来例で述べた補正処理は、この画像補正の項目で選択される。例えば、カーソルキーにより   In the figure, the liquid crystal display unit 1006 displays menu items for setting various data relating to items printed on the left and right. The items displayed here are the first photo number of the range to be printed, the designated frame number (start / -designate), the last photo number of the range to be printed (end), the number of copies (number of copies), and used for printing. Type of paper (recording sheet) to be printed (paper type), setting of the number of photos to be printed on one sheet (layout), specification of print quality (quality), and whether to print the date of shooting (date printing) ), Designation of whether or not to print a photograph (image correction), display of the number of sheets necessary for printing (number of sheets), and the like. These items are selected or designated using the cursor keys 2001. The correction processing described in the conventional example is selected in this image correction item. For example, by cursor key

Figure 2009038582
のように表示がトグルし、ユーザーが選択出来るようになる。
Figure 2009038582
The display toggles like so that the user can select.

2002はモードキーで、このキー2002を押下する毎に、印刷の種類(インデックス印刷、全コマ印刷、1コマ印刷等)を切り替えることができ、これに応じてLED2003の対応するLEDが点灯される。2004はメンテナンスキーで、記録ヘッド1301のクリーニング等、プリンタのメンテナンスや印刷領域指定モードに入るためのキーである。2005は印刷開始キーで、印刷の開始を指示する時、或いはメンテナンスの設定を確立する際に押下される。2006は印刷中止キーで、印刷を中止させる時や、メンテナンスの中止を指示する際に押下される。   2002 is a mode key, and each time the key 2002 is pressed, the type of printing (index printing, full-frame printing, single-frame printing, etc.) can be switched, and the corresponding LED of the LED 2003 is lit accordingly. . Reference numeral 2004 denotes a maintenance key, which is used to enter a printer maintenance or print area designation mode such as cleaning of the recording head 1301. Reference numeral 2005 denotes a print start key which is pressed when instructing the start of printing or when establishing maintenance settings. Reference numeral 2006 denotes a print cancel key which is pressed when printing is stopped or when maintenance is instructed.

次に図4を参照して、本実施の形態に係るフォトダイレクトプリンタ装置1000の制御に係る主要部の構成を説明する。3000は制御部(制御基板)を示している。3001はASIC(専用カスタムLSI)、3002はDSP(デジタル信号処理プロセッサ)で、内部にCPUを有し、後述する画像処理等を担当している。3003はメモリで、DSP3002のCPUの制御プログラムを記憶するプログラムメモリ3003a、及び実行時のプログラムを記憶するRAMエリア,画像データなどを記憶するワークメモリとして機能するメモリエリアを有している。3004はプリンタエンジンで、ここでは、複数色のカラーインクを用いてカラー画像を印刷するインクジェットプリンタのプリンタエンジンが搭載されている。3005はデジタルカメラ3012を接続するためのポートとしてのUSBバスコネクタである。3006はビューワ1011を接続するためのコネクタである。3008はUSBバスハブ(USB HUB)で、このプリンタ装置1000がPC3010からの画像データに基づいて印刷を行う際には、PC3010からのデータをそのままスルーし、USBバス3021を介してプリンタエンジン3004に出力する。これにより、接続されているPC3010は、プリンタエンジン3004と直接、データや信号のやり取りを行って印刷を実行することが出来る(一般的なPCプリンタとして機能する)。3009は電源コネクタで、電源3013により、商用ACから変換された直流電圧を入力している。PC3010は一般的なパーソナルコンピュータ、3011は前述したメモリカード(PCカード)、3012はデジタルカメラである。尚、この制御部3000とプリンタエンジン3004との間の信号のやり取りは、前述したUSBバス3021又はIEEE1284バス3022を介して行われる。   Next, with reference to FIG. 4, the configuration of the main part relating to the control of the photo direct printer 1000 according to the present embodiment will be described. Reference numeral 3000 denotes a control unit (control board). Reference numeral 3001 denotes an ASIC (dedicated custom LSI), and 3002 a DSP (digital signal processor), which has an internal CPU and is in charge of image processing and the like to be described later. A memory 3003 has a program memory 3003a that stores a control program for the CPU of the DSP 3002, a RAM area that stores a program at the time of execution, and a memory area that functions as a work memory that stores image data and the like. Reference numeral 3004 denotes a printer engine. Here, a printer engine of an ink jet printer that prints a color image using a plurality of color inks is installed. Reference numeral 3005 denotes a USB bus connector as a port for connecting the digital camera 3012. Reference numeral 3006 denotes a connector for connecting the viewer 1011. Reference numeral 3008 denotes a USB bus hub (USB HUB). When the printer apparatus 1000 performs printing based on image data from the PC 3010, the data from the PC 3010 is directly passed through and output to the printer engine 3004 via the USB bus 3021. To do. As a result, the connected PC 3010 can directly perform printing by exchanging data and signals with the printer engine 3004 (functions as a general PC printer). Reference numeral 3009 denotes a power connector which inputs a DC voltage converted from commercial AC by a power source 3013. A PC 3010 is a general personal computer, 3011 is the memory card (PC card) described above, and 3012 is a digital camera. Note that the exchange of signals between the control unit 3000 and the printer engine 3004 is performed via the USB bus 3021 or the IEEE 1284 bus 3022 described above.

図5に、本実施系における画像処理ブロック図を示す。メモリカードから画像を取得し、プリンタが出力可能なデータの形式にするまでのブロックとなっている。各ブロックにおける処理内容を説明する。   FIG. 5 shows a block diagram of image processing in the present embodiment. It is a block from acquiring an image from a memory card to a data format that can be output by a printer. Processing contents in each block will be described.

(JPEG復号化処理部)
デジタルカメラで最も利用されている画像フォーマットは、JPEG(Joint Photographic Experts Group)形式である。本実施例では、メモリカード内にJPEG画像があることを想定する。本出願では、そのデコード方法の詳細は本質ではないので割愛するが、主要な処理として、エントロピー符号の展開(復号化)処理、逆量子化処理、逆DCT変換処理となる。
(JPEG decoding processing unit)
The most used image format in digital cameras is the JPEG (Joint Photographic Experts Group) format. In this embodiment, it is assumed that there is a JPEG image in the memory card. Although details of the decoding method are not essential in this application, they are omitted, but the main processes are entropy code expansion (decoding) processing, inverse quantization processing, and inverse DCT transformation processing.

(逆光補正係数決定部)
デコードされた画像データは、逆光補正が必要であれば逆光補正係数決定部で、その係数が決定される。逆光補正の処理方法は、幾つかあるが本実施例では、自動で人肌部分を検出し、その輝度値から補正量を算出する方法を挙げる。
(Backlight correction coefficient determination unit)
If the decoded image data requires backlight correction, its coefficient is determined by the backlight correction coefficient determination unit. Although there are several backlight correction processing methods, in this embodiment, a method of automatically detecting a human skin portion and calculating a correction amount from the luminance value is given.

図6に、逆光補正係数決定処理のフロー図を示す。STEP601は人肌判定用データ生成部である。色判定用と周波数判定用の2つデータが生成される。色判定用データとしては、上述のデコード処理により画像の展開が実行され、輝度Y色差CbCr成分の画像データが得られる。これらはSTEP602に送られ、ITU-R BT.601に準拠した下記式によりRGBデータに変換される。   FIG. 6 shows a flowchart of the backlight correction coefficient determination process. STEP 601 is a human skin determination data generation unit. Two data for color determination and frequency determination are generated. As the color determination data, image expansion is executed by the decoding process described above, and image data of luminance Y color difference CbCr component is obtained. These are sent to STEP 602 and converted into RGB data by the following equation in conformity with ITU-R BT.601.

R=Y+1.402(Cr−128)
G=Y−0.34414(Cb−128)−0.71414(Cr−128)
B=Y+1.772(Cb−128)
得られたRGBデータを利用し、STEP603において、色判定処理を実行する。判定条件としては、従来技術で記載した式(4)などが挙げられる。これらの判定処理は、後述するSTEP604での処理を考慮すると、全ての画素について実行する必要はなく、8x8単位での判定で構わない。8x8ブロック内での、RGB各平均値を算出ししての判定でも良いし、予め設定された点、例えば四隅の点による判定を行っても良い。このSTEP603の処理により、色として人肌の条件を満たしているか否かが判定が実行される。
R = Y + 1.402 (Cr-128)
G = Y−0.34414 (Cb−128) −0.71414 (Cr−128)
B = Y + 1.772 (Cb-128)
In step 603, color determination processing is executed using the obtained RGB data. As the determination condition, Formula (4) described in the related art may be used. These determination processes need not be executed for all pixels in consideration of the process in STEP 604 described later, and may be determined in units of 8 × 8. The determination may be made by calculating the respective RGB average values in the 8 × 8 block, or may be determined by a preset point, for example, four corner points. By the processing in STEP 603, it is determined whether or not the condition of human skin is satisfied as a color.

一方、STEP601は人肌判定用データ生成部では、逆量子化後の逆DCT変換処理を実行する前のJPEGの8x8のMCU単位で格納されている輝度Yに関する周波数データをメモリに格納する。図7は、JPEGにおける8x8のMCUを表した図である。左上のDC成分のほか、AC成分のDCT係数が格納されている。左上が低周波成分を表し、右下に行くにつれ高周波成分となっている。STEP604では、このAC成分のDCT係数と予め準備されたパラメータとの比較により、肌に適した周波数か否かの判定を行う。パラメータとしては、高周波成分がある一定以上含まれている場合は、肌に適さないと判定するように設定される。低周波成分についても、極端に強すぎる場合は、肌でないと判定するよう設定することも可能である。また、AC成分のDCT係数63個全てについてのパラメータを用意し、比較すると処理時間を多く要したり、パラメータ数が多くなってしまったりするので、ある決められたポイント点での比較としても良い。また、一定区間の平均値を求め、その比較としても構わない。図8に、AC成分を7分割した場合を示す。各区間での平均値と予め設定された値との比較となり、この場合、7回の比較処理で人肌周波の判定が実行される。このSTEP604の処理により、周波数として人肌の条件を満たしているかの判定が実行される。   On the other hand, in STEP 601, the human skin determination data generation unit stores frequency data relating to luminance Y stored in JPEG 8 × 8 MCU units before executing inverse DCT conversion processing after inverse quantization. FIG. 7 is a diagram showing an 8 × 8 MCU in JPEG. In addition to the DC component at the upper left, the DCT coefficient of the AC component is stored. The upper left represents a low frequency component, and the lower left is a high frequency component. In STEP 604, whether or not the frequency is suitable for the skin is determined by comparing the DCT coefficient of the AC component with a parameter prepared in advance. The parameter is set so as to determine that it is not suitable for the skin when a high-frequency component is included in a certain amount or more. The low frequency component can also be set to be determined as not being skin if it is extremely strong. In addition, since parameters for all 63 DCT coefficients of the AC component are prepared and compared, a long processing time or a large number of parameters may be required, so comparison may be made at a predetermined point. . Further, an average value in a certain section may be obtained and compared. FIG. 8 shows a case where the AC component is divided into seven parts. The average value in each section is compared with a preset value. In this case, human skin frequency is determined by seven comparison processes. By the processing of STEP 604, it is determined whether the frequency satisfies the condition of human skin.

STEP605では、STEP603および604で判定された結果を受け取り、共に人肌の条件を満たしていると判定した場合は、その8x8ブロックが人肌との認定をする。   In STEP 605, when the result determined in STEPs 603 and 604 is received and it is determined that both satisfy the condition of human skin, the 8 × 8 block is recognized as human skin.

STEP606で画像全体に対して人肌判定がされたかを判定し、もしされていない場合は、SETP601からSTEP606を繰り返す。   In STEP 606, it is determined whether the human skin is determined for the entire image. If not, the steps from SETP 601 to STEP 606 are repeated.

画像全てに対し判定処理が実行された場合は、STEP607へと進み、補正係数を決定する。本実施例では、補正係数として輝度変換テーブルを作成する。これは例えば、輝度Y成分に対し、どのような値にすればよいかを示した対応が格納されたテーブルである。入力が8ビットであればエントリが256のテーブルとなる。出力結果は0〜255の8ビットでも構わないが、階調損失を考慮すると、8ビットよりも多い出力の方が望ましい。   If the determination process has been executed for all the images, the process proceeds to STEP 607 and a correction coefficient is determined. In this embodiment, a brightness conversion table is created as a correction coefficient. This is, for example, a table storing correspondence indicating what value should be set for the luminance Y component. If the input is 8 bits, the entry is a table of 256. The output result may be 8 bits from 0 to 255, but in consideration of gradation loss, an output with more than 8 bits is desirable.

決定方法は、STEP5で人肌と判定されたブロックの輝度値を利用する。人肌ブロックの輝度平均Y人肌を算出することにより、画像中の人肌部分の明るさの指標を取得出来る。その値を予め設定されたあるターゲット輝度YTARGET、例えば輝度を10%アップする
TARGET=Y人肌×k
(k=1.1)
となるような、テーブルを生成することにより、人肌部分を明るくする係数が求められる。より適切な係数を求めるために、人肌の輝度値に応じてターゲット輝度へのアップ率を変化させたり、画像全体の輝度値Y全体輝度を考慮し、それによりターゲット輝度を変化させたりすることも可能である。
The determination method uses the luminance value of the block determined as human skin in STEP5. By calculating the luminance average Y human skin of the human skin block, the brightness index of the human skin portion in the image can be acquired. The target brightness Y TARGET that is set in advance is set, for example, the brightness is increased by 10%. Y TARGET = Y human skin × k
(K = 1.1)
A coefficient that brightens the human skin portion is obtained by generating a table such that In order to obtain a more appropriate coefficient, the increase rate to the target luminance is changed according to the luminance value of the human skin, or the target luminance is changed by considering the luminance value Y overall luminance of the entire image. Is also possible.

TARGET=Y人肌×k(Y全体輝度
求められたターゲット輝度から図9に示すような変換テーブルLUTY(逆光)を作成する。作成方法としては、直線で繋ぐ方法、またはそれにスムージング処理を行う方法、近似曲線を求める方法など、階調の急激な飛びがない作成方法が挙げられる。
Y TARGET = Y human skin x k (Y overall brightness )
A conversion table LUT Y (backlight) as shown in FIG. 9 is created from the obtained target luminance. Examples of the creation method include a creation method that does not cause a sharp jump in gradation, such as a method of connecting with a straight line, a method of performing smoothing thereto, or a method of obtaining an approximate curve.

NEW=LUTY(逆光)[YORG
また、輝度アップに伴い、彩度低下が発生するので、それを補正する必要がある。これは、輝度の増加率により変化し、
(逆光)=f(YNEW−YORG
により、算出される、元々の色差成分CbORG、CrORGに対して、下記記のように適用され、CbNEW、CrNEWが、求められる。
Y NEW = LUT Y (backlight) [Y ORG ]
Further, as the luminance increases, the saturation decreases, and it is necessary to correct it. This varies with the rate of increase in brightness,
S (backlight) = f (Y NEW -Y ORG )
Is applied to the original color difference components Cb ORG and Cr ORG calculated as follows , and Cb NEW and Cr NEW are obtained.

CbNEW=CbORG×S(逆光)
CrNEW=CrORG×S(逆光)
(色かぶり補正係数決定部)
色かぶり補正の係数決定は、従来技術で述べたように、輝度ヒストグラムから移動量を求め、その移動を実現する係数の決定となる。
Cb NEW = Cb ORG × S (backlight)
Cr NEW = Cr ORG × S (Backlight)
(Color cast correction coefficient determination unit)
As described in the prior art, the determination of the color fog correction coefficient is to determine the coefficient for obtaining the movement amount from the luminance histogram and realizing the movement.

まず、画像のデコード処理を行い、JPEG画像を展開する。展開されたYCbCrについて、Y成分のみの累積を行い、輝度ヒストグラムを生成する。ここで画像全体のデコード処理を行うと、ヒストグラム作成までに、時間を要することになるほか、多くのメモリを消費するので、画像をMCU単位間引きながら展開することも可能である。また、JPEGのDC成分のみを利用し、逆DCT変換を行うことを省略する方法も考えられる。   First, an image decoding process is performed to develop a JPEG image. For the developed YCbCr, only the Y component is accumulated to generate a luminance histogram. If the decoding process for the entire image is performed here, it takes time to create the histogram, and a lot of memory is consumed. Therefore, it is possible to develop the image while thinning out the MCU units. Another possible method is to use only the DC component of JPEG and omit performing inverse DCT conversion.

図1(a)は、色かぶりと露出がアンダーになっている画像の輝度ヒストグラムの一例である。この輝度ヒストグラムでは本来白であるべき点が白でないことを表している。そこで、全画素数の上から数パーセントに当たる輝度をハイライトポイント(YHL)、下から数パーセントに当たる輝度をシャドーポイント(YSD)と決定する。一般的にハイライトポイント、シャドーポイントは、それぞれ上(Y=255)および下(Y=0)から全画素数の0〜5%程度である。そして、この輝度YHLが白 、輝度YSDが黒となるように変換を行う。 FIG. 1A shows an example of a luminance histogram of an image in which the color cast and the exposure are under. In this luminance histogram, the point that should be white is not white. Therefore, the luminance corresponding to several percent from the top of the total number of pixels is determined as the highlight point (Y HL ), and the luminance corresponding to several percent from the bottom is determined as the shadow point (Y SD ). Generally, the highlight point and the shadow point are about 0 to 5% of the total number of pixels from the top (Y = 255) and the bottom (Y = 0), respectively. Then, the conversion is performed so that the luminance YHL is white and the luminance YSD is black.

HL=255
SD=0
また、上式のように変換を行った場合、輝度0〜YSD、YHL〜255間の階調が失われる恐れがあるので、下式に示すようにYHLを255よりもわずかに低い値Y255′、YSDを0よりもわずかに高い値Y0′に設定することにより階調損失を防ぐことが出来る。
Y HL = 255
Y SD = 0
Further, when it was converted to the above equation, the luminance 0 to Y SD, since gradation between Y HL to 255 is likely to be lost, slightly lower than the 255 Y HL as shown in the following formula value Y255 ', the Y SD slightly higher value Y0 than 0' it is possible to prevent a tone loss by setting.

HL=Y255′ (但し、Y255′≒255)
SD=Y′ (但し、Y′≒0)
このようなハイライトポイントおよびシャドーポイントの輝度を設定する変換を画像全体に施すことにより、露出がアンダーやオーバーしている画像は改善される。
Y HL = Y 255 ′ (Y 255 ′ ≈255)
Y SD = Y 0 ′ (however, Y 0 ′ ≈0)
By performing conversion for setting the brightness of the highlight point and the shadow point on the entire image, an image with underexposed or overexposed images is improved.

さらに画像の色差信号Cb、Crに色かぶりの補正を行う。白であるための条件は
Cb=Cr=0 かつ Y=255
である。同様にシャドーポイントの画素は黒となるべきであり、その条件は
Cb=Cr=0 かつ Y=0
となる。ハイライトポイントおよびシャドーポイントの輝度となる画素の色差信号の平均をそれぞれ(CbHL,CrHL)、(CbSD,CrSD)とすると、色かぶりのしている画像の場合
CbHL≠0 または CrHL≠0
CbSD≠0 または CrSD≠0
となってしまっている。そこで、色かぶりを補正するためには、(CbHL,CrHL)、(CbSD,CrSD)をそれぞれ本来の白、黒の値に変換する。その方法の一例としては図10に示すようなハイライトポイントとシャドーポイントを通る色立体の線を考え、その線が輝度軸とに重なるようにすればよい。それは、下記式により実現出来る。
Further, color fog correction is performed on the color difference signals Cb and Cr of the image. The condition for white is Cb = Cr = 0 and Y = 255
It is. Similarly, the shadow point pixel should be black, and the condition is Cb = Cr = 0 and Y = 0.
It becomes. If the average of the color difference signals of the pixels having the luminance at the highlight point and the shadow point is (Cb HL , Cr HL ) and (Cb SD , Cr SD ), respectively, Cb HL ≠ 0 or Cr HL ≠ 0
Cb SD ≠ 0 or Cr SD ≠ 0
It has become. Therefore, in order to correct the color cast, (Cb HL , Cr HL ) and (Cb SD , Cr SD ) are converted into original white and black values, respectively. As an example of the method, a color solid line passing through a highlight point and a shadow point as shown in FIG. 10 may be considered, and the line may be overlapped with the luminance axis. It can be realized by the following formula.

Figure 2009038582
ここでYNEW、CbNEW、CrNEWは、それぞれ変換後の輝度、色差を表し、YORG、CbORG、CrORGは、それぞれ変換前の輝度、色差を表す。色かぶり補正係数決定部では上記3x3マトリクスを算出する。
Figure 2009038582
Here, Y NEW , Cb NEW , and Cr NEW represent luminance and color difference after conversion, respectively, and Y ORG , Cb ORG , and Cr ORG represent luminance and color difference before conversion, respectively. The color cast correction coefficient determination unit calculates the 3 × 3 matrix.

また、本実施例では、色かぶり補正が選択された場合、同時にコントラスト補正および彩度強調することにより、補正をより効果的にする。そのために、輝度ヒストグラムの分布から、コントラスト強調度を求め、コントラストを強める場合には、変換テーブルLUTY(コントラスト)を作成し、
NEW=LUTY(コントラスト)[YORG
の補正を実行する。彩度補正については、画像全体の平均彩度を算出し、彩度強調係数S(強調)を求め、
CbNEW=CbORG×S(強調)
CrNEW=CrORG×S(強調)
により彩度強調を実現する。
In this embodiment, when color cast correction is selected, the correction is made more effective by simultaneously performing contrast correction and saturation enhancement. Therefore, when the contrast enhancement degree is obtained from the distribution of the luminance histogram and the contrast is strengthened, a conversion table LUT Y (contrast) is created,
Y NEW = LUT Y (contrast) [Y ORG ]
Perform the correction. For saturation correction, the average saturation of the entire image is calculated, the saturation enhancement coefficient S (emphasis) is obtained,
Cb NEW = Cb ORG × S (emphasis)
Cr NEW = Cr ORG × S (emphasis)
To achieve saturation enhancement.

(補正処理部)
補正処理部においては、上記で求められた、逆光補正に関する補正係数LUTY(逆光)
彩度補正係数S(逆光)、色かぶり補正やコントラスト補正、彩度強調の補正係数、3x3マトリクス、LUTY(コントラスト)、S(強調)、などを画像に適用する。
(Correction processor)
In the correction processing unit, the correction coefficient LUT Y (backlight) relating to the backlight correction obtained above,
Saturation correction coefficient S (backlight) , color cast correction, contrast correction, saturation enhancement correction coefficient, 3 × 3 matrix, LUT Y (contrast) , S (enhancement) , etc. are applied to the image.

この際、逆光補正、色かぶり補正(コントラスト補正および彩度強調を含む)が同時に選択された場合、それぞれの処理を適宜施していると処理時間が多くかかってしまう。そこで、輝度および彩度に関する補正においては、処理を開始する前に、下記色によりテーブルを結合させることが可能である。   At this time, if backlight correction and color cast correction (including contrast correction and saturation enhancement) are selected at the same time, it takes a lot of processing time if the respective processes are appropriately performed. Therefore, in the correction relating to luminance and saturation, it is possible to combine tables with the following colors before starting the processing.

(逆光+コントラスト)=LUTY(逆光)[YORG]×LUTY(コントラスト)[YORG
(逆光+強調)=S(逆光)×S(強調)
求められた、Y(逆光+コントラスト)、S(逆光+強調)でのみ処理を施すことにより、各々の処理を施す場合と同等の効果が実現出来る。
Y (backlight + contrast) = LUT Y (backlight) [Y ORG ] × LUT Y (contrast) [Y ORG ]
S (backlight + enhancement) = S (backlight) x S (emphasis)
By performing the processing only with the obtained Y (backlight + contrast) and S (backlight + enhancement) , it is possible to achieve the same effect as when each processing is performed.

(変倍処理部)
選択された画像のピクセル数、選択された用紙サイズから、拡大・縮小の変倍率が決定される。変倍方法については、単純拡大・縮小やバイリニア法、バイキュービック法など幾つか方法が挙げられる。そのどれを選択するかは、そのシステム環境および求められる処理速度により、決定される。上述の各変倍手段については、本提案の本質とはならないので割愛する。
(Scaling processing unit)
The scaling factor for enlargement / reduction is determined from the number of pixels of the selected image and the selected paper size. As the scaling method, there are several methods such as simple enlargement / reduction, bilinear method, and bicubic method. Which one to select is determined by the system environment and the required processing speed. The above-described scaling means will be omitted because they are not the essence of this proposal.

(色変換処理部)
色変換処理部では、入力された信号YCbCr乃至RGBのデータに対し、プリンタのデバイス色への色変換を行う。例えば、6種類のインクを積載したプリンタであれば、シアン(C)、マゼンタ(M)、イエロー(Y)、ブラック(K)、淡いシアン(LC)、淡いマゼンタ(LM)の信号に変換する。入力をRGB信号値とすると、(R,G,B)→(C,M,Y,K,LC,LM)の変換となる。
(Color conversion processor)
The color conversion processing unit converts the input signals YCbCr through RGB data into a printer device color. For example, in the case of a printer loaded with six types of ink, the signals are converted into cyan (C), magenta (M), yellow (Y), black (K), light cyan (LC), and light magenta (LM) signals. . If the input is an RGB signal value, the conversion is (R, G, B) → (C, M, Y, K, LC, LM).

変換方法としては、いくつかの方法があるが、ここではルックアップテーブル(以下、LUT)と補間処理を用いた方法を一例として挙げる。   There are several conversion methods, but here, a method using a look-up table (hereinafter referred to as LUT) and interpolation processing is taken as an example.

事前に用意しておくLUTは、図11に示すようなRGB値をそれぞれ16レベルずつに16分割した4913点に対応するC,M,Y,K,LC,LM信号値が記述されており、入力R,G,Bの値に応じたC,M,Y,K,LC,LM値が参照される。R,G,Bの値が16分割した間にある場合は、補間処理によって求める。   The LUT prepared in advance describes C, M, Y, K, LC, and LM signal values corresponding to 4913 points obtained by dividing the RGB values as shown in FIG. 11 into 16 levels each. The C, M, Y, K, LC, and LM values corresponding to the values of the inputs R, G, and B are referred to. When the values of R, G, and B are between 16 divisions, they are obtained by interpolation processing.

補間方法の例として、四面体補間法を挙げる。四面体補間法とは、3次元空間の分割単位を四面体として、4つの格子点を用いる線形補間である。その手順として、まず図12(a)に示すように四面体への分割を行う。そして、ターゲットとなる点pが分割されたどの四面体に属するかを決定する。その四面体の4頂点をp0、p1、p2、p3とし、図12(b)に示すようにさらに細かい小四面体に分割される。また、拡張点の変換値をそれぞれf(p0)、f(p1)、f(p2)、f(p3)とすると、   An example of the interpolation method is a tetrahedral interpolation method. The tetrahedral interpolation method is linear interpolation using four grid points with a unit of three-dimensional space as a tetrahedron. As the procedure, first, as shown in FIG. Then, the tetrahedron to which the target point p belongs is determined. The four vertices of the tetrahedron are defined as p0, p1, p2, and p3, and are divided into smaller tetrahedrons as shown in FIG. Also, if the conversion values of the extension points are f (p0), f (p1), f (p2), and f (p3), respectively,

Figure 2009038582
より求まる。ここで、w0、w1、w2、w3は、各頂点piと反対向位置の小四面体の体積比である。これにより、インク色C,M,Y,K,LC,LMへの変換が行われる。
Figure 2009038582
More. Here, w0, w1, w2, and w3 are volume ratios of the small tetrahedrons at positions opposite to each vertex pi. Thereby, conversion to ink colors C, M, Y, K, LC, and LM is performed.

(量子化処理部)
インク色に変換されたデータは、量子化処理が施される。これは、多ビットのデータを記録装置で記録可能なビット数に変換するものである。本実施例では、記録(1)/非記録(0)の1ビット2値であるインクジェットプリンターの場合を考える。ここで、量子化方法としては、写真画像の量子化に最適となる誤差拡散法とする。また、入力信号は8ビットの0〜255とする。
(Quantization processing unit)
The data converted into the ink color is subjected to quantization processing. This converts multi-bit data into the number of bits that can be recorded by a recording apparatus. In the present embodiment, a case of an inkjet printer having 1 bit / binary of recording (1) / non-recording (0) is considered. Here, the quantization method is an error diffusion method that is optimal for the quantization of photographic images. The input signal is 8 bits from 0 to 255.

図13は誤差拡散法における、誤差分配方法を示す図である。ターゲットピクセルの信号値をL(0≦L≦255)とした時、しきい値THと比較を行う。その大小により、
L>TH ・・・・・・ 1(記録)
L≦TH ・・・・・・ 0(非記録)
と判定される。その時に発生する誤差E(=L−TH)は、図13の分配係数に従い周囲のピクセルに分配される。この処理をすべてのピクセル、すべてのインク色色C,M,Y,K,LC,LMに対して行うことで、1ビットの画像データ色C',M',Y',K',LC',LM'に量子化される。
FIG. 13 is a diagram showing an error distribution method in the error diffusion method. When the signal value of the target pixel is L (0 ≦ L ≦ 255), it is compared with the threshold value TH. Depending on its size,
L> TH ・ ・ ・ ・ ・ ・ 1 (Recording)
L ≦ TH ・ ・ ・ ・ ・ ・ 0 (not recorded)
It is determined. The error E (= L−TH) generated at that time is distributed to surrounding pixels according to the distribution coefficient shown in FIG. By performing this processing for all pixels and all ink color colors C, M, Y, K, LC, and LM, 1-bit image data colors C ′, M ′, Y ′, K ′, LC ′, Quantized to LM ′.

次に各処理ブロックがどのように実行されるかを図14に示す処理フローを使用して説明する。   Next, how each processing block is executed will be described using the processing flow shown in FIG.

(補正が選択されていない場合)
最初にSTEP1401およびにおいて、ユーザーにより、色かぶり補正または逆光補正が選択されていないかを判別する。ここで、いずれも選択されていない場合は、補正処理は一切行われない通常のフローとなる。STEP1402へと進み、JPEGのデコード処理を行った後、STEP1403の補正処理へと送られる。補正係数は、初期化処理(図示せず)において、何も施されていない値
3x3マトリクス:
(When no correction is selected)
First, in STEP 1401 and whether or not color fog correction or backlight correction is selected by the user. Here, when none is selected, the normal flow is performed without any correction processing. After proceeding to STEP 1402, JPEG decoding processing is performed, and then sent to STEP 1403 correction processing. The correction coefficient is a value that has not been applied in an initialization process (not shown) 3 × 3 matrix:

Figure 2009038582
LUT:Y=Xのリニアな直線
S:1.00
が記述されているので、STEP1403が行われてもデータは不変である。処理負荷を減らしたいのであれば、STEP1401の判定の結果により、STEP1403をスキップすることも可能である。その後、STEP1404の変倍処理が実行され、STEP1405の色変換処理、続いてSTEP1406の量子化処理が実行される。量子化後のデータ、プリンタに送信され、プリンタはこのデータに基づいて記録を行う(図示せず)。STEP1413において、全ての画素が終了したかの判定を行い、もしそうでなければSTEP1402へと戻る。これを全ての画素について行い、終了となる。
Figure 2009038582
LUT: Y = X linear straight line S: 1.00
Therefore, even if STEP 1403 is performed, the data is not changed. If it is desired to reduce the processing load, STEP 1403 can be skipped based on the determination result of STEP 1401. Thereafter, the scaling process of STEP 1404 is executed, the color conversion process of STEP 1405, and the quantization process of STEP 1406 are executed. The quantized data is transmitted to the printer, and the printer performs recording based on this data (not shown). In STEP1413, it is determined whether all the pixels have been completed. If not, the process returns to STEP1402. This is performed for all the pixels, and the process ends.

(色かぶり補正のみが選択されている場合)
同様に図14を使用し、パネル操作で色かぶり補正のみが選択された場合のフローについて説明する。
(When only color cast correction is selected)
Similarly, a flow when only color cast correction is selected by panel operation will be described with reference to FIG.

STEP1401の判定により、色かぶり補正が選択されているので、STEP1407へと進む。   Since color cast correction is selected according to the determination in STEP 1401, the process proceeds to STEP 1407.

STEP1407では、上述したようにデコード処理を行い、色かぶり補正係数の3x3マトリクスおよびコントラスト補正係数LUTY(コントラスト)、彩度強調係数S(強調)を求める。 In STEP 1407, the decoding process is performed as described above to obtain a 3 × 3 matrix of color fog correction coefficients, a contrast correction coefficient LUT Y (contrast) , and a saturation enhancement coefficient S (enhancement) .

STEP1408で、逆行補正の選択有無の判定を行い、本ケースであれば、STEP1402のJPEGデコード処理へと進む。ここから先は、[補正が選択されていない場合]と同等の処理になる。但し、STEP1403においての補正係数は、STEP1407で求められた係数が使用される。これにより、色かぶり補正を実現し、さらにコントラスト補正、彩度強調処理を行う。   In STEP 1408, it is determined whether or not reverse correction is selected. If this is the case, the process proceeds to STEP 1402 for JPEG decoding. From this point onward, the processing is equivalent to [when no correction is selected]. However, the coefficient obtained in STEP 1407 is used as the correction coefficient in STEP 1403. Thus, color cast correction is realized, and further contrast correction and saturation enhancement processing are performed.

(逆光補正のみが選択されている場合)
同様に図14を使用し、パネル操作で逆光補正のみが選択された場合のフローについて説明する。
(When only backlight compensation is selected)
Similarly, FIG. 14 will be used to explain the flow when only backlight correction is selected by panel operation.

STEP1401の判定により、逆光補正が選択されているので、STEP1407へと進む。   As the backlight correction is selected based on the determination in STEP1401, the process proceeds to STEP1407.

STEP1407では、上述したようにデコード処理を行い、色かぶり補正係数の3x3マトリクスおよびコントラスト補正係数LUTY(コントラスト)、彩度強調係数S(強調)を求める。 In STEP 1407, the decoding process is performed as described above to obtain a 3 × 3 matrix of color fog correction coefficients, a contrast correction coefficient LUT Y (contrast) , and a saturation enhancement coefficient S (enhancement) .

STEP1408で、逆行補正の選択有無の判定を行い、本ケースであれば、STEP1409へと進む。ここでは、逆光補正用の人肌判定に用いる色判定用データおよび周波数判定データを生成する。色判定用データについては、メモリ上に8x8ブロックを表すRGBデータが出力される。これらのデータは、ITU-R BT.601に準拠した下記式によりYCbCr変換される。   In STEP 1408, it is determined whether or not reverse correction is selected. If this is the case, the process proceeds to STEP 1409. Here, color determination data and frequency determination data used for human skin determination for backlight correction are generated. For the color determination data, RGB data representing an 8 × 8 block is output on the memory. These data are subjected to YCbCr conversion by the following formula compliant with ITU-R BT.601.

Y=0.900×R+0.587×G+0.114×B
Cb=(−0.299×R−0.587×G+0.886×B)
×0.564+128
Cr=(0.701×R−0.587×G−0.114×B)
×0.713+128
変換されたYCbCrデータに対し、STEP1407で生成した色かぶり補正係数の3x3マトリクスおよびコントラスト補正係数LUTY(コントラスト)、彩度強調係数S(強調)を施し、再度、
R=Y+1.402(Cr−128)
G=Y−0.34414(Cb−128)−0.71414(Cr−128)
B=Y+1.772(Cb−128)
により、RGB信号値に戻される。
Y = 0.900 × R + 0.587 × G + 0.114 × B
Cb = (− 0.299 × R−0.587 × G + 0.886 × B)
× 0.564 + 128
Cr = (0.701 × R−0.587 × G−0.114 × B)
× 0.713 + 128
The converted YCbCr data is subjected to the 3 × 3 matrix of the color fog correction coefficient generated in STEP 1407, the contrast correction coefficient LUT Y (contrast) , and the saturation enhancement coefficient S (enhancement) , and again,
R = Y + 1.402 (Cr-128)
G = Y−0.34414 (Cb−128) −0.71414 (Cr−128)
B = Y + 1.772 (Cb-128)
Thus, the RGB signal value is restored.

STEP1410では、上記変換されたRGBデータを利用することにより、色かぶりを補正した画像に対し色判定を行い、同時に周波数成分の判定を実行する。これにより、求められた人肌輝度値から、適性に明るくする補正係数を決定する。   In STEP 1410, by using the converted RGB data, color determination is performed on the image with the color cast corrected, and frequency component determination is performed at the same time. Thus, a correction coefficient for appropriately brightening is determined from the obtained human skin luminance value.

その後、STEP1411で、色かぶり補正の判定を行い、本ケースではSTEP1412へと進む。STEP1412では、色かぶり補正が実際には実行はしないように、3x3マトリクスについてはデフォルト値(単位行列)へと戻す処理が行われる。   Thereafter, in STEP 1411, color fog correction is determined, and in this case, the process proceeds to STEP 1412. In STEP 1412, a process of returning the 3 × 3 matrix to a default value (unit matrix) is performed so that the color cast correction is not actually executed.

この後、STEP1402へと進み、ここから先は、[補正が選択されていない場合]と同等の処理になる。但し、本ケースの場合、STEP1403においての補正係数は、色かぶり補正に関する係数についてはデフォルトの何もしないもの、輝度を変換する逆光補正に関する係数については、STEP1410で求められた値が使用される。これにより、色かぶりなどを起こしている画像に対しての的確な逆光補正が実現される。   Thereafter, the process proceeds to STEP 1402 and the processing from here is the same as [when correction is not selected]. However, in this case, as the correction coefficient in STEP 1403, the default value is not used for the coefficient relating to the color cast correction, and the value obtained in STEP 1410 is used for the coefficient related to the backlight correction for converting the luminance. As a result, accurate backlight correction is realized for an image in which color cast or the like has occurred.

(色かぶり補正および逆光補正が両方選択されている場合)
同様に図14を使用し、パネル操作で色かぶり補正および逆光補正が選択された場合のフローについて説明する。
(When color cast correction and backlight correction are both selected)
Similarly, FIG. 14 will be used to explain the flow when color cast correction and backlight correction are selected by panel operation.

STEP1401の判定により、色かぶり補正、逆光補正が共に選択されているので、STEP1407へと進む。   Since both color fog correction and backlight correction are selected according to the determination in STEP 1401, the process proceeds to STEP 1407.

STEP1407では、上述したようにデコード処理を行い、色かぶり補正係数の3x3マトリクスおよびコントラスト補正係数LUTY(コントラスト)、彩度強調係数S(強調)を求める。 In STEP 1407, the decoding process is performed as described above to obtain a 3 × 3 matrix of color fog correction coefficients, a contrast correction coefficient LUT Y (contrast) , and a saturation enhancement coefficient S (enhancement) .

STEP1408で、逆行補正の選択有無の判定を行い、本ケースであれば、STEP1409のへと進む。ここでは、逆光補正用の人肌判定に用いる色判定用データおよび周波数判定データを生成する。色判定用データについては、メモリ上に8x8ブロックを表すRGBデータが出力される。これらのデータは、逆光補正のみが選択されている場合で上述のITU-R BT.601に準拠した式によりYCbCr変換される。変換されたYCbCrデータに対し、STEP1407で生成した色かぶり補正係数の3x3マトリクスおよびコントラスト補正係数LUTY(コントラスト)、彩度強調係数S(強調)を施し、再度、上述の変換式によりRGB信号値に戻される。 In STEP 1408, it is determined whether or not the retrograde correction is selected. In this case, the process proceeds to STEP 1409. Here, color determination data and frequency determination data used for human skin determination for backlight correction are generated. For the color determination data, RGB data representing an 8 × 8 block is output on the memory. These data are YCbCr converted according to the above-mentioned formula based on ITU-R BT.601 when only backlight correction is selected. The converted YCbCr data is subjected to the 3 × 3 matrix of the color fog correction coefficient generated in STEP 1407, the contrast correction coefficient LUT Y (contrast) , and the saturation enhancement coefficient S (enhancement) , and again the RGB signal value by the above conversion equation. Returned to

STEP1410では、上記変換されたRGBデータを利用することにより、色かぶりを補正した画像に対し色判定を行い、同時に周波数成分の判定を実行する。これにより、求められた人肌輝度値から、適性に明るくする補正係数を決定する。   In STEP 1410, by using the converted RGB data, color determination is performed on the image with the color cast corrected, and frequency component determination is performed at the same time. Thus, a correction coefficient for appropriately brightening is determined from the obtained human skin luminance value.

その後、STEP1411で、色かぶり補正有無の判定を行い、本ケースでは色かぶり補正が選択されているので、STEP1402へと進む。   Thereafter, in STEP 1411, it is determined whether or not color fog correction is performed. In this case, since color fog correction is selected, the process proceeds to STEP 1402.

STEP1402以降は、[補正が選択されていない場合]と同等の処理になる。但し、STEP1403においての補正係数は、STEP1407で求められた係数が使用される。これにより、色かぶりおよび逆光補正などが実現される。   In STEP 1402 and subsequent steps, the process is the same as [when correction is not selected]. However, the coefficient obtained in STEP 1407 is used as the correction coefficient in STEP 1403. As a result, color cast and backlight correction are realized.

以上、述べたように、本発明の第一の実施形態では、PCカードからのダイレクト印刷が可能なプリンタにおいて、パネルにより色かぶり補正と逆光補正が、ユーザーにより選択される場合を示した。第一の実施例の手段を行うことで、適切な人肌検出が可能となり、より適切な補正を施すことが実現出来る。   As described above, in the first embodiment of the present invention, in the printer capable of direct printing from the PC card, the case where the user selects the color fog correction and the backlight correction by the panel is shown. By performing the means of the first embodiment, it is possible to detect human skin appropriately and to perform more appropriate correction.

[実施形態2]
本発明の第二の実施形態として、上述の第一の実施形態に対し、ノイズ除去処理が加わった場合を示す。尚、記録装置としては、第一の実施形態と同様、PCカードに記録されたデジタルカメラで撮影した画像もプリンタ可能なインクジェット記録装置(フォトダイレクトプリンタ装置)とする。よって、記録装置についての詳細な説明は、ここでは省略する。
[Embodiment 2]
As a second embodiment of the present invention, a case where a noise removal process is added to the first embodiment described above will be described. As in the first embodiment, the recording apparatus is an ink jet recording apparatus (photo direct printer apparatus) capable of printing an image taken with a digital camera recorded on a PC card. Therefore, detailed description of the recording apparatus is omitted here.

パネルにより設定を行うが、パネルのキー操作により、   The settings are made using the panel.

Figure 2009038582
と表示が切り替わり、ユーザーが設定可能となっている。
Figure 2009038582
The display is switched and the user can set it.

図15に、本実施形態における処理のブロック図を示す。第一の実施形態である図5との違いは、JPEG復号化処理部の次に、ノイズ除去処理部が加えられたところである。ノイズ除去処理部について説明する。   FIG. 15 shows a block diagram of processing in the present embodiment. The difference from FIG. 5 which is the first embodiment is that a noise removal processing unit is added after the JPEG decoding processing unit. The noise removal processing unit will be described.

(ノイズ除去処理部)
ノイズ除去の方法としては、様々な方法が提案、実現されているが、ここでは一般的なノイズ除去の一つである平均値フィルタを例に挙げる。図16は、平均値フィルタの一例である。5x5のウィンドウサイズのフィルタであり、中心の*印の画素が、ターゲット画素となる。ターゲット画素の輝度値をYTGTとしたとき、これは下記式で求められる。
(Noise removal processing part)
Various methods have been proposed and implemented as a noise removal method. Here, an average value filter which is one of general noise removal methods will be described as an example. FIG. 16 is an example of the average value filter. This is a 5 × 5 window size filter, and the pixel marked with * in the center is the target pixel. When the luminance value of the target pixel is Y TGT , this is obtained by the following equation.

Figure 2009038582
これらを全画素について行うことで、平滑化が実行され、結果としてノイズが除去される。画像の端部については、5x5のウィンドウサイズを確保出来ないので、その場合は確保可能な限りのサイズで行えばよい。同様に色差成分についても、平均化処理を行う。
Figure 2009038582
By performing these operations for all pixels, smoothing is executed, and as a result, noise is removed. Since the 5 × 5 window size cannot be secured at the edge of the image, in that case, the size may be as large as possible. Similarly, the color difference component is averaged.

また、単純な平均値フィルタの場合は、エッジ部分おいても平滑化をして、エッジが鈍り、画像のボケが発生してしまう。それを回避するために、エッジを検出し、エッジと判定された場合は、平滑化フィルタを施さないとして、エッジを確保する。エッジ検出には、PrewittフィルタやSobelフィルタに代表される微分フィルタを利用すればよい。   Further, in the case of a simple average value filter, the edge portion is also smoothed, the edge becomes dull, and the image is blurred. In order to avoid this, an edge is detected, and when the edge is determined, the smoothing filter is not applied and the edge is secured. For edge detection, a differential filter represented by a Prewitt filter or a Sobel filter may be used.

図17に本実施形態におけるフロー図を示す。第一の実施形態である図14との違いは、ノイズ処理に関するSTEP1703、1704、1713が追加されたことである。主要なケースを取り上げ、説明する。   FIG. 17 shows a flowchart in the present embodiment. The difference from FIG. 14, which is the first embodiment, is that STEPs 1703, 1704, and 1713 related to noise processing are added. Take up and explain the main cases.

(ノイズ除去のみが選択されている場合)
図17を用いて、ノイズ除去処理のみが選択されている場合を説明する。
(When only noise reduction is selected)
The case where only the noise removal process is selected will be described with reference to FIG.

STEP1701では、ノイズ除去のみのためSTEP1710の方へ判定されず、STEP1702へと進む。STEP1702で、JPEG画像の復号処理が行われた後、STEP1703により、ノイズ除去の判定を行う。ノイズ除去が選択されている場合は、STEP1704により上述のノイズ除去処理を実行する。それ以降、STEP1705〜1709は、実施例1で説明したフローと同じになり詳細は割愛する。STEP1708の量子化処理が終わった後に、STEP1709において全画素について処理が終了したかの判定を行い、もしそうでなければ、STEP1702に戻り、再度処理が繰り返される。   In STEP1701, since it is only noise removal, it does not determine to STEP1710, but progresses to STEP1702. After the decoding processing of the JPEG image is performed in STEP 1702, the noise removal is determined in STEP 1703. If noise removal is selected, the above-described noise removal processing is executed in STEP 1704. Thereafter, STEPs 1705 to 1709 are the same as the flow described in the first embodiment, and the details are omitted. After the quantization processing in STEP 1708 is completed, it is determined in STEP 1709 whether processing has been completed for all pixels. If not, the processing returns to STEP 1702 and the processing is repeated again.

(逆光補正のみが選択されている場合)
同様に図17を用いて、逆行補正のみが選択されている場合を説明する。
(When only backlight compensation is selected)
Similarly, the case where only the retrograde correction is selected will be described with reference to FIG.

逆光補正が選択されているため、STEP1701からSTEP1710へと進み、JPEGのデコード処理を行い、ヒストグラムから色かぶり補正のパラメータを決定する。STEP1711で逆光補正の有無の判定を行い、本ケースであればSTEP1712へと進む。STEP1712では第一の実施例の図14におけるSTEP1409と同様の処理となり、人肌判定データに対して、STEP1710で作成したパラメータを施し、色かぶりを除去する。さらにSTEP1713で変換された人肌判定用の画像に対し、ノイズ除去処理を実行する。そして、STEP1714では、その画像を使用して逆光補正係数決定の処理が実行される。これによって、人肌の判定処理を行う画像は、色かぶりがなくかつノイズ除去処理によりノイズが除去された画像となり、より精度高く人肌を検出し、その結果、より最適な逆光補正係数が決定される。   Since backlight correction is selected, the process proceeds from STEP 1701 to STEP 1710, JPEG decoding processing is performed, and parameters for color cast correction are determined from the histogram. In STEP 1711, the presence / absence of backlight correction is determined. If this is the case, the process proceeds to STEP 1712. In STEP 1712, the processing is the same as in STEP 1409 in FIG. 14 of the first embodiment, and the parameters created in STEP 1710 are applied to the human skin determination data to remove the color cast. Further, noise removal processing is executed on the human skin determination image converted in STEP 1713. In STEP 1714, the backlight correction coefficient determination process is executed using the image. As a result, the image subjected to human skin determination processing is an image having no color cast and noise removed by noise removal processing. Human skin is detected with higher accuracy, and as a result, a more optimal backlight correction coefficient is determined. Is done.

その後、色かぶり補正が選択されていないので、STEP1715において色かぶり係数をデフォルト値に戻し、STEP1702へと進む。   Thereafter, since color cast correction is not selected, the color cast coefficient is returned to the default value in STEP 1715, and the process proceeds to STEP 1702.

STEP1703では、ノイズ除去の判定が行われる、本ケースではSTEP1704はスキップされ、STEP1705へと進む。それ以降は、上述のフローと同様である。   In STEP 1703, noise removal is determined. In this case, STEP 1704 is skipped and the process proceeds to STEP 1705. The subsequent flow is the same as the above-described flow.

(色かぶり補正、逆光補正、ノイズ除去すべてが選択されている場合)
同様に図17を用いて、全ての補正処理が選択されている場合を説明する。
(When color cast correction, backlight correction, and noise reduction are all selected)
Similarly, the case where all the correction processes are selected will be described with reference to FIG.

STEP1701において、全ての補正処理が選択されている場合は、STEP1710へと進み、JPEGのデコード処理を行い、ヒストグラムから色かぶり補正のパラメータが決定された後、STEP1711の判定を経て、STEP1712で人肌判定用の画像に対し、STEP1710の係数による色かぶりを除去、STEP1713のノイズ除去処理を実行し、STEP1714では、その画像を使用して逆光補正係数決定の処理が実行される。これは、色かぶりがなく、かつノイズ除去処理により、ノイズが除去された画像に対し、人肌検出されたこととなり、より精度高く検出が実現し、その結果、より最適な逆光補正係数が決定される。   If all the correction processes are selected in STEP 1701, the process proceeds to STEP 1710, JPEG decoding is performed, the color cast correction parameters are determined from the histogram, and after the determination of STEP 1711, the human skin is determined in STEP 1712. The color cast by the coefficient of STEP 1710 is removed from the image for determination, and the noise removal process of STEP 1713 is executed. In STEP 1714, the backlight correction coefficient determination process is executed using the image. This means that human skin has been detected for images that have no color cast and noise is removed by noise removal processing, and detection is realized with higher accuracy. As a result, a more optimal backlight correction coefficient is determined. Is done.

その後、STEP1715の判定からSTEP1702へと戻り、それ以降は上述と同様の処理が実行される。   Thereafter, the process returns from STEP 1715 to STEP 1702, and thereafter, the same processing as described above is executed.

以上述べたように、第二の実施形態によれば、逆光補正のほか、色かぶり補正とノイズ除去処理が存在する場合に、より検出精度の高い人肌検出処理が実現することを説明した。なお、ノイズ除去処理ではフィルタリング処理を使用したが、その他様々な効果をもつフィルタリング処理との組み合わせにより、検出精度向上が図れることは言うまでもない。   As described above, according to the second embodiment, it has been described that human skin detection processing with higher detection accuracy is realized when color fog correction and noise removal processing exist in addition to backlight correction. Although the filtering process is used in the noise removal process, it goes without saying that the detection accuracy can be improved by combining with a filtering process having various other effects.

[他の実施形態]
なお、本発明の実施形態では、主としてカードからのダイレクトプリントを代表させて記述した。しかし、適用範囲はこれに限定されることなく、通常のPCからプリントも含まれる。また、出力装置だけでなく、スキャナといった入力機器についても、同様の処理が適用でき、効果も得ることが可能である。さらに複数の機器やスキャナ、プリンタから構成されるコピーのような複合されたシステムにおいても適用しても構わない。
[Other Embodiments]
In the embodiment of the present invention, direct printing from a card is representatively described. However, the application range is not limited to this, and printing from a normal PC is also included. Further, not only the output device but also an input device such as a scanner can be applied with the same processing, and an effect can be obtained. Furthermore, the present invention may be applied to a complex system such as a copy composed of a plurality of devices, scanners, and printers.

また、本発明の目的は、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記憶媒体(または記録媒体)を、システムあるいは装置に供給し、そのシステムあるいは装置のコンピュータ(またはCPUやMPU)が記憶媒体に格納されたプログラムコードを読み出し実行することによっても、達成されることは言うまでもない。この場合、記憶媒体から読み出されたプログラムコード自体が前述した実施形態の機能を実現することになり、そのプログラムコードを記憶した記憶媒体は本発明を構成することになる。また、コンピュータが読み出したプログラムコードを実行することにより、前述した実施形態の機能が実現されるだけでなく、そのプログラムコードの指示に基づき、コンピュータ上で稼働しているオペレーティングシステム(OS)などが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。   Another object of the present invention is to supply a storage medium (or recording medium) in which a program code of software that realizes the functions of the above-described embodiments is recorded to a system or apparatus, and the computer (or CPU or CPU) of the system or apparatus. Needless to say, this can also be achieved by the MPU) reading and executing the program code stored in the storage medium. In this case, the program code itself read from the storage medium realizes the functions of the above-described embodiments, and the storage medium storing the program code constitutes the present invention. Further, by executing the program code read by the computer, not only the functions of the above-described embodiments are realized, but also an operating system (OS) running on the computer based on the instruction of the program code. It goes without saying that a case where the function of the above-described embodiment is realized by performing part or all of the actual processing and the processing is included.

露出が適性でない、色かぶりをおこしている画像の輝度ヒストグラムの一例を示す図である。It is a figure which shows an example of the brightness | luminance histogram of the image which is performing the color cast which exposure is not appropriate. 本発明の実施の形態に係るフォトダイレクトプリンタ装置の概観斜視図である。1 is a schematic perspective view of a photo direct printer according to an embodiment of the present invention. 本発明の実施の形態に係るフォトダイレクトプリンタ装置の操作パネルの概観図である。FIG. 3 is an overview of an operation panel of the photo direct printer according to the embodiment of the present invention. 本発明の実施の形態に係るフォトダイレクトプリンタ装置の制御に係る主要部の構成を示すブロック図である。It is a block diagram which shows the structure of the principal part which concerns on control of the photo direct printer apparatus which concerns on embodiment of this invention. 本発明の第一の実施形態に係る画像処理についてのブロック図である。It is a block diagram about the image processing which concerns on 1st embodiment of this invention. 本発明の実施の形態に係る逆光補正処理の係数決定を表すフロー図である。It is a flowchart showing the coefficient determination of the backlight correction process which concerns on embodiment of this invention. JPEG画像のMCUの構成を示す図である。It is a figure which shows the structure of MCU of a JPEG image. 本発明の実施の形態に係る人肌検出の周波数判定のAC成分の取り扱い方法を説明する図である。It is a figure explaining the handling method of AC component of the frequency determination of the human skin detection which concerns on embodiment of this invention. 本発明の実施の形態に係る逆光補正用の輝度変換テーブルを示す図である。It is a figure which shows the luminance conversion table for backlight correction which concerns on embodiment of this invention. 本発明の実施の形態に係るハイライトポイントとシャドーポイントを結ぶ線が輝度軸に重なるように回転させるYCC空間の図である。It is a figure of YCC space rotated so that the line which connects the highlight point and shadow point which concerns on embodiment of this invention may overlap with a luminance axis. 本実施の形態に係る色変換処理に用いられるルックアップテーブルの一例を示す図である。It is a figure which shows an example of the look-up table used for the color conversion process which concerns on this Embodiment. 本実施の形態に係る色変換処理に用いられる四面体補間処理を示す図である。It is a figure which shows the tetrahedral interpolation process used for the color conversion process which concerns on this Embodiment. 本実施の形態に係る誤差拡散法における分配方法を表す図である。It is a figure showing the distribution method in the error diffusion method which concerns on this Embodiment. 本発明の第一の実施形態に係る画像処理についてのフロー図である。It is a flowchart about the image processing which concerns on 1st embodiment of this invention. 本発明の第二の実施形態に係る画像処理についてのブロック図である。It is a block diagram about the image processing which concerns on 2nd embodiment of this invention. 本発明の第二の実施形態に係るフィルター処理に関する図である。It is a figure regarding the filter process which concerns on 2nd embodiment of this invention. 本発明の第二の実施形態に係る画像処理についてのフロー図である。It is a flowchart about the image processing which concerns on 2nd embodiment of this invention.

Claims (10)

入力された画像に対して、複数の画像処理手段を施す画像処理装置において、
そのうちの少なくとも一つの画像処理手段は、処理を実行する際に使用する係数を決定する処理係数決定手段を有する第一の画像処理手段であり、
前記処理係数決定手段は、他の第二の画像処理手段を利用して決定する処理係数決定手段であり、
前記処理係数決定手段により決定された処理係数を使用して、前記第一の画像処理手段を実行することを特徴とする画像処理装置。
In an image processing apparatus that applies a plurality of image processing means to an input image,
At least one of the image processing means is a first image processing means having a processing coefficient determining means for determining a coefficient to be used when executing the processing,
The processing coefficient determination means is a processing coefficient determination means that determines using another second image processing means,
An image processing apparatus, wherein the first image processing means is executed using the processing coefficient determined by the processing coefficient determination means.
前記処理係数決定手段は、ある特定領域を抽出する特徴領域抽出手段を有し、抽出された領域の特性に基づいて処理係数を決定することを特徴とする請求項1に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the processing coefficient determination unit includes a characteristic region extraction unit that extracts a specific region, and determines a processing coefficient based on characteristics of the extracted region. 前記特徴領域抽出手段は、抽出判定に用いるデータに対し、前記第二の画像処理を施すことを特徴とする請求項2に記載の画像処理装置。   The image processing apparatus according to claim 2, wherein the feature region extraction unit performs the second image processing on data used for extraction determination. 前記第二の処理手段とは、画像全体の色相または輝度を変化させることを特徴とする請求項1〜請求項3のいずれかに記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the second processing unit changes a hue or luminance of the entire image. 前記第二の処理手段とは、周囲の画素値を利用して値を決定するフィルタ処理であることを特徴とする請求項1〜請求項4のいずれかに記載の画像処理装置。   5. The image processing apparatus according to claim 1, wherein the second processing unit is a filter process that determines a value using surrounding pixel values. 入力された画像に対して、複数の画像処理ステップを施す画像処理方法において、
そのうちの少なくとも一つの画像処理ステップは、処理を実行する際に使用する係数を決定する処理係数決定ステップを有する第一の画像処理ステップであり、
前記処理係数決定ステップは、他の第二の画像処理ステップを利用して決定する処理係数決定ステップであり、
前記処理係数決定ステップにより決定された処理係数を使用して、前記第一の画像処理ステップを実施することを特徴とする画像処理方法。
In an image processing method for performing a plurality of image processing steps on an input image,
At least one of the image processing steps is a first image processing step including a processing coefficient determination step for determining a coefficient to be used when executing the process.
The processing coefficient determination step is a processing coefficient determination step that is determined using another second image processing step,
An image processing method, wherein the first image processing step is performed using the processing coefficient determined by the processing coefficient determination step.
前記処理係数決定方法は、ある特定領域を抽出する特徴領域抽出方法を有し、抽出された領域の特性に基づいて処理係数を決定することを特徴とする請求項6に記載の画像処理方法。   The image processing method according to claim 6, wherein the processing coefficient determination method includes a feature area extraction method for extracting a specific area, and the processing coefficient is determined based on characteristics of the extracted area. 前記特徴領域抽出方法は、抽出判定に用いるデータに対し、前記第二の画像処理を施すことを特徴とする請求項7に記載の画像処理方法。   The image processing method according to claim 7, wherein the feature region extraction method performs the second image processing on data used for extraction determination. 前記第二の処理方法とは、画像全体の色相または輝度を変化させることを特徴とする請求項6〜請求項8のいずれかに記載の画像処理方法。   The image processing method according to claim 6, wherein the second processing method changes a hue or luminance of the entire image. 前記第二の処理手段とは、周囲の画素値を利用して値を決定するフィルタ処理であることを特徴とする請求項1〜請求項5のいずれかに記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the second processing unit is a filter process that determines a value by using a surrounding pixel value.
JP2007200916A 2007-08-01 2007-08-01 Image processing apparatus and image processing method Pending JP2009038582A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007200916A JP2009038582A (en) 2007-08-01 2007-08-01 Image processing apparatus and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007200916A JP2009038582A (en) 2007-08-01 2007-08-01 Image processing apparatus and image processing method

Publications (1)

Publication Number Publication Date
JP2009038582A true JP2009038582A (en) 2009-02-19

Family

ID=40440117

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007200916A Pending JP2009038582A (en) 2007-08-01 2007-08-01 Image processing apparatus and image processing method

Country Status (1)

Country Link
JP (1) JP2009038582A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012118699A (en) * 2010-11-30 2012-06-21 Canon Inc Image processing apparatus and method, and program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012118699A (en) * 2010-11-30 2012-06-21 Canon Inc Image processing apparatus and method, and program

Similar Documents

Publication Publication Date Title
JP4323748B2 (en) Digital camera and control method thereof, image processing apparatus, image processing method, and image processing system
JP4011933B2 (en) Image processing apparatus and method
JP5594382B2 (en) Output image adjustment for image files
JP3725454B2 (en) Output image adjustment for image files
CA2406350C (en) Image processing method and apparatus, storage medium and program
CN100473172C (en) Image data output image adjustment device and method
US7924326B2 (en) Image quality adjustment processing device
JP3964297B2 (en) Image processing apparatus, image processing method, and program executed by computer
JP4955082B2 (en) Image processing apparatus, image forming apparatus, and image processing method
WO2002065757A1 (en) Apparatus and method for adjusting output image from image data
JP4063290B2 (en) Image processing apparatus, image processing program, and image processing method
JP4226278B2 (en) Image processing apparatus, image forming apparatus, image processing method, image processing program, and recording medium recording the same
JP2003219191A (en) Image processing apparatus and image forming apparatus using the same
JP3667182B2 (en) Image processing method and image processing apparatus
JP4010306B2 (en) Output image adjustment for image files
JP2009038582A (en) Image processing apparatus and image processing method
JP2003060935A (en) Output image adjustment method for image file
JP2004080737A (en) Imaging device, imaging method, computer program, and computer-readable recording medium
JP4027117B2 (en) Image processing apparatus and method
JP4099366B2 (en) Image processing apparatus, image reading apparatus, image forming apparatus, and image processing method
JP3666439B2 (en) Output image adjustment for image files
JP5045808B2 (en) Output image adjustment for image files
JP2002344763A (en) Image processing device
JP4024735B2 (en) Image processing method, image processing apparatus, image forming apparatus, imaging apparatus, and computer program
JP3999157B2 (en) Output image adjustment for image files

Legal Events

Date Code Title Description
RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20100201

RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20100630