JP2016054491A - Image processing apparatus, image processing method, and program - Google Patents

Image processing apparatus, image processing method, and program Download PDF

Info

Publication number
JP2016054491A
JP2016054491A JP2015206155A JP2015206155A JP2016054491A JP 2016054491 A JP2016054491 A JP 2016054491A JP 2015206155 A JP2015206155 A JP 2015206155A JP 2015206155 A JP2015206155 A JP 2015206155A JP 2016054491 A JP2016054491 A JP 2016054491A
Authority
JP
Japan
Prior art keywords
coordinates
movement
correction
coordinate
correction range
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.)
Granted
Application number
JP2015206155A
Other languages
Japanese (ja)
Other versions
JP6039778B2 (en
Inventor
裕史 川口
Yasushi Kawaguchi
裕史 川口
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.)
Renesas Electronics Corp
Original Assignee
Renesas Electronics 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 Renesas Electronics Corp filed Critical Renesas Electronics Corp
Priority to JP2015206155A priority Critical patent/JP6039778B2/en
Publication of JP2016054491A publication Critical patent/JP2016054491A/en
Application granted granted Critical
Publication of JP6039778B2 publication Critical patent/JP6039778B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Abstract

PROBLEM TO BE SOLVED: To provide an image processing apparatus, an image processing method, and a program for appropriately setting a transformation rule for color transformation in a color space.SOLUTION: A three-dimensional lookup table unit transforms color information of an input image signal on the basis of a transformation rule. A correction range calculation unit 110, on the basis of positional relationship between a movement source coordinate and a movement destination coordinate in a color space set in advance, calculates a correction range in the color space. A lattice point movement amount calculation unit 120, on the basis of the positional relationship between the movement source coordinate and the movement destination coordinate and positional relationship between a coordinate of each point within the correction range and the movement source coordinate, calculates a transformation destination coordinate of each point, and reflects the transformation destination coordinate in the transformation rule.SELECTED DRAWING: Figure 2

Description

本発明は、画像処理装置、画像処理方法、及びプログラムに関する。   The present invention relates to an image processing apparatus, an image processing method, and a program.

青空の青色や、桜のピンク色等のオブジェクトや背景には、人間がそのオブジェクトや背景に対してイメージしている特定の色が存在する。これらの色は、記憶色と呼ばれている。人間は、あるオブジェクトや背景の色を実世界に即して忠実に再現した画像を見た場合であっても、綺麗な画像とは評価しない。これは、人間がイメージしていた色(記憶色)と再現された色が異なり、色が薄い等の認識をしてしまうためである。   For objects and backgrounds such as blue in the blue sky and pink of cherry blossoms, there are specific colors that humans image against the objects and background. These colors are called memory colors. Even if a human sees an image that faithfully reproduces the color of an object or background according to the real world, he does not evaluate it as a beautiful image. This is because the reproduced color is different from the color that the human imaged (memory color), and it is recognized that the color is light.

そのため、画像処理装置の多くは、オブジェクトや背景毎に人間がイメージしている色を再現するための補正処理を行う。この補正処理を記憶色補正と呼ぶ。記憶色補正の実施方法には、一般的に以下の2つの方法がある。
専用回路(特色補正機能)
3次元ルックアップテーブル
For this reason, many image processing apparatuses perform a correction process for reproducing a color imaged by a human for each object or background. This correction process is called memory color correction. There are generally the following two methods for performing the memory color correction.
Dedicated circuit (spot color correction function)
3D lookup table

はじめに、(1)専用回路を用いた記憶色補正について説明する。ここで、専用回路は、記憶色補正に特化した処理を行う。具体的には、専用回路に対して、補正したい特定の色を、Cb/Crやa*/b*等の色空間上の移動元と移動先の座標形式で設定する。専用回路は、この設定に応じて周辺の色領域を含めた色領域の補正を行う。しかしながら、専用回路は、記憶色補正に特化した回路であるため、他の処理を行うことが出来ない。さらに、2領域以上の特色補正を行う場合、複数の専用回路が必要となる。   First, (1) memory color correction using a dedicated circuit will be described. Here, the dedicated circuit performs processing specialized for memory color correction. Specifically, a specific color to be corrected is set for the dedicated circuit in the coordinate format of the movement source and the movement destination on the color space such as Cb / Cr or a * / b *. The dedicated circuit corrects the color area including the peripheral color area in accordance with this setting. However, since the dedicated circuit is a circuit specialized for memory color correction, other processing cannot be performed. Furthermore, when performing spot color correction in two or more areas, a plurality of dedicated circuits are required.

次に、(2)3次元ルックアップテーブルを用いた記憶色補正について説明する。3次元ルックアップテーブルの情報は、任意のメモリに格納される。3次元ルックアップテーブルには、主にRGBの3次元色空間を表現した9×9×9または17×17×17等の座標点に相当するテーブルデータが格納される。3次元ルックアップテーブルは、色空間上の、各点の座標と、当該座標の変換先の座標との対応を格納する。例えば、3次元ルックアップテーブルが17×17×17の座標点に対応するテーブルデータを持つ場合、RGB座標(0,0,0)とその変換先のRGB座標、RGB座標(16,16,16)とその変換先のRGB座標、等がそれぞれ格納される。そして、任意の処理部が3次元ルックアップテーブルを参照し、色空間に存在する各座標を各種の補間処理により変換先の座標に移動する。例えば、当該処理部は、RGB座標(8,8,8)の変換先座標を、RGB座標(0,0,0)の変換先座標、及びRGB座標(16,16,16)の変換先座標を参照して算出する。   Next, (2) memory color correction using a three-dimensional lookup table will be described. Information of the three-dimensional lookup table is stored in an arbitrary memory. In the three-dimensional lookup table, table data corresponding to coordinate points such as 9 × 9 × 9 or 17 × 17 × 17 representing mainly a three-dimensional RGB color space is stored. The three-dimensional lookup table stores the correspondence between the coordinates of each point on the color space and the coordinates to which the coordinates are converted. For example, when the three-dimensional lookup table has table data corresponding to coordinate points of 17 × 17 × 17, the RGB coordinates (0, 0, 0), the RGB coordinates of the conversion destination, and the RGB coordinates (16, 16, 16 ) And the RGB coordinates of the conversion destination, etc. are stored respectively. Then, an arbitrary processing unit refers to the three-dimensional lookup table, and moves each coordinate existing in the color space to a conversion destination coordinate by various interpolation processes. For example, the processing unit converts the conversion destination coordinates of the RGB coordinates (8, 8, 8), the conversion destination coordinates of the RGB coordinates (0, 0, 0), and the conversion destination coordinates of the RGB coordinates (16, 16, 16). To calculate.

3次元ルックアップテーブルは、単なる変換規則を保持するものにすぎず、それ自体には何らの機能を具備しない。しかし、3次元ルックアップテーブルに対して適切なテーブルデータを設定し、テーブル内の変換規則に従った処理を行うことにより、色域マッピング、6軸補正、記憶色補正、ガンマ補正等の様々な色管理機能を実現することができる。ここで、3次元ルックアップテーブルに設定するテーブルデータは、適宜変更することができる。そのため、単一の処理回路(またはソフトウェアによる処理機能)を設けるのみで、必要な機能(複数領域処理、複数の他機能を同時に実現することを含む)を状況に応じて実現することができる。   The three-dimensional lookup table merely holds conversion rules and does not have any function in itself. However, by setting appropriate table data for the three-dimensional lookup table and performing processing according to the conversion rules in the table, various types of color gamut mapping, six-axis correction, memory color correction, gamma correction, etc. A color management function can be realized. Here, the table data set in the three-dimensional lookup table can be changed as appropriate. Therefore, only by providing a single processing circuit (or processing function by software), necessary functions (including simultaneous realization of multiple area processing and multiple other functions) can be realized according to the situation.

このように、3次元ルックアップテーブルを用いた補正は、専用回路機能(特色補正機能)による補正よりも断然高い自由度を有する。そのため、3次元ルックアップテーブルを用いた構成により、開発リソースの削減、回路規模の縮小等の多くのコスト面でのメリット、及びユーザビリティの改善を図ることができる。さらに、不具合が生じた場合や性能向上を図る場合、3次元ルックアップテーブルのテーブルデータを差し替えることにより、ハードウェアの変更等を行うことなく、課題を解決することができる。   As described above, the correction using the three-dimensional lookup table has a much higher degree of freedom than the correction by the dedicated circuit function (spot color correction function). Therefore, the configuration using the three-dimensional lookup table can improve many cost advantages such as reduction of development resources and reduction of circuit scale, and improvement of usability. Furthermore, when a problem occurs or when improving the performance, the problem can be solved without changing the hardware by replacing the table data of the three-dimensional lookup table.

以下、上記した事項に関連する画像処理技術を開示した文献について説明する。特許文献1は、入力動画像信号を3次元ルックアップテーブルを用いてカラーマネージメント処理する色信号処理システムを開示している。当該システムは、入力された画像信号の色情報を多次元ルックアップテーブルにより変換する色変換部と、色変換部で変換された画像信号と入力された画像信号を任意の比率で合成した合成画像信号を出力する内挿部と、色変換部における多次元ルックアップテーブルのデータを変更するルックアップテーブル書き換え部と、を備える。当該構成により、このシステムは、ルックアップテーブルのデータ書き換え時にも、高精度なカラーマネージメント処理を実現することができる。   Hereinafter, documents disclosing image processing techniques related to the above-described matters will be described. Patent Document 1 discloses a color signal processing system that performs color management processing on an input moving image signal using a three-dimensional lookup table. The system includes a color conversion unit that converts color information of an input image signal using a multidimensional lookup table, and a composite image obtained by combining the image signal converted by the color conversion unit and the input image signal at an arbitrary ratio. An interpolation unit that outputs a signal; and a lookup table rewriting unit that changes data of a multidimensional lookup table in the color conversion unit. With this configuration, this system can realize highly accurate color management processing even when the data in the lookup table is rewritten.

特許文献2は、記憶色補正に対する副作用の少ない自動色調整を行う画像処理装置を開示している。当該画像処理装置は、2つの色度成分(a*/b*)に基づいて設定された特定範囲の色領域に対し、その領域周辺は小さい補正強度を生成する強度決定手段と、生成された補正強度に応じて補正を行う手段と、を有する。   Patent Document 2 discloses an image processing apparatus that performs automatic color adjustment with few side effects on memory color correction. The image processing apparatus includes: an intensity determining unit that generates a small correction intensity around a specific color range set based on two chromaticity components (a * / b *); Means for performing correction according to the correction intensity.

特開2010−118881号公報JP 2010-118881 A WO2004/032524号公報WO2004 / 032524

しかしながら、3次元ルックアップテーブル等の変換規則を用いた色空間上での補正処理には、記憶色補正をはじめとする変換規則を設定するための高度な知識やノウハウが必要となるという課題があった。当該課題を以下に述べる。   However, correction processing on a color space using a conversion rule such as a three-dimensional lookup table requires a high level of knowledge and know-how to set conversion rules including memory color correction. there were. The subject is described below.

3次元ルックアップテーブルを用いた補正処理システムには、一般にテーブルデータを記憶するメモリと、そのテーブルデータから変換値を算出する回路が存在するのみである。そのため、3次元ルックアップテーブルのテーブルデータの設定の自由度が非常に高い。この3次元ルックアップテーブルのテーブルデータの設定とは、記憶色補正の対象としたい色(対象色)と、当該色の変換先を設定することに加えて、対象色の周辺に存在する色をどこまで補正範囲にするか、及び補正範囲内にある各色の変換先座標、を設定する必要がある。そのため、例えば上述の記憶色補正に関するテーブルデータを設定する場合、設定者は、記憶色補正に関する高度な知識、ノウハウを保持していなければ正しい設定を行うことができない。   A correction processing system using a three-dimensional lookup table generally has only a memory for storing table data and a circuit for calculating a conversion value from the table data. Therefore, the degree of freedom for setting the table data of the three-dimensional lookup table is very high. The setting of the table data of the three-dimensional lookup table includes not only setting a color (target color) to be subjected to memory color correction and a conversion destination of the color, but also colors existing around the target color. It is necessary to set how far the correction range is set and the conversion destination coordinates of each color within the correction range. Therefore, for example, when setting the table data relating to the memory color correction described above, the setter cannot perform a correct setting unless he / she has advanced knowledge and know-how regarding the memory color correction.

仮に設定者が十分な知識やノウハウを保持せずにテーブルデータを設定して記憶色補正を行った場合、3次元色空間内の連続性が保証されず、補正処理後の画像に空間歪みが生じる恐れがある。このようなテーブルデータを持つ画像処理装置に対して色や輝度のなだらかなグラデーションを持つ画像が入力された場合、当該画像処理装置は、本来は存在しないはずの輪郭を持つ画像や、階調特性を損なった画像を出力してしまう恐れがある。 If the setter does not have sufficient knowledge and know-how to set table data and perform memory color correction, continuity in the three-dimensional color space is not guaranteed, and spatial distortion occurs in the corrected image. May occur. When an image having a gentle gradation of color and brightness is input to an image processing apparatus having such table data, the image processing apparatus can display an image having a contour that should not exist or gradation characteristics. There is a risk of outputting an image in which the image is damaged.

特許文献1及び特許文献2に記載の画像補正手法は、いずれも設定者がテーブルデータを逐次設定することを前提とした手法である。そのため、設定者が色補正に関する十分なノウハウ、知識を有さない場合、意図した補正を行えない恐れがある。   The image correction methods described in Patent Literature 1 and Patent Literature 2 are both methods based on the premise that a setter sequentially sets table data. Therefore, if the setter does not have sufficient know-how and knowledge regarding color correction, there is a possibility that the intended correction cannot be performed.

なお、上述の説明では、3次元ルックアップテーブルを参照して記憶色補正を行う場合おいて、ルックアップテーブルの設定者が十分なノウハウ、知識を有さない場合に問題が生じる点を説明した。しかしながら、当該問題は、3次元ルックアップテーブルを用いた補正に限った話ではなく、色空間における色補正を行う際に必要となる任意の変換ルールの設定の際に生じる問題である。さらに、当該問題は、記憶色補正を目的とした補正に限られず、映像に含まれる画素データの補正(色空間上での座標移動)を行う場合に共通する課題であった。   In the above description, when memory color correction is performed with reference to a three-dimensional lookup table, a problem occurs when a lookup table setter does not have sufficient know-how and knowledge. . However, this problem is not limited to correction using a three-dimensional lookup table, but is a problem that occurs when setting an arbitrary conversion rule that is necessary when performing color correction in a color space. Further, the problem is not limited to correction for the purpose of memory color correction, and is a problem common to correction of pixel data included in a video (coordinate movement in a color space).

すなわち、映像に含まれる画素データ(画素値)の補正(色空間での座標移動)を行う場合に、所望の補正目的に合致する補正範囲(移動が生じる座標点の範囲)の算出、移動を行う各座標点の移動量・方向を設定するためには、高度な知識を要す。ユーザが高度な知識を持たない場合、適切な設定が行えないという問題があった。   That is, when correcting pixel data (pixel value) included in an image (coordinate movement in a color space), calculation and movement of a correction range (range of coordinate points where movement occurs) that matches a desired correction purpose is performed. Advanced knowledge is required to set the amount and direction of movement of each coordinate point. If the user does not have advanced knowledge, there is a problem that appropriate settings cannot be made.

本発明にかかる画像処理装置の一態様は、
入力された画像信号の色情報を変換規則に基づいて変換する変換部と、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出する補正範囲算出部と、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させる各点移動量算出部と、を備えるものである。
One aspect of the image processing apparatus according to the present invention is as follows.
A conversion unit that converts color information of the input image signal based on a conversion rule;
A correction range calculation unit that calculates a correction range in the color space based on the positional relationship between the movement source coordinates and the movement destination coordinates in the preset color space;
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion Each point movement amount calculation unit to be reflected in the rule.

本発明にかかる画像処理方法の一態様は、
入力された画像信号の色情報を変換規則に基づいて変換する画像処理方法であって、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出し、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させる、ものである。
One aspect of the image processing method according to the present invention is as follows.
An image processing method for converting color information of an input image signal based on a conversion rule,
Based on the positional relationship between the movement source coordinates and the movement destination coordinates in the preset color space, a correction range in the color space is calculated,
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion It is what is reflected in the rules.

本発明にかかる画像処理プログラムの一態様は、
コンピュータに、
入力された画像信号の色情報を変換規則に基づいて変換する処理と、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出する処理と、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させる処理と、を実行させるためのプログラムである。
One aspect of the image processing program according to the present invention is as follows:
On the computer,
A process of converting the color information of the input image signal based on a conversion rule;
A process of calculating a correction range in the color space based on the positional relationship between the movement source coordinates and the movement destination coordinates in a preset color space;
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion This is a program for executing processing to be reflected in the rules.

本発明では、補正範囲算出部は、移動元座標と移動先座標の位置関係から補正範囲を自動算出する。更に、各点移動量算出部は、移動元座標と移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、から補正範囲内の各格子点の変換先座標を算出し、当該変換先座標を変換規則(本実施の形態では3次元ルックアップテーブル)に反映する。ここで、ユーザは、移動元座標と移動先座標の情報を提供するのみで良い。これにより、ユーザは、補正範囲の設定に関する知識や各点の移動量等についての知識を有することなく、色空間での補正処理を実現することができる。   In the present invention, the correction range calculation unit automatically calculates the correction range from the positional relationship between the movement source coordinates and the movement destination coordinates. Furthermore, each point movement amount calculation unit calculates the position of each lattice point in the correction range from the positional relationship between the movement source coordinate and the movement destination coordinate and the positional relationship between the coordinate of each point in the correction range and the movement source coordinate. The conversion destination coordinates are calculated, and the conversion destination coordinates are reflected in the conversion rule (a three-dimensional lookup table in the present embodiment). Here, the user only needs to provide information on the movement source coordinates and the movement destination coordinates. Thereby, the user can realize the correction process in the color space without having knowledge about the setting of the correction range, knowledge about the movement amount of each point, and the like.

本発明によれば、映像に含まれる画素データ(画素値)の補正(色空間での座標移動)を行う場合に、高度な知識を要すことなく、所望の補正目的に合致する補正範囲(移動が生じる座標点の範囲)の算出、移動を行う各座標点の移動量・方向の設定ができる画像処理装置、画像処理方法、画像処理プログラムを提供することができる。   According to the present invention, when correction of pixel data (pixel value) included in an image (coordinate movement in a color space) is performed, a correction range that matches a desired correction purpose without requiring advanced knowledge ( It is possible to provide an image processing apparatus, an image processing method, and an image processing program capable of calculating the range of coordinate points where movement occurs and setting the amount and direction of movement of each coordinate point to be moved.

本発明の実施の形態1にかかる画像処理装置1の構成を示すブロック図である。1 is a block diagram showing a configuration of an image processing apparatus 1 according to a first embodiment of the present invention. 本発明の実施の形態1にかかるテーブルデータ生成部100の構成を示すブロック図である。It is a block diagram which shows the structure of the table data generation part 100 concerning Embodiment 1 of this invention. 本発明の実施の形態1にかかる補正範囲算出部110の構成を示すブロック図である。It is a block diagram which shows the structure of the correction range calculation part 110 concerning Embodiment 1 of this invention. 色空間(GB断面)における移動元座標と、移動先座標との距離Ltoの概念を示す図である。It is a figure which shows the concept of distance Lto of the movement origin coordinate in a color space (GB cross section) and a movement destination coordinate. 本発明の実施の形態1にかかる補正範囲算出部110による補正範囲の回転の概念を示す図である。It is a figure which shows the concept of rotation of the correction range by the correction range calculation part 110 concerning Embodiment 1 of this invention. 移動元座標、移動先座標、及び補正範囲を示す楕円球の関係を3次元的に示した図である。It is the figure which showed the relationship of the ellipsoid which shows a movement origin coordinate, a movement destination coordinate, and a correction range three-dimensionally. 本発明の実施の形態1にかかる格子点移動量算出部120の構成を示すブロック図である。It is a block diagram which shows the structure of the lattice point movement amount calculation part 120 concerning Embodiment 1 of this invention. 影響度Efと移動量特性MEの関係を示す図である。It is a figure which shows the relationship between the influence Ef and the movement amount characteristic ME. 色空間における補正方向の概念を示す図である。It is a figure which shows the concept of the correction direction in color space. 補正範囲の回転の効果を示す概念図である。It is a conceptual diagram which shows the effect of rotation of a correction range. 肌色の記憶色補正を示す概念図である。It is a conceptual diagram which shows the memory color correction | amendment of skin color. 本発明の実施の形態2にかかる画像処理装置1の構成を示すブロック図である。It is a block diagram which shows the structure of the image processing apparatus 1 concerning Embodiment 2 of this invention. 本発明の実施の形態2にかかるヒストグラム解析部304による画像全体のヒストグラムの解析を示す図である。It is a figure which shows the analysis of the histogram of the whole image by the histogram analysis part 304 concerning Embodiment 2 of this invention. 補正範囲の干渉を示す概念図である。It is a conceptual diagram which shows the interference of a correction range. 本発明の実施の形態1、及び実施の形態2にかかる画像処理装置1による記憶色補正を示す概念図である。It is a conceptual diagram which shows memory color correction by the image processing apparatus 1 concerning Embodiment 1 and Embodiment 2 of this invention. 本発明の実施の形態3にかかる補正範囲算出部110による補正範囲の回転の概念を示す図である。It is a figure which shows the concept of rotation of the correction range by the correction range calculation part 110 concerning Embodiment 3 of this invention. 補正範囲に含まれる格子点数を算出、楕円球を縮小する再設定の概念を示す図である。It is a figure which shows the concept of the reset which calculates the number of grid points contained in a correction range, and reduces an ellipsoid. 本発明の実施の形態4にかかる補正範囲算出部110の構成を示すブロック図である。It is a block diagram which shows the structure of the correction range calculation part 110 concerning Embodiment 4 of this invention. 本発明の実施の形態4にかかる画像処理装置1の動作イメージを示す概念図である。It is a conceptual diagram which shows the operation | movement image of the image processing apparatus 1 concerning Embodiment 4 of this invention. 本発明の実施の形態4にかかる画像処理装置1の動作イメージを示す概念図である。It is a conceptual diagram which shows the operation | movement image of the image processing apparatus 1 concerning Embodiment 4 of this invention. 本発明の実施の形態5にかかる画像処理装置1の構成を示すブロック図である。It is a block diagram which shows the structure of the image processing apparatus 1 concerning Embodiment 5 of this invention. 本発明の実施の形態5にかかる画像処理装置1の処理対象とする画像例を示す図である。It is a figure which shows the example of an image made into the process target of the image processing apparatus 1 concerning Embodiment 5 of this invention. GB断面における青空の補正範囲と、青い花の補正範囲を示す図である。It is a figure which shows the correction range of the blue sky in a GB cross section, and the correction range of a blue flower. 本発明の実施の形態6にかかる色空間変換部500の構成を示すブロック図である。It is a block diagram which shows the structure of the color space conversion part 500 concerning Embodiment 6 of this invention. 画像処理装置1の各処理部の処理をプログラムとして実行するコンピュータのハードウェア構成の一例を示す図である。It is a figure which shows an example of the hardware constitutions of the computer which performs the process of each process part of the image processing apparatus 1 as a program.

<実施の形態1>
以下、図面を参照して本発明の実施の形態について説明する。図1は、本実施の形態かかる画像処理装置の構成を示すブロック図である。
<Embodiment 1>
Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram showing the configuration of the image processing apparatus according to this embodiment.

画像処理装置1は、テーブルデータ生成部100と、3次元ルックアップテーブル部200と、を備える。3次元ルックアップテーブル部200は、アドレス生成部210と、テーブルデータメモリ部220と、補間部230と、を備える。 The image processing apparatus 1 includes a table data generation unit 100 and a three-dimensional lookup table unit 200. The three-dimensional lookup table unit 200 includes an address generation unit 210, a table data memory unit 220, and an interpolation unit 230.

3次元ルックアップテーブル部200は、3次元ルックアップテーブルを保持し、入力されたRGB信号の変換処理をする。3次元ルックアップテーブル部200は、3次元ルックアップテーブルを用いた一般的な記憶色補正を行う。ここで、3次元ルックアップテーブル部200が保持する3次元ルックアップテーブルは、8bitまたは10bit精度の9×9×9または17×17×17等の格子点を持つ一般的なRGB空間の3次元ルックアップテーブルである。3次元ルックアップテーブル部200は、RGB空間上の格子点座標(R1,G1,B1)を(R2,G2,B2)に移動させるというような対応関係を格子点数分だけ保持する。3次元ルックアップテーブル部200内にて格子点を補間する方法(格子点に含まれない色空間上の座標の移動先を算出する方法)は、一般的な3次元空間における直線補間法やキュービック補間法を用いれば良い。   The three-dimensional lookup table unit 200 holds a three-dimensional lookup table and performs a conversion process on the input RGB signal. The three-dimensional lookup table unit 200 performs general memory color correction using a three-dimensional lookup table. Here, the three-dimensional lookup table held by the three-dimensional lookup table unit 200 is a general three-dimensional RGB space having a lattice point of 9 × 9 × 9 or 17 × 17 × 17 having an 8-bit or 10-bit accuracy. Lookup table. The three-dimensional lookup table unit 200 holds a correspondence relationship such as moving the grid point coordinates (R1, G1, B1) in the RGB space to (R2, G2, B2) by the number of grid points. A method of interpolating lattice points in the three-dimensional lookup table unit 200 (a method of calculating a movement destination of coordinates on a color space not included in the lattice points) is a linear interpolation method or cubic in a general three-dimensional space. An interpolation method may be used.

なお、記憶色補正処理は、3次元色空間内にある特定の色領域を指定して補正を行う。そのため、格子点数が多い方が、高精度な補正を行うことができる。そのため、3次元ルックアップテーブルにおける格子点数は、9×9×9以上の格子点数とすべきである。これにより、実使用上に耐えうる記憶色補正を実施することが可能となる。   In the memory color correction process, correction is performed by designating a specific color region in the three-dimensional color space. Therefore, correction with higher accuracy can be performed when the number of grid points is larger. Therefore, the number of grid points in the three-dimensional lookup table should be 9 × 9 × 9 or more. As a result, it is possible to perform memory color correction that can withstand actual use.

続いて、図2を参照してテーブルデータ生成部100の構成を説明する。テーブルデータ生成部100は、補正範囲算出部110と、格子点移動量算出部120と、を備える。ユーザは、記憶色補正を施したい色の移動元座標(RGB座標上の座標点)、移動先座標(RGB座標上の座標点)、及び補正方向(圧縮方向/平行方向)という3つの設定値をテーブルデータ生成部100に入力する。なお、ユーザは、影響範囲ゲイン/オフセット、及び移動特性を更に設定しても良い。設定しない場合には、デフォルト値を用いれば良い。同様に、補正方向が設定されない場合には、デフォルト値(例えば圧縮方向)を用いても良い。   Next, the configuration of the table data generation unit 100 will be described with reference to FIG. The table data generation unit 100 includes a correction range calculation unit 110 and a lattice point movement amount calculation unit 120. The user sets three set values of the movement source coordinates (coordinate points on the RGB coordinates), the movement destination coordinates (coordinate points on the RGB coordinates), and the correction direction (compression direction / parallel direction) of the color to be subjected to memory color correction. Is input to the table data generation unit 100. Note that the user may further set the influence range gain / offset and movement characteristics. If not set, the default value may be used. Similarly, when the correction direction is not set, a default value (for example, the compression direction) may be used.

補正範囲算出部110は、前述の3つの設定値(移動元座標、移動先座標、及び補正方向)を基に記憶色補正を行う色空間上の範囲(補正範囲)を算出する処理部である。なお、ユーザは、補正範囲算出部110が算出する補正範囲が適切ではない(広すぎる、狭すぎる)と感じた場合には、影響範囲ゲイン/オフセットを調整することにより補正範囲を調整することができる。詳細は、後述する。   The correction range calculation unit 110 is a processing unit that calculates a range (correction range) on a color space for performing memory color correction based on the above-described three setting values (movement source coordinates, movement destination coordinates, and correction direction). . If the user feels that the correction range calculated by the correction range calculation unit 110 is not appropriate (too wide or too narrow), the user can adjust the correction range by adjusting the influence range gain / offset. it can. Details will be described later.

補正範囲算出部110は、算出した補正範囲(記憶色補正に伴って色空間上の座標が変化する範囲)を格子点移動量算出部120に供給する。格子点移動量算出部120は、当該補正範囲内の各格子点の移動量を自動的に算出し、当該移動量を基に3次元ルックアップテーブルのテーブルデータを生成する。   The correction range calculation unit 110 supplies the calculated correction range (a range in which coordinates in the color space change with memory color correction) to the lattice point movement amount calculation unit 120. The lattice point movement amount calculation unit 120 automatically calculates the movement amount of each lattice point within the correction range, and generates table data of a three-dimensional lookup table based on the movement amount.

詳細には、格子点移動量算出部120は、移動の中心となる移動元座標と、各格子点の座標と、の距離を基準に影響度(各格子点の移動量の指標値であり、詳細は後述する。)を算出する。移動元座標に近い格子点から算出された影響度は、大きくなる。移動元座標からの距離が大きい格子点から算出された影響度は、小さくなる。影響範囲外(補正範囲外)の格子点から算出される影響度は0となる。 Specifically, the grid point movement amount calculation unit 120 is an influence (an index value of the movement amount of each grid point) based on the distance between the movement source coordinates serving as the center of movement and the coordinates of each grid point. Details will be described later). The degree of influence calculated from the grid point close to the movement source coordinate becomes large. The degree of influence calculated from a grid point having a large distance from the movement source coordinate becomes small. The degree of influence calculated from the grid points outside the influence range (outside the correction range) is zero.

格子点移動量算出部120は、各格子点についての影響度を算出し、その影響度に応じて各格子点の移動量を算出する。格子点移動量算出部120は、各格子点の座標値に、各格子点について算出した移動量を加算することによりテーブルデータを生成する。   The lattice point movement amount calculation unit 120 calculates the influence degree for each lattice point, and calculates the movement amount of each lattice point according to the influence degree. The lattice point movement amount calculation unit 120 generates table data by adding the movement amount calculated for each lattice point to the coordinate value of each lattice point.

なお、ユーザは、影響度から算出する移動量について調整したい場合には、移動特性の入力値を調整すればよい。移動特性についての詳細は、後述する。   When the user wants to adjust the movement amount calculated from the degree of influence, the user may adjust the input value of the movement characteristic. Details of the movement characteristics will be described later.

続いて、補正範囲算出部110、格子点移動量算出部120の詳細な構成、動作の説明に先立ち、上記した入力(移動元座標、移動先座標)を基に補正範囲、及び各格子点の移動量を算出する意義について説明する。   Subsequently, prior to the detailed configuration and operation of the correction range calculation unit 110 and the grid point movement amount calculation unit 120, the correction range and each grid point are determined based on the input (movement source coordinates, movement destination coordinates) described above. The significance of calculating the movement amount will be described.

本実施の形態にかかる画像処理装置1では、ユーザは、記憶色補正を行う場合に、移動の中心となる移動元の色座標を設定し、その色をどの色にするかを示す移動先の色座標を設定する。当該設定を受けて、補正範囲算出部110は、補正範囲を算出する。すなわち、補正範囲算出部110は、設定された2つの色座標の周囲に存在する色(座標)も移動対象として選択する。このように選択する理由は、以下の2つである。   In the image processing apparatus 1 according to the present embodiment, when performing memory color correction, the user sets a movement source color coordinate that is the center of movement, and indicates a movement destination that indicates which color the color is to be used for. Set the color coordinates. In response to the setting, the correction range calculation unit 110 calculates the correction range. That is, the correction range calculation unit 110 also selects a color (coordinate) existing around two set color coordinates as a movement target. There are two reasons for this selection.

1つ目の理由は、3次元色空間内の連続性を保証することにより空間歪みを防ぎ、階調特性を劣化させないためである。   The first reason is that by ensuring continuity in the three-dimensional color space, spatial distortion is prevented and gradation characteristics are not deteriorated.

2つ目の理由は、補正したい色は、3次元空間のある1点に集中して存在しているわけではなく、ある色領域に対して補正を要すためである。例えば、青色の記憶色補正を行う場合、補正したい青色は、3次元空間のある一点に集中して存在しているわけではなく、ある当該一点の周辺の一定の色領域が補正の対象となるためである。 The second reason is that the color to be corrected is not concentrated on a certain point in the three-dimensional space but needs to be corrected for a certain color area. For example, when a blue memory color correction is performed, the blue color to be corrected does not exist in a concentrated manner at a certain point in the three-dimensional space, and a certain color region around the certain point is a correction target. Because.

一般的に、例えば記憶色補正をしたい肌色の色領域を設定する場合、世の中に存在する肌色のサンプルデータを取得する。そして、取得したデータとは別に好ましい肌色の統計データを収集する。その上で、これらのデータを高度なノウハウを用いて解析することにより、どの肌色を中心(移動元)にして、ある範囲(補正範囲)までを肌色と定義し、どの色を好ましい肌色(移動先)とするかを決めていた。   In general, for example, when setting a skin color area to be subjected to memory color correction, skin color sample data existing in the world is acquired. In addition to the acquired data, statistical data of preferable skin color is collected. In addition, by analyzing these data using advanced know-how, it is defined which skin color is the center (movement source), up to a certain range (correction range) as the skin color, and which color is the preferred skin color (movement) I decided to do it first).

しかしながら、一言に肌色といっても、様々な人種が存在している。そのため、全ての肌色領域を定義した場合、当該領域は、かなり広いものになってしまう。さらに、撮影環境の光源による肌色の変化や、背景色による肌色の見え方の変化も生じる。そのため、どのような場合に対しても絶対的に好ましい設定を行うことは不可能である。さらに、記憶色とは、そもそも曖昧な定義であるものが多い。そのため、記憶色は、ユーザの好みや地域性により大きく異なる場合がある。要するに、記憶色の補正にかかる移動元座標と移動先座標の設定は、非常に困難な場合が多い。しかしながら、好ましいとされる色と輝度の傾向に画像の色が補正された場合、一定の補正効果があることも事実である。   However, there are various races even if it is called skin color. For this reason, when all skin color regions are defined, the region becomes considerably wide. Furthermore, the skin color changes due to the light source in the shooting environment, and the skin color appearance changes depending on the background color. Therefore, it is impossible to make an absolutely preferable setting for any case. Furthermore, memory colors are often vague definitions in the first place. Therefore, the memory color may vary greatly depending on the user's preference and regional characteristics. In short, setting the movement source coordinates and the movement destination coordinates for correcting the memory color is often very difficult. However, it is also true that there is a certain correction effect when the color of the image is corrected to the preferred color and brightness trends.

よって、本実施の形態にかかる画像処理装置では、各ユーザが“この色を中心に、この色に近づくように補正したい”ということを設定(すなわち前述の移動元と移動先の座標を設定)すれば、補正範囲算出部110は、自動的に補正範囲を算出する。また、格子点移動量算出部120は、自動的に補正範囲内の各格子点の移動量を算出する。これにより本実施の形態にかかる画像処理装置1は、ユーザが上述の統計データや高度な調整ノウハウを保持していない場合でも、容易に実運用上問題の無い記憶色補正の手段を提供できるようにする。   Therefore, in the image processing apparatus according to the present embodiment, each user sets that “I want to correct this color so that it approaches this color” (that is, set the above-described movement source and movement destination coordinates). Then, the correction range calculation unit 110 automatically calculates the correction range. Further, the lattice point movement amount calculation unit 120 automatically calculates the movement amount of each lattice point within the correction range. As a result, the image processing apparatus 1 according to the present embodiment can easily provide a means for correcting the memory color that is not problematic in actual operation even when the user does not hold the above statistical data or advanced adjustment know-how. To.

次に、図3を参照して、補正範囲算出部110の詳細な構成について説明する。図3は、補正範囲算出部110の構成を示すブロック図である。補正範囲算出部110は、移動先−移動元距離算出部111と、補正範囲ゲイン・オフセット調整部112と、移動先−移動元直線傾き算出部113と、回転角度算出部114と、補正範囲楕円球式算出部115と、を備える。なお、図4〜図6は、色空間における移動元座標、移動先座標、及び補正範囲の関係を示す図である。以下、これらの図面を適宜参照して説明する。   Next, a detailed configuration of the correction range calculation unit 110 will be described with reference to FIG. FIG. 3 is a block diagram illustrating a configuration of the correction range calculation unit 110. The correction range calculation unit 110 includes a movement destination-movement source distance calculation unit 111, a correction range gain / offset adjustment unit 112, a movement destination-movement source linear inclination calculation unit 113, a rotation angle calculation unit 114, and a correction range ellipse. A spherical calculation unit 115. 4 to 6 are diagrams illustrating the relationship between the movement source coordinates, the movement destination coordinates, and the correction range in the color space. The following description will be given with reference to these drawings as appropriate.

移動先−移動元距離算出部111には、ユーザが設定した移動元座標と、移動先座標と、が入力される。移動先−移動元距離算出部111は、移動先座標から移動元座標を減算することにより、移動先座標から移動元座標までの色空間上での距離を算出する。移動元座標、移動先座標、及び移動先座標から移動元座標までの距離を以下のように定義し、算出式を示す。
移動元座標: O (Ro, Go, Bo)
移動先座標: T (Rt, Gt, Bt)
移動元/移動元間距離: Lto (Rlto, Glto, Blto)
Lto = (Rt-Ro, Gt-Go, Bt-Bo)
To the movement destination-movement source distance calculation unit 111, the movement source coordinates and the movement destination coordinates set by the user are input. The destination-source distance calculation unit 111 calculates the distance in the color space from the destination coordinate to the source coordinate by subtracting the source coordinate from the destination coordinate. The movement source coordinates, the movement destination coordinates, and the distance from the movement destination coordinates to the movement source coordinates are defined as follows, and a calculation formula is shown.
Source coordinates: O (Ro, Go, Bo)
Destination coordinates: T (Rt, Gt, Bt)
Source / Source Distance: Lto (Rlto, Glto, Blto)
Lto = (Rt-Ro, Gt-Go, Bt-Bo)

図4は、色空間(GB断面)における移動元座標と、移動先座標との距離Ltoの概念を示している。なお、図4では、図面の制約上、2次元断面を示しているが、移動先−移動元距離算出部111は、3次元空間上での距離を算出する。   FIG. 4 shows the concept of the distance Lto between the movement source coordinates and the movement destination coordinates in the color space (GB cross section). In FIG. 4, a two-dimensional cross section is shown due to the restriction of the drawing, but the movement destination-movement source distance calculation unit 111 calculates a distance in a three-dimensional space.

移動先−移動元距離算出部111は、算出した移動元/移動元間距離(Lto)を補正範囲ゲイン・オフセット調整部112に供給する。   The movement destination-movement source distance calculation unit 111 supplies the calculated movement source / movement source distance (Lto) to the correction range gain / offset adjustment unit 112.

補正範囲ゲイン・オフセット調整部112は、供給された移動元/移動元間距離(Lto)を基に、RGBの各軸毎の補正範囲を定める。補正範ゲイン、補正範囲オフセットは、ユーザが適宜設定する。設定を行わない場合、デフォルト値が用いられる。以下、補正範囲E、補正範囲ゲインEgain、補正範囲オフセットEofsを定義し、補正範囲ゲイン・オフセット調整部112の用いる補正範囲Eの算出式(数1)〜(数3)を記載する。
補正範囲: E (Re, Ge, Be)
補正範囲ゲイン:Egain
補正範囲オフセット:Eofs
The correction range gain / offset adjustment unit 112 determines a correction range for each axis of RGB based on the supplied movement source / movement source distance (Lto). The correction range gain and the correction range offset are appropriately set by the user. If no setting is made, the default value is used. Hereinafter, the correction range E, the correction range gain Egain, and the correction range offset Eofs are defined, and calculation formulas (Expression 1) to (Expression 3) of the correction range E used by the correction range gain / offset adjustment unit 112 are described.
Correction range: E (Re, Ge, Be)
Correction range gain: Egain
Correction range offset: Eofs

Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491

なお、補正範囲ゲインEgainは、“1”〜“5”の間でユーザが調整可能であるものとするが、“3”程度に設定されることを前提とする。補正範囲オフセットEofsは、8bit(256)階調の場合、8〜64の間でユーザが調整可能であるものとするが、16程度に設定されることを前提とする。   The correction range gain Egain can be adjusted by the user between “1” and “5”, but it is assumed that the correction range gain Egain is set to about “3”. The correction range offset Eofs can be adjusted by the user between 8 and 64 in the case of 8-bit (256) gradation, but it is assumed that the correction range offset Eofs is set to about 16.

ユーザは、補正範囲ゲインEgain、及び補正範囲オフセットEofsを調整することにより、移動元座標と移動先座標の距離Ltoに応じて、自動的に補正範囲Eの大きさを設定することができる。補正範囲ゲインEgain及び補正範囲オフセットEofsを大きくするほど、補正範囲Eの範囲が広くなる(図4において、楕円球範囲が大きくなる)。なお、補正範囲ゲインEgainは、1以下の値とはならないため、補正範囲E内に移動元座標、移動先座標が原則として含まれる。補正範囲ゲイン・オフセット調整部112は、算出した補正範囲Eを補正範囲楕円球式算出部115に供給する。   The user can automatically set the size of the correction range E according to the distance Lto between the movement source coordinates and the movement destination coordinates by adjusting the correction range gain Egain and the correction range offset Eofs. The larger the correction range gain Egain and the correction range offset Eofs, the wider the range of the correction range E (in FIG. 4, the elliptical sphere range becomes larger). Since the correction range gain Egain does not take a value of 1 or less, the movement source coordinates and the movement destination coordinates are included in the correction range E in principle. The correction range gain / offset adjustment unit 112 supplies the calculated correction range E to the correction range elliptic sphere type calculation unit 115.

移動先−移動元直線傾き算出部113は、移動先座標と、移動先座標と、からRG断面の傾き(Δrg)及びGB断面の傾き(Δgb)を算出する。詳細には、移動先−移動元直線傾き算出部113は、移動元座標のR座標(Ro)、G座標(Go)と、移動先座標のR座標(Rt)、G座標(Gt)と、の位置関係からRG断面の傾き(Δrg)を算出する。同様に、移動先−移動元直線傾き算出部113は、移動元座標のG座標(Go)、B座標(Bo)と、移動先のG座標(Gt)、B座標(Bt)と、の位置関係からGB断面の傾き(Δgb)を算出する。詳細には、移動先−移動元直線傾き算出部113は、以下の算出式(数4)、(数5)を用いてRG断面の傾き(Δrg)、及びGB断面の傾き(Δgb)を算出する。 The movement destination-movement source linear inclination calculation unit 113 calculates the inclination (Δrg) of the RG cross section and the inclination (Δgb) of the GB cross section from the movement destination coordinates and the movement destination coordinates. Specifically, the movement destination-movement source linear inclination calculation unit 113 includes an R coordinate (Ro) and a G coordinate (Go) of the movement source coordinate, an R coordinate (Rt) and a G coordinate (Gt) of the movement destination coordinate, The slope (Δrg) of the RG cross section is calculated from the positional relationship. Similarly, the movement destination-movement source linear inclination calculation unit 113 calculates the positions of the movement coordinates G coordinates (Go) and B coordinates (Bo) and the movement destination G coordinates (Gt) and B coordinates (Bt). The inclination (Δgb) of the GB cross section is calculated from the relationship. Specifically, the destination-source linear slope calculation unit 113 calculates the slope of the RG cross section (Δrg) and the slope of the GB cross section (Δgb) using the following formulas (Equation 4) and (Equation 5). To do.

Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491

移動先−移動元直線傾き算出部113は、算出したRG断面の傾き(Δrg)及びGB断面の傾き(Δgb)を回転角度算出部114に供給する。図4では、GB断面の傾き(Δgb)が示されている。 The destination-movement source straight line inclination calculation unit 113 supplies the calculated RG cross section inclination (Δrg) and GB cross section inclination (Δgb) to the rotation angle calculation unit 114. In FIG. 4, the inclination (Δgb) of the GB cross section is shown.

回転角度算出部114は、供給されたRG断面の傾き(Δrg)及びGB断面の傾き(Δgb)から補正範囲Eの外周が構成する楕円球を回転する角度(θrg,θgb)を算出する。詳細には、回転角度算出部114は、以下の算出式(数6)、(数7)を用いて回転角度(θrg, θgb)を算出する。 The rotation angle calculation unit 114 calculates the angles (θrg, θgb) for rotating the elliptic sphere formed by the outer periphery of the correction range E from the supplied RG cross section inclination (Δrg) and GB cross section inclination (Δgb). Specifically, the rotation angle calculation unit 114 calculates the rotation angle (θrg, θgb) using the following calculation formulas (Equation 6) and (Equation 7).

Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491

補正範囲楕円球式算出部115は、補正範囲の楕円球式を算出する処理部である。補正範囲楕円球式算出部115は、補正範囲ゲイン・オフセット調整部112が算出した補正範囲Eの外周が示す楕円球を、回転角度算出部114が算出した角度(θrg,θgb)だけ各軸において軸回転することにより最終的な補正範囲Eの楕円球式を算出する。具体的には、補正範囲楕円球式算出部115は、座標変数(R0,G0,B0)を以下の式(数8)を用いてRG軸回転をした座標(R1,G1,*)を算出する。そして、補正範囲楕円球式算出部115は、座標(R1,G1,*)を以下の式(数9)を用いてRG軸回転をして座標(R1,G2,B1)を算出する。補正範囲楕円球式算出部115は、この座標点(R1,G2,B1)から、軸回転後の楕円球式の数式(数10)を算出する。 The correction range elliptic sphere type calculation unit 115 is a processing unit that calculates an elliptic sphere type of the correction range. The correction range elliptic sphere type calculation unit 115 applies the elliptic sphere indicated by the outer periphery of the correction range E calculated by the correction range gain / offset adjustment unit 112 to each axis by the angles (θrg, θgb) calculated by the rotation angle calculation unit 114. The final ellipsoidal correction range E is calculated by rotating the shaft. Specifically, the correction range ellipsoidal sphere calculation unit 115 calculates coordinates (R1, G1, *) obtained by rotating the coordinate variable (R0, G0, B0) using the following formula (Equation 8). To do. Then, the correction range ellipsoidal sphere formula calculation unit 115 calculates the coordinates (R1, G2, B1) by rotating the coordinates (R1, G1, *) by the RG axis using the following formula (Equation 9). The correction range elliptic sphere formula calculation unit 115 calculates the elliptic sphere formula (Equation 10) after the axis rotation from the coordinate points (R1, G2, B1).

Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491
Figure 2016054491

補正範囲楕円球式算出部115は、算出した補正範囲Eの楕円球式を格子点移動量算出部120(交点算出部122)に供給する。 The correction range elliptic sphere calculation unit 115 supplies the calculated elliptic sphere type of the correction range E to the lattice point movement amount calculation unit 120 (intersection point calculation unit 122).

図5は、補正範囲Eの回転の概念を示す図である。なお、図5は、RG断面の回転概念を示している。図示するように、補正範囲Eは、移動元座標と移動先座標との位置関係に応じて回転される。すなわち、補正範囲楕円球式算出部115は、移動元座標と移動先座標とを結んだ直線が楕円球の長辺方向と等しくなるように補正範囲Eを回転させる。 FIG. 5 is a diagram showing the concept of rotation of the correction range E. FIG. 5 shows the concept of rotation of the RG cross section. As illustrated, the correction range E is rotated according to the positional relationship between the movement source coordinates and the movement destination coordinates. That is, the correction range elliptic sphere type calculation unit 115 rotates the correction range E so that the straight line connecting the movement source coordinates and the movement destination coordinates is equal to the long side direction of the elliptic sphere.

図6は、移動元座標、移動先座標、及び補正範囲を示す楕円球の関係を3次元的に示した図である。図示するように、楕円球は、移動元座標及び移動先座標を内部に有する。 FIG. 6 is a diagram three-dimensionally showing the relationship between the movement source coordinates, the movement destination coordinates, and the elliptical sphere indicating the correction range. As shown in the figure, the elliptical sphere has movement source coordinates and movement destination coordinates inside.

上述したように、ユーザは、移動元座標と移動先座標を1点ずつ設定する。補正範囲算出部110は、上記した一連の処理により自動的に補正範囲Eを算出する。上記した補正範囲Eの算出手法では、補正範囲を示す楕円球の中心は、補正元座標となる。しかしながら、上記の算出手法は、補正範囲Eの楕円球を算出する手法の一例にすぎず、楕円球の中心は、移動元座標と移動先座標の中間座標であっても良く、移動元座標(移動先座標)の近辺座標であっても良い。 As described above, the user sets the movement source coordinates and the movement destination coordinates one by one. The correction range calculation unit 110 automatically calculates the correction range E through the series of processes described above. In the above-described method for calculating the correction range E, the center of the ellipsoid indicating the correction range is the correction source coordinate. However, the above calculation method is merely an example of a method for calculating an elliptical sphere of the correction range E, and the center of the elliptical sphere may be an intermediate coordinate between the movement source coordinate and the movement destination coordinate. The coordinates in the vicinity of the (destination coordinates) may be used.

さらに、上記した補正範囲Eの算出手法では、補正範囲は楕円球で示される。しかし、補正範囲Eを示す式は必ずしも楕円球式等の複雑な数式である必要はなく、上記の楕円球式に相当した範囲を示すもの(すなわち、移動元座標と移動先座標との位置関係を基に算出された範囲を示すもの)であれば、直線式等の簡易な数式であってもよい。直線式で示される補正範囲Eは、例えば正立方体(8角形)、長立方体(8角形、10角形、12角形)等がある。 Furthermore, in the above-described method for calculating the correction range E, the correction range is indicated by an elliptical sphere. However, the formula indicating the correction range E is not necessarily a complicated formula such as an elliptic sphere formula, and shows a range corresponding to the above elliptic sphere formula (that is, the positional relationship between the movement source coordinates and the movement destination coordinates). As long as it indicates a range calculated based on the above, a simple mathematical expression such as a linear expression may be used. The correction range E indicated by the linear formula includes, for example, a regular cube (octagon), a long cube (octagon, 10-gon, 12-gon).

続いて、格子点移動量算出部120の構成を及び動作を図7を参照して説明する。図7は、格子点移動量算出部120の構成を示すブロック図である。まず、格子点移動量算出部120の処理の概要を説明する。 Next, the configuration and operation of the lattice point movement amount calculation unit 120 will be described with reference to FIG. FIG. 7 is a block diagram illustrating a configuration of the lattice point movement amount calculation unit 120. First, an outline of the processing of the lattice point movement amount calculation unit 120 will be described.

格子点移動量算出部120は、補正範囲楕円球式算出部115から入力された補正範囲Eの楕円球式が示す楕円球内の各格子点の移動量を算出する。例えば、格子点移動料算出部20は、図4(A)の補正範囲内の各格子点の移動量を算出する。 The grid point movement amount calculation unit 120 calculates the movement amount of each grid point in the elliptic sphere indicated by the elliptic sphere formula of the correction range E input from the correction range elliptic sphere type calculation unit 115. For example, the grid point movement fee calculation unit 20 calculates the movement amount of each grid point within the correction range of FIG.

詳細には、まず、格子点移動量算出部120は、各格子点と移動元座標を通る直線と、入力された楕円球式が示す楕円球と、の交点を算出する。そして、格子点移動量算出部120は、当該交点と、移動元座標と、の距離(正規化距離)を算出する。格子点移動量算出部120は、移動元座標と、当該格子点と、の距離も算出する。格子点移動量算出部120は、当該距離(移動元座標と当該格子点との距離)と、正規化距離と、の比から移動影響度を算出する。そして、格子点移動量算出部120は、当該影響度と、移動元座標、移動先座標、格子点座標との関係から格子点のRGB座標毎の移動量を算出する。格子点移動量算出部120は、格子点座標に対し、RGB座標毎の移動量を加算して当該格子点の移動後の座標を算出する。移動後の座標は、記憶色補正のテーブルデータとなる。 Specifically, first, the lattice point movement amount calculation unit 120 calculates an intersection point between each lattice point and a straight line passing through the movement source coordinates and the elliptic sphere indicated by the input elliptic sphere formula. Then, the lattice point movement amount calculation unit 120 calculates the distance (normalized distance) between the intersection point and the movement source coordinates. The grid point movement amount calculation unit 120 also calculates the distance between the movement source coordinates and the grid point. The grid point movement amount calculation unit 120 calculates the movement influence degree from the ratio between the distance (the distance between the movement source coordinate and the grid point) and the normalized distance. Then, the lattice point movement amount calculation unit 120 calculates the movement amount for each RGB coordinate of the lattice point from the relationship between the degree of influence and the movement source coordinate, the movement destination coordinate, and the lattice point coordinate. The lattice point movement amount calculation unit 120 adds the movement amount for each RGB coordinate to the lattice point coordinates to calculate the coordinates after the movement of the lattice points. The coordinates after the movement become table data for memory color correction.

なお、以下の説明では、格子点(上下左右との距離が全て均一な座標配置)を扱うこととして説明するが、必ずしもこれに限られない。格子点移動量算出部120(各点移動量算出部)は、格子点以外の並びを持つ各座標点の移動量を算出する構成でも良い。この場合、3次元ルックアップテーブル部200は、各座標点の距離関係を参照して補間処理を行えばよい。 In the following description, it is assumed that grid points (coordinate arrangements where the distances between the top, bottom, left, and right are all uniform) are handled, but the present invention is not necessarily limited thereto. The lattice point movement amount calculation unit 120 (each point movement amount calculation unit) may be configured to calculate the movement amount of each coordinate point having an arrangement other than the lattice points. In this case, the three-dimensional lookup table unit 200 may perform interpolation processing with reference to the distance relationship between the coordinate points.

続いて、格子点移動量算出部120の詳細な構成、及び各構成処理部の動作について説明する。格子点移動量算出部120は、移動元−格子点直線式算出部121と、交点算出部122と、移動元−交点距離算出部123と、移動元−格子点距離算出部124と、影響度算出部125と、移動特性設定部126と、座標算出部127と、を備える。 Next, the detailed configuration of the grid point movement amount calculation unit 120 and the operation of each configuration processing unit will be described. The lattice point movement amount calculation unit 120 includes a movement source-grid point linear equation calculation unit 121, an intersection point calculation unit 122, a movement source-intersection point distance calculation unit 123, a movement source-grid point distance calculation unit 124, and an influence degree. A calculation unit 125, a movement characteristic setting unit 126, and a coordinate calculation unit 127 are provided.

移動元−格子点直線式算出部121は、移動元座標と、補正範囲E内に含まれる各座標と、を結ぶ直線の直線式を算出する。ここで、補正範囲E内に含まれる任意の格子点座標D、座標変数INPUTを以下のように定義すると、直線式は一般的な3次元の直線方程式により以下の式(数11)として算出される。
補正範囲楕円球内の格子点座標: D (Rd, Gd, Bd)
座標変数: (R0,G0,B0)
The movement source-grid point linear equation calculation unit 121 calculates a linear equation of a straight line connecting the movement source coordinates and each coordinate included in the correction range E. Here, when an arbitrary grid point coordinate D and coordinate variable INPUT included in the correction range E are defined as follows, the linear equation is calculated as the following equation (Equation 11) by a general three-dimensional linear equation. The
Lattice point coordinates within the correction range ellipsoid: D (Rd, Gd, Bd)
Coordinate variable: (R0, G0, B0)

Figure 2016054491
Figure 2016054491

移動元−格子点直線式算出部121は、算出した各格子点にかかる直線式(数11)を交点算出部122に供給する。 The movement source-grid point linear equation calculation unit 121 supplies the calculated linear equation (Equation 11) for each lattice point to the intersection calculation unit 122.

交点算出部122には、補正範囲楕円球式算出部115から入力された補正範囲Eの楕円球式(軸回転後の楕円球式、(数10))、及び各格子点から算出した直線式(数11)が入力される。交点算出部122は、楕円球(補正範囲Eの楕円球)と直線(移動元座標と任意格子点を結ぶ直線)の交点を、楕円球式に直線式を代入することにより算出する。以下、代入式を示す。はじめにR1にかかる代入式(数12)を示す。 The intersection calculation unit 122 includes an elliptical sphere type (ellipsoidal type after axis rotation, (Equation 10)) of the correction range E input from the correction range elliptical sphere type calculation unit 115, and a linear formula calculated from each lattice point. (Expression 11) is input. The intersection calculation unit 122 calculates the intersection of the elliptic sphere (the elliptic sphere in the correction range E) and the straight line (the straight line connecting the movement source coordinates and the arbitrary lattice point) by substituting the linear expression into the elliptic sphere. The substitution formula is shown below. First, an assignment formula (Expression 12) relating to R1 is shown.

Figure 2016054491
Figure 2016054491

なお、(数12)では、一部の項を変数Aと置き換えている。同様に、G2にかかる代入式(数13)を示す。なお、代入手法は(数12)と同様であるため、代入処理の詳細は、簡略化して記載する。   In (Equation 12), some terms are replaced with variable A. Similarly, the substitution formula (Formula 13) concerning G2 is shown. Since the substitution method is the same as in (Equation 12), details of the substitution process will be described in a simplified manner.

Figure 2016054491
Figure 2016054491

なお、(数13)では、一部の項を変数Bと置き換えている。同様に、B1にかかる代入式(数14)を示す。なお、(数14)では、一部の項を変数Cと置き換えている。   In (Equation 13), some terms are replaced with variable B. Similarly, the substitution formula (Formula 14) concerning B1 is shown. In (Equation 14), some terms are replaced with variable C.

Figure 2016054491
Figure 2016054491

上記式より、交点Crは、以下の式(数15)により求めることができる。
交点Cr (Rcr, Gcr, Bcr)
From the above equation, the intersection point Cr can be obtained by the following equation (Equation 15).
Intersection Cr (Rcr, Gcr, Bcr)

Figure 2016054491
Figure 2016054491

また、Rd = Roの場合、直線式(数11)においてゼロ除算が発生する。よって、上述のRcr及びB0は、以下の(数16)となる。   Further, when Rd = Ro, division by zero occurs in the linear equation (Equation 11). Therefore, Rcr and B0 described above are expressed by the following (Equation 16).

Figure 2016054491
Figure 2016054491

(数16)を楕円球式(数10)に代入すると、以下の式(数17)〜(数19)を得る。   Substituting (Equation 16) into the elliptic sphere equation (Equation 10), the following equations (Equation 17) to (Equation 19) are obtained.

Figure 2016054491
Figure 2016054491

Figure 2016054491
Figure 2016054491

Figure 2016054491
Figure 2016054491

上記(数17)〜(数19)より、交点Crは、以下の式(数20)により求めることができる。   From the above (Equation 17) to (Equation 19), the intersection Cr can be obtained by the following equation (Equation 20).

Figure 2016054491
Figure 2016054491

また、Gd = Goの場合、直線式(数11)においてゼロ除算が発生する。よって、上述のRcr及びGcrは、以下の(数21)となる。 Further, when Gd = Go, division by zero occurs in the linear equation (Equation 11). Therefore, Rcr and Gcr described above are expressed by the following (Equation 21).

Figure 2016054491
Figure 2016054491

(数21)を楕円球式(数10)に代入すると、以下の式(数22)〜(数24)を得ることができる。 Substituting (Equation 21) into the elliptic sphere equation (Equation 10), the following equations (Equation 22) to (Equation 24) can be obtained.

Figure 2016054491
Figure 2016054491

Figure 2016054491
Figure 2016054491

Figure 2016054491
Figure 2016054491

上記(数22)〜(数24)より、交点Crは、以下の式(数25)により求めることができる。   From the above (Equation 22) to (Equation 24), the intersection Cr can be obtained by the following equation (Equation 25).

Figure 2016054491
Figure 2016054491

交点算出部122は、以上のように、各格子点に対応する交点Crを算出する。交点算出部122は、算出した各格子点に対応する交点Cr(楕円球と、格子点と移動元座標を結ぶ直線と、の交点)の座標を移動元−交点距離算出部123に供給する。   As described above, the intersection calculation unit 122 calculates the intersection Cr corresponding to each lattice point. The intersection calculation unit 122 supplies the coordinates of the intersection Cr (the intersection of the ellipsoid and the straight line connecting the lattice point and the movement source coordinate) corresponding to each calculated lattice point to the movement source-intersection distance calculation unit 123.

移動元−交点距離算出部123は、移動元座標と、各格子点に対応する交点(楕円球と、格子点と移動元座標を結ぶ直線と、の交点)の座標と、の距離Locを算出する。移動元−交点距離算出部123は、三平方の定理を用い、以下の(数26)から距離Locを算出する。   The movement source-intersection distance calculation unit 123 calculates a distance Loc between the movement source coordinates and the coordinates of the intersection corresponding to each grid point (the intersection of the ellipsoid and the straight line connecting the grid point and the movement source coordinate). To do. The source-intersection distance calculation unit 123 calculates the distance Loc from the following (Equation 26) using the three-square theorem.

Figure 2016054491
Figure 2016054491

距離Locは、移動元座標を中心とした移動が発生する範囲を示すことになる。そのため、距離Locを移動範囲の正規化距離とする。移動元−交点距離算出部123は、格子点毎に算出した正規化距離Locを影響度算出部125に供給する。   The distance Loc indicates a range in which movement around the movement source coordinate occurs. Therefore, the distance Loc is set as a normalized distance of the movement range. The movement source-intersection distance calculation unit 123 supplies the normalized distance Loc calculated for each lattice point to the influence calculation unit 125.

移動元−格子点距離算出部124は、移動元座標Oと、任意格子点Dとの距離を算出する。移動元−格子点距離算出部124は、三平方の定理を用い、以下の(数27)から距離Lodを算出する。   The movement source-grid point distance calculation unit 124 calculates the distance between the movement source coordinate O and the arbitrary grid point D. The movement source-grid point distance calculation unit 124 calculates the distance Lod from the following (Equation 27) using the three-square theorem.

Figure 2016054491
Figure 2016054491

移動元−格子点距離算出部124は、格子点毎に算出した距離Lodを影響度算出部125に供給する。なお、図4(B)は、正規化距離Loc及び距離Lodの関係を示す図である。   The movement source-grid point distance calculation unit 124 supplies the distance Lod calculated for each lattice point to the influence degree calculation unit 125. FIG. 4B is a diagram illustrating the relationship between the normalized distance Loc and the distance Lod.

影響度算出部125は、各格子点の移動量算出に用いる影響度Efを算出する。影響度算出部125には、前述の各格子点の正規化距離Loc及び距離Lodが入力される。影響度Efが大きくなるほど、各格子点の移動量は大きくなる。影響度Efは、移動元座標付近から算出される場合に最大となり、交点Crが0(移動が無くなる値)となる。これは、移動元座標が移動の中心となるためである。影響度算出部125は、以下の(数28)により影響度Efを算出する。   The influence calculation unit 125 calculates an influence Ef used for calculating the movement amount of each grid point. The influence degree calculation unit 125 receives the normalized distance Loc and the distance Lod of each lattice point described above. As the influence Ef increases, the amount of movement of each lattice point increases. The degree of influence Ef is maximum when calculated from the vicinity of the movement source coordinates, and the intersection point Cr is 0 (a value at which movement does not occur). This is because the movement source coordinates are the center of movement. The influence degree calculation unit 125 calculates the influence degree Ef by the following (Equation 28).

Figure 2016054491
Figure 2016054491

影響度算出部125は、補正範囲Eの各格子点に対して上述の影響度Efの算出処理を行う。   The influence degree calculation unit 125 performs the above-described influence degree Ef calculation process for each lattice point in the correction range E.

以上より、移動元座標に近い格子点の移動量は、大きくなり、移動元座標から遠ざかるにつれて移動量は小さくなる。補正範囲楕円球上の格子点の移動量(影響度Ef)は、0となる。これにより3次元色空間内での連続性が保証される。連続性が保証されることにより、色歪みの無い記憶色補正が可能となる。   As described above, the movement amount of the lattice point close to the movement source coordinate is increased, and the movement amount is decreased as the distance from the movement source coordinate is increased. The movement amount (influence Ef) of the lattice points on the correction range ellipsoid is zero. This ensures continuity in the three-dimensional color space. By guaranteeing continuity, it is possible to perform memory color correction without color distortion.

影響度算出部125は、算出した各格子点の影響度Efを移動特性設定部126に供給する。   The influence degree calculation unit 125 supplies the calculated influence degree Ef of each lattice point to the movement characteristic setting unit 126.

移動特性設定部126は、各格子点の影響度Efから移動量特性MEを算出する。移動量特性MEは、各格子点の移動量の係数となる。上述した各格子点の影響度Efを移動量とした場合、移動元座標から離れるにつれて移動量(移動量特性ME)は小さくなる。移動特性設定部126は、例えば以下の式(数29)により各格子点の影響度Efから移動量特性MEを算出する。   The movement characteristic setting unit 126 calculates a movement amount characteristic ME from the degree of influence Ef of each grid point. The movement amount characteristic ME is a coefficient of the movement amount of each lattice point. When the influence degree Ef of each lattice point described above is used as the movement amount, the movement amount (movement amount characteristic ME) decreases as the distance from the movement source coordinate increases. The movement characteristic setting unit 126 calculates the movement amount characteristic ME from the influence degree Ef of each grid point, for example, by the following equation (Equation 29).

Figure 2016054491
Figure 2016054491

図8は、影響度Efと移動量特性MEの関係を示す図である。上記(数29)により、影響度Efに応じて移動量(移動量特性ME)が制御される。図8に示すように、当該移動量(移動量特性ME)は、影響度Efのリニアな変化に比べて大きくなる。これにより、より適切な移動量を設定することができる。   FIG. 8 is a diagram showing the relationship between the degree of influence Ef and the movement amount characteristic ME. By the above (Equation 29), the movement amount (movement amount characteristic ME) is controlled according to the influence degree Ef. As shown in FIG. 8, the movement amount (movement amount characteristic ME) is larger than the linear change in the degree of influence Ef. Thereby, a more appropriate amount of movement can be set.

なお、ユーザが、移動特性設定部126が算出した移動量特性MEに満足しない場合、ユーザが移動量特性MEを適宜調節できるようにしても良い。すなわち、ユーザが移動特性設定部126の用いる算出式を適宜設定できるようにしても良い。   When the user is not satisfied with the movement amount characteristic ME calculated by the movement characteristic setting unit 126, the user may be able to adjust the movement amount characteristic ME as appropriate. That is, the calculation formula used by the movement characteristic setting unit 126 may be appropriately set by the user.

移動特性設定部126は、算出した各格子点の移動量特性MEを座標算出部127に供給する。   The movement characteristic setting unit 126 supplies the calculated movement amount characteristic ME of each grid point to the coordinate calculation unit 127.

座標算出部127は、各格子点の移動量特性MEを基に、各格子点の移動量M(Mr, Mg, Mb)を算出し、当該移動量Mを各格子点座標Dに加算して各格子点の補正後座標DC(DCr, DCg, DCb)を算出する。ここで、座標算出部127には、各格子点の移動量特性ME、各格子点座標Dに加えて補正方向が入力される。補正方向は、ユーザにより指定され、圧縮方向または平行方向の一方が指定される。以下、図9を参照し、補正方向について説明する。   The coordinate calculation unit 127 calculates the movement amount M (Mr, Mg, Mb) of each grid point based on the movement amount characteristic ME of each grid point, and adds the movement amount M to each grid point coordinate D. The corrected coordinates DC (DCr, DCg, DCb) of each grid point are calculated. Here, in addition to the movement amount characteristic ME of each grid point and each grid point coordinate D, the correction direction is input to the coordinate calculation unit 127. The correction direction is designated by the user, and one of the compression direction and the parallel direction is designated. Hereinafter, the correction direction will be described with reference to FIG.

図9(A)に示すように、圧縮方向の補正は、ユーザに指定された1点の座標に集中するように座標位置を変更する補正である。これにより、どのような色が入力されても、好ましい色(好ましい座標)に近づくように記憶色補正が行われる。換言すると、色再現範囲が狭くなる補正である。   As shown in FIG. 9A, the correction in the compression direction is a correction for changing the coordinate position so as to concentrate on the coordinates of one point designated by the user. Thereby, no matter what color is input, the memory color correction is performed so as to approach the preferable color (preferable coordinates). In other words, this is a correction that narrows the color reproduction range.

図9(B)に示すように、平行方向の補正は、補正範囲内の格子点を全て同じ方向に移動させる補正である。移動方向は、ユーザが指定した移動元座標と、移動先座標と、を結ぶ方向となる。換言すると、平行方向の補正は、補正範囲内の格子点を全て同じ方向に移動させるため、圧縮方向の補正と比べて色再現範囲が狭くならない。   As shown in FIG. 9B, the correction in the parallel direction is a correction for moving all the lattice points in the correction range in the same direction. The movement direction is a direction connecting the movement source coordinates designated by the user and the movement destination coordinates. In other words, since the correction in the parallel direction moves all the lattice points in the correction range in the same direction, the color reproduction range does not become narrower than the correction in the compression direction.

ユーザは、記憶色補正の目的に応じて、補正方向を指定する。座標算出部127は、指定された補正方向に応じて、以下の算出式から各格子点の移動量M(Mr, Mg, Mb)、及び各格子点の補正後座標DC(DCr, DCg, DCb)を算出する。   The user designates a correction direction according to the purpose of memory color correction. The coordinate calculation unit 127 calculates the movement amount M (Mr, Mg, Mb) of each grid point and the corrected coordinates DC (DCr, DCg, DCb) of each grid point from the following calculation formulas according to the specified correction direction. ) Is calculated.

圧縮方向の算出式は、以下(数30)に示される。   The calculation formula of the compression direction is shown below (Equation 30).

Figure 2016054491
Figure 2016054491

平行方向の算出式は、以下(数31)に示される。   The calculation formula in the parallel direction is shown below (Equation 31).

Figure 2016054491
Figure 2016054491

座標算出部127は、補正範囲E内の各格子点の補正後座標DCをテーブルデータメモリ部220に供給する。これにより、テーブルデータメモリ部220は、任意格子点Dを対応する補正後座標DCに変換するルックアップテーブルを保持する。 The coordinate calculation unit 127 supplies the post-correction coordinates DC of each grid point within the correction range E to the table data memory unit 220. Accordingly, the table data memory unit 220 holds a lookup table for converting the arbitrary grid point D into the corresponding corrected coordinate DC.

続いて、本実施の形態にかかる画像処理装置1の効果について説明する。上述の通り、ユーザは、色空間における移動元座標と移動先座標の指定のみを行う。この指定に応じて、補正範囲算出部110は、補正範囲Eを自動算出し、格子点移動量算出部120は、補正範囲E内の各格子点の変換先座標を算出し、当該変換先座標を変換規則(本実施の形態では3次元ルックアップテーブル)に反映する。すなわち、ユーザは、色空間上での色変換(補正)処理に関する知識、ノウハウを持っていない場合でも容易に色空間上での色変換処理を実現すること(上述の例では、記憶色補正を実現すること)ができる。 Next, effects of the image processing apparatus 1 according to the present embodiment will be described. As described above, the user only specifies the movement source coordinates and the movement destination coordinates in the color space. In response to this designation, the correction range calculation unit 110 automatically calculates the correction range E, the grid point movement amount calculation unit 120 calculates the conversion destination coordinates of each grid point in the correction range E, and the conversion destination coordinates Are reflected in the conversion rule (a three-dimensional lookup table in this embodiment). That is, the user can easily realize the color conversion process on the color space even if he / she has no knowledge and know-how about the color conversion (correction) process on the color space (in the above example, the memory color correction is performed). Can be realized).

さらに、ユーザは、変換規則を逐次設定する必要がない。すなわち、ユーザは、記憶色補正にかかるルックアップテーブルの各テーブルデータを逐次設定する必要がない。ユーザは、移動元座標と移動先座標のみを設定する。これにより、ユーザの設定の工数を削減することができる。 Further, the user does not need to set conversion rules sequentially. That is, the user does not need to sequentially set each table data of the lookup table for the memory color correction. The user sets only the movement source coordinates and the movement destination coordinates. Thereby, the man-hour of a user's setting can be reduced.

さらに、本実施の形態にかかる補正範囲算出部110は、移動元座標と移動先座標の位置関係に応じて、補正範囲Eを回転(RG軸平面での回転、GB軸平面での回転)している(図5)。詳細には、補正範囲算出部110は、移動元座標と前記移動先座標を結ぶ直線が長軸方向となるように、補正範囲Eを回転している。これにより、色空間歪みがない記憶色補正を行うことができる。この詳細を図10を参照して説明する。 Furthermore, the correction range calculation unit 110 according to the present embodiment rotates the correction range E (rotation on the RG axis plane, rotation on the GB axis plane) according to the positional relationship between the movement source coordinates and the movement destination coordinates. (FIG. 5). Specifically, the correction range calculation unit 110 rotates the correction range E so that a straight line connecting the movement source coordinates and the movement destination coordinates is in the major axis direction. Thereby, memory color correction without color space distortion can be performed. Details will be described with reference to FIG.

図10(A)は、補正範囲を回転しなかった場合の色空間上での座標変化を示す図である。図10(A)に示すように、移動先座標付近に位置する各座標の移動量が、急激に変化している。 FIG. 10A is a diagram illustrating a change in coordinates on the color space when the correction range is not rotated. As shown in FIG. 10A, the movement amount of each coordinate located in the vicinity of the movement destination coordinates is changing rapidly.

図10(B)は、補正範囲を回転した場合(すなわち、本実施の形態にかかる画像処理装置1の構成)の色空間上での座標変化を示す図である。図示するように、移動元座標と、格子点座標が遠ざかるにつれて、当該格子点座標の移動量(移動ベクトルの大きさ)がなだらかに変化する(たとえば、図10(B)(2)の示す補正量は、図10(A)(1)の示す補正量よりも大きい)。補正範囲内の各座標の移動量は、移動元座標との距離が大きくなるにつれて徐々に小さくなるように制御されるためである。色の変化が急激に起きないため、色空間歪みを回避することができる。 FIG. 10B is a diagram illustrating coordinate changes on the color space when the correction range is rotated (that is, the configuration of the image processing apparatus 1 according to the present embodiment). As shown in the figure, as the movement source coordinates and the grid point coordinates move away, the movement amount (the magnitude of the movement vector) of the grid point coordinates changes gently (for example, the correction shown in FIGS. 10B and 10B). The amount is larger than the correction amount shown in FIGS. This is because the movement amount of each coordinate within the correction range is controlled so as to gradually decrease as the distance from the movement source coordinate increases. Since the color change does not occur abruptly, color space distortion can be avoided.

さらに、本実施の形態にかかる画像処理装置1によれば、補正したい色のみを補正することができる。図11を参照して、この効果を説明する。 Furthermore, according to the image processing apparatus 1 according to the present embodiment, it is possible to correct only the color to be corrected. This effect will be described with reference to FIG.

図11は、肌色の記憶色補正を示す概念図である。図11(A)は、補正範囲Eを回転しなかった場合の補正範囲Eを示す図である。補正範囲Eを回転しない場合、補正対象の色(肌色)以外の色を示す座標も補正対象としてしまう。そのため、ユーザとしては補正をしたくない色についての補正(色空間上での座標移動)が行われてしまう。 FIG. 11 is a conceptual diagram showing a skin color memory color correction. FIG. 11A is a diagram showing the correction range E when the correction range E is not rotated. When the correction range E is not rotated, coordinates indicating colors other than the color to be corrected (skin color) are also subject to correction. Therefore, the correction (coordinate movement in the color space) for the color that the user does not want to correct is performed.

一方、図11(B)は、補正範囲Eを回転した場合(すなわち、本実施の形態にかかる画像処理装置1の構成)の補正範囲Eを示す図である。補正範囲Eを回転した場合、補正対象の色(肌色)を示す座標のみを補正対象とする。さらに、各格子点の変換先座標も肌色の存在範囲内となる。そのため、本実施の形態にかかる画像処理装置1は、補正を行いたくない色の補正は行わず、補正したい色のみを適切に補正することができる。 On the other hand, FIG. 11B is a diagram showing the correction range E when the correction range E is rotated (that is, the configuration of the image processing apparatus 1 according to the present embodiment). When the correction range E is rotated, only the coordinates indicating the correction target color (skin color) are set as correction targets. Furthermore, the coordinates of the conversion destination of each grid point are also within the skin color existing range. Therefore, the image processing apparatus 1 according to the present embodiment can appropriately correct only the color to be corrected without correcting the color that is not desired to be corrected.

図10、図11を参照して説明したように、本実施の形態にかかる画像処理装置1は、ノウハウ無しでの補正処理の実現、工数の削減という効果に加えて補正品質の向上も図れるという効果を奏する。ユーザが手動で設定を行う場合、各設定項目の最適化に注力してしまうため、最終的な色空間歪みの発生等を引き起こす場合がある。一方、本実施の形態にかかる画像処理装置は、移動元座標と移動先座標との関係から補正範囲Eを定める。補正範囲E内の座標の移動量は、移動元座標との距離が大きくなるにつれて小さくなるように制御される。このため、画像処理装置は、前述のように色空間歪み等の無い最適な画像を生成することができる。   As described with reference to FIGS. 10 and 11, the image processing apparatus 1 according to the present embodiment can improve the correction quality in addition to the effect of realizing the correction process without know-how and reducing the man-hours. There is an effect. When the user manually sets, the focus is on optimization of each setting item, which may cause final color space distortion. On the other hand, the image processing apparatus according to the present embodiment determines the correction range E from the relationship between the movement source coordinates and the movement destination coordinates. The movement amount of the coordinates within the correction range E is controlled so as to decrease as the distance from the movement source coordinates increases. Therefore, the image processing apparatus can generate an optimal image without color space distortion as described above.

なお、本実施の形態の画像処理装置1内の格子点移動量算出部120は、移動特性設定部126を備える構成としたが、必ずしもこれに限られず影響度Efから直接変換先座標を算出しても良い。 Note that the lattice point movement amount calculation unit 120 in the image processing apparatus 1 of the present embodiment is configured to include the movement characteristic setting unit 126, but the present invention is not limited to this, and the conversion destination coordinates are calculated directly from the degree of influence Ef. May be.

<実施の形態2>
本実施の形態にかかる画像処理装置は、画像毎(たとえば動画像用のフレーム毎)の絵柄を考慮した記憶色補正を実現できることを特徴とする。本実施の形態にかかる画像処理装置について、以下に説明する。
<Embodiment 2>
The image processing apparatus according to the present embodiment is characterized in that memory color correction can be realized in consideration of a picture for each image (for example, for each frame for moving images). The image processing apparatus according to this embodiment will be described below.

図12は、本実施の形態にかかる画像処理装置の構成を示すブロック図である。画像処理装置1は、テーブルデータ生成部100、3次元ルックアップテーブル部200に加え、絵柄適応部300を備える。なお、テーブルデータ生成部100及び3次元ルックアップテーブル部200の構成及び処理は、実施の形態1と同様であるため、絵柄適応部300の構成及び動作について以下に説明する。 FIG. 12 is a block diagram showing the configuration of the image processing apparatus according to this embodiment. The image processing apparatus 1 includes a pattern adaptation unit 300 in addition to the table data generation unit 100 and the three-dimensional lookup table unit 200. Since the configuration and processing of the table data generation unit 100 and the three-dimensional lookup table unit 200 are the same as those in the first embodiment, the configuration and operation of the picture adaptation unit 300 will be described below.

絵柄適応部300は、記憶色補正対象検出部301と、記憶色補正決定部302と、3次元ヒストグラム生成部303と、ヒストグラム解析部304と、移動元・移動先算出部305と、を備える。   The pattern adaptation unit 300 includes a memory color correction target detection unit 301, a memory color correction determination unit 302, a three-dimensional histogram generation unit 303, a histogram analysis unit 304, and a movement source / destination calculation unit 305.

記憶色補正対象検出部301は、画像内の記憶色補正の対象となるオブジェクトや背景等(以下の記載では、オブジェクトや背景等を総称して記憶色補正対象とも記載する。)を検出する。記憶色補正対象としては、例えば顔、空、海、もみじ、桜、木々の緑等が挙げられる。記憶色補正対象検出部301は、これらの記憶色補正対象の形状、色、輝度、画像内の位置(たとえば、画面上部:空、画面下部:海)等を検出、解析する。当該検出処理には、一般的に用いられる画像認識技術を用いれば良い。近年、固有の記憶色補正対象を検出する画像認識技術が各分野で広く開発されている。特に、多くのデジタルスチルカメラ等の商品は、顔検出等の機能を備えている。 The memory color correction target detection unit 301 detects objects, backgrounds, and the like (in the following description, the objects, backgrounds, etc. are collectively referred to as memory color correction targets) in the image. Examples of the memory color correction target include face, sky, sea, maple, cherry blossom, and green trees. The memory color correction target detection unit 301 detects and analyzes the shape, color, brightness, position in the image (for example, screen upper part: sky, screen lower part: sea), and the like. For the detection process, a generally used image recognition technique may be used. In recent years, image recognition techniques for detecting a unique memory color correction target have been widely developed in various fields. In particular, many products such as digital still cameras have functions such as face detection.

記憶色補正対象検出部301は、これらの一般的な記憶色補正対象の検出技術を利用し、検出した情報(記憶色補正対象が存在するか、形状、色、輝度、画像内の位置)を記憶色補正決定部302及び3次元ヒストグラム取得部303に供給する。 The memory color correction target detection unit 301 uses these general memory color correction target detection techniques, and detects the detected information (whether the memory color correction target exists, shape, color, luminance, position in the image). The data is supplied to the memory color correction determination unit 302 and the three-dimensional histogram acquisition unit 303.

記憶色補正決定部302は、記憶色補正を行うか否かを判定する処理部である。記憶色補正決定部302には、ユーザが補正を行いたい記憶色補正対象の情報が入力される。本実施の形態において、ユーザは、補正したい記憶色補正対象を指定する。ここで、ユーザは、記憶色補正対象を複数指定しても良い。複数設定する場合、ユーザは、記憶色補正対象毎に移動元座標のプリセット値と移動先座標のプリセット値を設定する。例えば、青空と桜の花の記憶色補正を同時に行う場合、ユーザは、青空に関する移動元座標のプリセット値と移動先座標のプリセット値、及び桜の花に関する移動元座標のプリセット値と移動先座標のプリセット値を設定する。 The memory color correction determination unit 302 is a processing unit that determines whether or not to perform memory color correction. The memory color correction determination unit 302 receives information on a memory color correction target that the user wants to correct. In the present embodiment, the user designates a memory color correction target to be corrected. Here, the user may designate a plurality of memory color correction targets. When a plurality of settings are made, the user sets a preset value for the movement source coordinates and a preset value for the movement destination coordinates for each memory color correction target. For example, when performing memory color correction for blue sky and cherry blossoms at the same time, the user can preset the source coordinate preset value and destination coordinate preset value for the blue sky, and the source coordinate preset value and destination coordinate preset for the cherry blossom. Set the value.

記憶色補正決定部302は、記憶色補正対象検出部301の検出した情報(記憶色補正対象が画像内に存在するか、形状、色、輝度、画像内の位置)と、ユーザの指定する記憶色補正対象と、を比較し、記憶色補正を行うか否かを判定する。 The memory color correction determination unit 302 includes information detected by the memory color correction target detection unit 301 (whether the memory color correction target exists in the image, shape, color, luminance, position in the image), and memory specified by the user. The color correction target is compared, and it is determined whether or not the memory color correction is performed.

画像内にユーザの指定する記憶色補正対象が存在しない場合、記憶色補正を行っても補正による効果が生じない可能性がある。さらに、対象ではない記憶色補正対象に対して記憶色補正を行ってしまう恐れがある。これらの理由により、記憶色補正決定部302は、記憶色補正を行うか否かを判定する。 If there is no memory color correction target designated by the user in the image, there is a possibility that the effect of the correction will not occur even if the memory color correction is performed. Furthermore, there is a possibility that memory color correction is performed on a memory color correction target that is not the target. For these reasons, the memory color correction determination unit 302 determines whether or not to perform memory color correction.

記憶色補正決定部302による判定は、画像(フレーム)毎に判定される。しかしながら、3次元ルックアップテーブルを複数保持しているシステム(後述)や3次元ルックアップテーブルにより補正する補正エリアを指定できるシステムにおいては、記憶色補正決定部302は、画面のエリア毎に上述の判定(記憶色補正を行うか否かの判定)を行っても良い。これにより、更に精度の良い記憶色補正を実現することができる。 The determination by the memory color correction determination unit 302 is determined for each image (frame). However, in a system that holds a plurality of three-dimensional lookup tables (described later) or a system that can specify a correction area to be corrected by a three-dimensional lookup table, the memory color correction determination unit 302 is described above for each screen area. Determination (determination of whether or not to perform memory color correction) may be performed. Thereby, a more accurate memory color correction can be realized.

記憶色補正決定部302は、判定結果を移動元・移動先算出部305に供給する。 The memory color correction determination unit 302 supplies the determination result to the movement source / destination calculation unit 305.

3次元ヒストグラム生成部303には、入力画像全体のRGB値が入力されるとともに、記憶色補正対象検出部301が検出した情報が入力される。3次元ヒストグラム取得部303は、画面全体、及び記憶色補正対象が検出された画像領域の3次元ヒストグラムを生成する。3次元ヒストグラム生成部303は、生成した2種類の3次元ヒストグラムをヒストグラム解析部304に供給する。 The three-dimensional histogram generation unit 303 receives the RGB values of the entire input image and the information detected by the memory color correction target detection unit 301. The three-dimensional histogram acquisition unit 303 generates a three-dimensional histogram of the entire screen and the image area where the memory color correction target is detected. The three-dimensional histogram generation unit 303 supplies the two types of generated three-dimensional histograms to the histogram analysis unit 304.

ヒストグラム解析部304は、入力された2種類の3次元ヒストグラム(記憶色補正対象を検出した画像領域の3次元ヒストグラム、画像全体の3次元ヒストグラム)を解析する。まず、記憶色補正対象を検出した画像領域の3次元ヒストグラムの解析について説明する。 The histogram analysis unit 304 analyzes two types of input three-dimensional histograms (a three-dimensional histogram of an image area in which a memory color correction target is detected and a three-dimensional histogram of the entire image). First, the analysis of the three-dimensional histogram of the image area where the memory color correction target is detected will be described.

記憶色補正対象を検出した画像領域には同一オブジェクト、または同一背景が表示されている。例えば、青空を検出した領域には、青空を構成する画素が存在する。そのため、色空間上のヒストグラムでは、3次元空間内のある領域に値が集中していることが想定される。ここで、ヒストグラムにおいて、ある一定頻度以下の色座標を無視する。すると、3次元空間内のある色座標を中心とした楕円球形状のヒストグラムを得ることができる。ヒストグラム解析部304は、当該楕円球形状の中心の座標、すなわち記憶色補正対象の中心的な色の座標を解析結果として検出する。当該検出方法には、楕円球位置中心検出、楕円球重心検出の2種類が主に考えられる。まず、楕円球位置中心検出について説明する。 The same object or the same background is displayed in the image area where the memory color correction target is detected. For example, in the area where the blue sky is detected, there are pixels constituting the blue sky. Therefore, in the histogram on the color space, it is assumed that the values are concentrated in a certain area in the three-dimensional space. Here, color coordinates having a certain frequency or less are ignored in the histogram. Then, an elliptical spherical histogram centered on a certain color coordinate in the three-dimensional space can be obtained. The histogram analysis unit 304 detects the coordinates of the center of the elliptic sphere shape, that is, the coordinates of the central color of the memory color correction target as an analysis result. There are mainly two types of detection methods, ellipsoidal position center detection and ellipsoidal centroid detection. First, ellipsoidal position center detection will be described.

ヒストグラム解析部304は、上述のヒストグラムに関する楕円球内のRGBの各軸における最大値、最小値、中心値を以下のように定義し、以下の式により楕円球の中心値を算出する。
楕円球内最大値 Rmax, Gmax, Bmax
楕円球内最小値 Rmin, Gmin, Bmin
楕円球内中心値 Rcen, Gcen, Bcen
The histogram analysis unit 304 defines the maximum value, the minimum value, and the center value of each of the RGB axes in the elliptic sphere relating to the above-described histogram as follows, and calculates the center value of the elliptic sphere using the following formula.
Maximum value in elliptic sphere Rmax, Gmax, Bmax
Minimum value in ellipsoidal sphere Rmin, Gmin, Bmin
Median value in elliptic sphere Rcen, Gcen, Bcen

Figure 2016054491
Figure 2016054491

続いて、楕円球重心検出について説明する。ヒストグラム解析部304は、上述の楕円球内のRGBの各軸における累積値、楕円球重心値を以下のように定義し、以下の式(数33)により楕円球の重心値を算出する。
楕円球内累積値 Rsgm, Gsgm, Bsgm
総画素数 Dot
楕円球内重心値 Rgra, Ggra, Bgra
Next, the ellipsoidal centroid detection will be described. The histogram analysis unit 304 defines the cumulative value and the elliptical centroid value of each of the RGB axes in the elliptical sphere as follows, and calculates the elliptical centroid value by the following equation (Equation 33).
Cumulative value in elliptic sphere Rsgm, Gsgm, Bsgm
Total pixels Dot
The center of gravity of the ellipsoid sphere Rgra, Ggra, Bgra

Figure 2016054491
Figure 2016054491

なお、ヒストグラム解析部304は、上記以外の方法によりヒストグラム内の楕円球の中心/重心(すなわちオブジェクトや背景の中心的な色の座標)を算出しても良い。ヒストグラム解析部304は、解析により得られた座標を移動元・移動先算出部305に供給する。 Note that the histogram analysis unit 304 may calculate the center / centroid of the elliptic sphere in the histogram (that is, the coordinates of the central color of the object or background) by a method other than the above. The histogram analysis unit 304 supplies the coordinates obtained by the analysis to the movement source / destination calculation unit 305.

次に、ヒストグラム解析部304による画像全体のヒストグラムの解析について説明する。ヒストグラム解析部304は、ユーザが記憶色補正対象毎に設定した移動元座標のプリセット値と移動先座標のプリセット値との間、及び周辺の色座標においてヒストグラムがどのような形状になっているかを解析する。具体的には、ヒストグラム解析部304は、記憶色補正前の状態において、すでに移動先座標のプリセット値の近辺に色が存在しているか(移動先の色と似た色を持つ座標が複数存在しているか)を解析する。また、ヒストグラム解析部304は、移動元座標のプリセット値から移動先座標のプリセット値の間の色の分布割合を解析する。 Next, analysis of the histogram of the entire image by the histogram analysis unit 304 will be described. The histogram analysis unit 304 determines the shape of the histogram between the preset value of the movement source coordinates and the preset value of the movement destination coordinates set by the user for each memory color correction target and in the surrounding color coordinates. To analyze. Specifically, the histogram analysis unit 304 determines whether a color already exists in the vicinity of the preset value of the destination coordinate in the state before the memory color correction (a plurality of coordinates having colors similar to the destination color exist). Is analyzed). Further, the histogram analysis unit 304 analyzes the color distribution ratio between the preset value of the movement source coordinates and the preset value of the movement destination coordinates.

ヒストグラム解析部304による画像全体のヒストグラムの解析の詳細を図13を参照して詳細に説明する。図13では、移動元座標のプリセット値OPと移動先座標のプリセット値TPとの間に7つのエリアを設定している。なお、図13では、説明の便宜上、2次元の座標空間を示しているが、ヒストグラム解析部304は、実際には3次元の座標空間を扱う。 Details of the histogram analysis of the entire image by the histogram analysis unit 304 will be described in detail with reference to FIG. In FIG. 13, seven areas are set between the preset value OP of the movement source coordinates and the preset value TP of the movement destination coordinates. In FIG. 13, for convenience of explanation, a two-dimensional coordinate space is shown, but the histogram analysis unit 304 actually handles a three-dimensional coordinate space.

ヒストグラム解析部304は、この7つのエリア毎にヒストグラムを解析する。ヒストグラム解析部304は、各エリアに位置する画素数が所定閾値を超えているか否かを判定する。超えている場合、ヒストグラム解析部304は、補正前に当該エリアに色が存在する(補正前に当該エリアに所定数以上の画素が存在する)と判定する。当該判定は、移動元座標のプリセット値に近いエリア1からエリア7まで順に行われる。ヒストグラム解析部304は、所定数以上の画素が確認できたエリアを検出した時点で、判定処理を終了する。ヒストグラム解析部304は、所定数以上の画素が確認できたエリアの代表座標を存在座標TE(TEr, TEg, TEb)として検出する。ヒストグラム解析部304は、存在座標TE(TEr, TEg, TEb)を移動元・移動先算出部305に供給する。 The histogram analysis unit 304 analyzes the histogram for each of the seven areas. The histogram analysis unit 304 determines whether or not the number of pixels located in each area exceeds a predetermined threshold value. If it exceeds, the histogram analysis unit 304 determines that a color exists in the area before correction (a predetermined number or more pixels exist in the area before correction). This determination is performed in order from area 1 to area 7 close to the preset value of the movement source coordinates. The histogram analysis unit 304 ends the determination process when detecting an area where a predetermined number of pixels or more can be confirmed. The histogram analysis unit 304 detects the representative coordinates of an area where a predetermined number of pixels or more can be confirmed as existence coordinates TE (TEr, TEg, TEb). The histogram analysis unit 304 supplies the existing coordinates TE (TEr, TEg, TEb) to the movement source / destination calculation unit 305.

例えば、エリア1には所定数以上の画素が存在せず、エリア2に所定数以上の画素が存在していた場合、ヒストグラム解析部304は、エリア3以降の判定は行わない。そして、ヒストグラム解析部304は、エリア2の代表座標を存在座標TE(TEr, TEg, TEb)として検出する。なお、エリア7までの判定を行い、所定数以上の画素が存在したエリアがなかった場合、ヒストグラム解析部304は、存在座標TEが存在しないとみなす。 For example, when there are no more than a predetermined number of pixels in area 1 and there are more than a predetermined number of pixels in area 2, the histogram analysis unit 304 does not make a determination after area 3. Then, the histogram analysis unit 304 detects the representative coordinates of the area 2 as the existing coordinates TE (TEr, TEg, TEb). Note that the determination up to the area 7 is performed, and if there is no area where a predetermined number of pixels or more exist, the histogram analysis unit 304 considers that the existence coordinates TE do not exist.

なお、図13の説明では、ヒストグラム内のエリアを7つとしたが必ずしもこれに限られない。エリア数をより多くした場合、ヒストグラム解析部304は、詳細な存在座標の検出を行うことができる、すなわち存在判定の精度を向上することができる。これにより、後述する記憶色補正の移動先座標の設定精度を向上させることができる。 In the description of FIG. 13, the number of areas in the histogram is seven, but the number is not necessarily limited to this. When the number of areas is increased, the histogram analysis unit 304 can perform detailed presence coordinate detection, that is, improve the accuracy of presence determination. As a result, it is possible to improve the setting accuracy of the destination coordinates for memory color correction described later.

次に、移動元・移動先算出部305について説明する。本実施の形態において、ユーザは、補正対象となるオブジェクトや背景毎に移動元座標Oのプリセット値OPと移動先座標Tのプリセット値TPとを設定する。移動元・移動先算出部305は、当該プリセット値と、記憶色補正決定部302の判定結果と、ヒストグラム解析部304の解析結果と、を基にテーブルデータ生成部100に供給する移動元座標Oと移動先座標Tとを算出する。すなわち、本実施の形態では、ユーザが入力した移動元座標と移動先座標とをそのまま使うのではなく、座標位置を調整してテーブルデータ生成部100に供給する。 Next, the movement source / destination calculation unit 305 will be described. In the present embodiment, the user sets a preset value OP of the movement source coordinate O and a preset value TP of the movement destination coordinate T for each object and background to be corrected. The movement source / movement destination calculation unit 305 supplies the movement source coordinates O supplied to the table data generation unit 100 based on the preset value, the determination result of the memory color correction determination unit 302, and the analysis result of the histogram analysis unit 304. And the destination coordinate T are calculated. That is, in this embodiment, the movement source coordinates and the movement destination coordinates input by the user are not used as they are, but the coordinate positions are adjusted and supplied to the table data generation unit 100.

はじめに、移動元・移動先算出部305による移動元座標Oの算出処理について説明する。ユーザは、記憶色補正対象毎の移動元座標Oのプリセット値OP(OPr, OPg, ORb)を設定する。移動元・移動先算出部305は、ヒストグラム解析部304の解析結果を受信する。解析結果とは、ユーザが指定する記憶色補正対象の中心色座標OC(OCr, OCg, OCb)である。移動元・移動先算出部305は、プリセット値OP(OPr, OPg, ORb)と、中心色座標OC(OCr, OCg, OCb)と、の間に移動元座標O(Ro, Go, Bo)を後述の式(数34)により算出する。ユーザは、中心色座標OC(OCr, OCg, OCb)に移動元座標OPのプリセット値をどれだけ近づけるかの指標である追従度F1(0〜100%)を設定できる。追従度F1を0%とした場合、移動元座標Oは、移動元座標Oのプリセット値OP(OPr, OPg, ORb)と等しくなる。追従度F1を100%とした場合、移動元座標Oは、中心色座標OC(OCr, OCg, OCb)と等しくなる。追従度F1を50%とした場合、移動元座標Oは、移動元座標Oのプリセット値OP(OPr, OPg, ORb)と、中心色座標OC(OCr, OCg, OCb)と、の中間値となる。以下、移動元座標O(Ro, Go, Bo)の算出式(数34)を示す。 First, the calculation process of the movement source coordinate O by the movement source / destination calculation unit 305 will be described. The user sets a preset value OP (OPr, OPg, ORb) of the movement source coordinate O for each memory color correction target. The movement source / movement destination calculation unit 305 receives the analysis result of the histogram analysis unit 304. The analysis result is the center color coordinate OC (OCr, OCg, OCb) of the memory color correction target specified by the user. The movement source / destination calculation unit 305 sets the movement source coordinates O (Ro, Go, Bo) between the preset value OP (OPr, OPg, ORb) and the center color coordinates OC (OCr, OCg, OCb). This is calculated by the following formula (Equation 34). The user can set a follow-up degree F1 (0 to 100%) that is an index of how close the preset value of the movement source coordinate OP is to the center color coordinate OC (OCr, OCg, OCb). When the follow-up degree F1 is set to 0%, the movement source coordinate O becomes equal to the preset value OP (OPr, OPg, ORb) of the movement source coordinate O. When the follow-up degree F1 is 100%, the movement source coordinate O is equal to the center color coordinate OC (OCr, OCg, OCb). When the tracking degree F1 is 50%, the movement source coordinate O is an intermediate value between the preset value OP (OPr, OPg, ORb) of the movement source coordinate O and the center color coordinate OC (OCr, OCg, OCb). Become. Hereinafter, a calculation formula (Formula 34) of the movement source coordinates O (Ro, Go, Bo) is shown.

Figure 2016054491
Figure 2016054491

なお、追従度F1は、50%程度を前提に設定されるものとし、ユーザが明示の指定をしない場合のデフォルト値も50%程度とする。 The follow-up degree F1 is set on the assumption of about 50%, and the default value when the user does not specify explicitly is also about 50%.

次に、移動元・移動先算出部305による移動先座標の算出処理について説明する。ユーザは、記憶色補正対象毎の移動元座標のプリセット値TP(TPr, TPg, TRb)を設定する。移動元・移動先算出部305は、ヒストグラム解析部304の解析結果を受信し、補正前の状態において既に移動先の方向に一定画素数以上の画素が存在しているかを判定する。存在している場合、移動元・移動先算出部305は、入力された存在座標TE(TEr, TEg, TEb)と移動先座標Tのプリセット値TP(TPr, TPg, TRb)と、を基に最終的な移動先座標Tを後述の式(数35)により算出する。ユーザは、存在座標TEに移動先座標Tのプリセット値をどれだけ近づけるかの指標である追従度F2(0〜100%)を設定できる。追従度F2を0%とした場合、移動先座標Tは、移動先座標Tのプリセット値TP(TPr, TPg, TRb)と等しくなる。追従度F2を100%とした場合、移動先座標Tは、存在座標TE(TEr, TEg, TEb)と等しくなる。追従度F2を50%とした場合、移動先座標Tは、移動先座標Tのプリセット値TP(TPr, TPg, TRb)と、存在座標TE(TEr, TEg, TEb)と、の中間値となる。以下、移動先座標T(Rt, Gt, Bt)の算出式(数35)を示す。 Next, the processing for calculating the movement destination coordinates by the movement source / movement destination calculation unit 305 will be described. The user sets preset values TP (TPr, TPg, TRb) of the movement source coordinates for each memory color correction target. The movement source / destination calculation unit 305 receives the analysis result of the histogram analysis unit 304 and determines whether or not there are pixels of a certain number or more in the direction of the movement destination in the state before correction. If it exists, the movement source / movement destination calculation unit 305 is based on the input existence coordinates TE (TEr, TEg, TEb) and the preset values TP (TPr, TPg, TRb) of the movement destination coordinates T. The final movement destination coordinate T is calculated by the following equation (Equation 35). The user can set a follow-up degree F2 (0 to 100%) that is an index of how close the preset value of the destination coordinate T is to the existing coordinate TE. When the follow-up degree F2 is set to 0%, the movement destination coordinate T becomes equal to the preset value TP (TPr, TPg, TRb) of the movement destination coordinate T. When the follow-up degree F2 is 100%, the movement destination coordinate T becomes equal to the existence coordinate TE (TEr, TEg, TEb). When the follow-up degree F2 is 50%, the destination coordinate T is an intermediate value between the preset value TP (TPr, TPg, TRb) of the destination coordinate T and the existing coordinate TE (TEr, TEg, TEb). . Hereinafter, a calculation formula (Expression 35) of the movement destination coordinates T (Rt, Gt, Bt) is shown.

Figure 2016054491
Figure 2016054491

なお、追従度F2は、50%程度を前提に設定されるものとし、ユーザが明示の指定をしない場合のデフォルト値も50%程度とする。 The follow-up degree F2 is set on the assumption of about 50%, and the default value when the user does not specify explicitly is also about 50%.

移動元・移動先算出部305は、算出した移動元座標O(Ro, Go, Bo)及び移動先座標T(Rt, Gt, Bt)をテーブルデータ生成部100に供給する。 The movement source / movement destination calculation unit 305 supplies the calculated movement source coordinates O (Ro, Go, Bo) and movement destination coordinates T (Rt, Gt, Bt) to the table data generation unit 100.

続いて、絵柄を考慮しない記憶色補正の問題点と、本実施の形態にかかる画像処理装置1の効果について説明する。はじめに、絵柄を考慮しない記憶色補正の問題点を説明する。 Next, the problem of memory color correction that does not take into account the pattern and the effect of the image processing apparatus 1 according to the present embodiment will be described. First, the problem of memory color correction without considering a picture will be described.

絵柄を考慮しない記憶色補正では、記憶色補正対象の有無に関わらず、定常的な1つのパターンが入力されたルックアップテーブルを用いて補正処理が行われる。このため、補正対象とすることを意図していない記憶色補正対象にかかる画素を補正してしまう危険がある。 In memory color correction that does not consider a pattern, correction processing is performed using a look-up table to which one stationary pattern is input regardless of whether or not there is a memory color correction target. For this reason, there is a risk of correcting a pixel relating to a memory color correction target that is not intended to be corrected.

さらに、画像内にユーザが補正を行いたい記憶色補正対象が存在する場合であっても、記憶色補正対象(たとえば人の顔)がその記憶色補正対象として想定していた色領域とは異なる色をしているため、補正したい画素を補正範囲内に十分に含めることが出来ない恐れがあった。 Furthermore, even if there is a memory color correction target that the user wants to correct in the image, the memory color correction target (for example, a human face) is different from the color region that is assumed as the memory color correction target. Because of the color, there is a possibility that the pixel to be corrected cannot be sufficiently included in the correction range.

ルックアップテーブルを用いた記憶色補正では、複数の記憶色補正対象に対して補正を同時に行うことが多い。この場合、補正範囲が干渉する場合がある。図14を参照して、当該状況を説明する。図示するように、ある記憶色補正対象に関する補正範囲と、他の記憶色補正対象に関する補正範囲に干渉が生じる場合がある。この場合、干渉する領域内における補正をどのように行えばよいかが不明となる。そのため、一般に理想とする補正量よりも補正強度を抑えて処理を行う必要が生じる。すなわち、図14に示すように補正範囲を縮小した上で補正処理を行う。このため、十分な補正効果を得ることが出来ない。 In memory color correction using a lookup table, correction is often performed simultaneously on a plurality of memory color correction targets. In this case, the correction range may interfere. The situation will be described with reference to FIG. As shown in the figure, interference may occur between a correction range related to a certain memory color correction target and a correction range related to another memory color correction target. In this case, it is unclear how to perform correction in the interfering area. For this reason, it is generally necessary to perform processing while suppressing the correction intensity from an ideal correction amount. That is, correction processing is performed after the correction range is reduced as shown in FIG. For this reason, a sufficient correction effect cannot be obtained.

次に、本実施の形態にかかる画像処理装置1の効果を説明する。本実施の形態にかかる画像処理装置1は、記憶色補正対象の検出を行い、当該記憶色補正対象や画像全体のヒストグラムを基に移動元座標と移動先座標を自動的に算出している。これにより、本実施の形態1にかかる画像処理装置1は、以下の2つの効果を得ることができる。
ユーザが補正を行いたい記憶色補正対象に対してのみ補正処理を行うことができる。
ユーザが補正を行いたい記憶色補正対象に対して十分な強度の補正を行うことができる。
Next, effects of the image processing apparatus 1 according to the present embodiment will be described. The image processing apparatus 1 according to the present embodiment detects a memory color correction target, and automatically calculates a movement source coordinate and a movement destination coordinate based on the memory color correction target and a histogram of the entire image. Thereby, the image processing apparatus 1 according to the first embodiment can obtain the following two effects.
Correction processing can be performed only for the memory color correction target that the user wants to correct.
A sufficient intensity correction can be performed on the memory color correction target that the user wants to correct.

まず、本実施の形態にかかる画像処理装置1において、「ユーザが補正を行いたい記憶色補正対象に対してのみ補正処理を行うことができる」という効果を奏する理由を説明する。 First, the reason why the image processing apparatus 1 according to the present embodiment has an effect that “the correction process can be performed only on the memory color correction target that the user wants to correct” will be described.

記憶色補正決定部302は、ユーザが指定した記憶色補正対象があるか否かを算出する。ユーザが指定した記憶色補正対象が存在する場合にのみ、移動元移動先算出部305は、移動元座標Oと移動先座標Tとを算出する。これにより、画像処理装置1(3次元ルックアップテーブル部200)は、当該記憶色補正対象に関する記憶色補正のみを行う、すなわち上述の(1)の効果を奏することができる。 The memory color correction determination unit 302 calculates whether there is a memory color correction target designated by the user. The movement source movement destination calculation unit 305 calculates the movement source coordinates O and the movement destination coordinates T only when there is a memory color correction target designated by the user. Thereby, the image processing apparatus 1 (three-dimensional lookup table unit 200) can perform only the memory color correction related to the memory color correction target, that is, the effect (1) described above can be achieved.

記憶色補正対象が1画面内に複数存在しない場合、すなわち1つしかない場合、画像処理装置1は、唯一の記憶色補正対象について記憶色補正を行う。そのため、画像処理装置1は、補正範囲の干渉に対する対応を行う必要が無くなる。 When there are not a plurality of memory color correction targets in one screen, that is, when there is only one, the image processing apparatus 1 performs the memory color correction for only one memory color correction target. Therefore, the image processing apparatus 1 does not need to cope with correction range interference.

なお、記憶色補正決定部302がユーザの指定する記憶色補正対象が複数あると判定し、両者の補正範囲が干渉する場合、画像処理装置1は、この干渉領域に属する色座標に対して意図しない変換を行うことがあり得る。しかし、後述する実施の形態4または5の構成によりこの問題は解消する。 When the memory color correction determination unit 302 determines that there are a plurality of memory color correction targets specified by the user and the correction ranges of the two interfere with each other, the image processing apparatus 1 intends for the color coordinates belonging to the interference area. It is possible that no conversion is performed. However, this problem is solved by the configuration of the fourth or fifth embodiment described later.

次に、本実施の形態にかかる画像処理装置1において、「(2)ユーザが補正を行いたい記憶色補正対象に対して十分な強度の補正を行うことができる。」という効果を奏する理由を説明する。当該理由は、以下の2点である。 Next, in the image processing apparatus 1 according to the present embodiment, the reason is that “(2) a sufficient intensity correction can be performed on a memory color correction target that the user wants to correct”. explain. The reason is the following two points.

第1の理由は、以下のとおりである。前述のように、記憶色補正決定部302は、ユーザが指定した記憶色補正対象があるか否かを算出する。そして、移動元移動先算出部305は、ユーザが指定し、かつ検出された記憶色補正対象のみについて補正範囲を設定する。すなわち、例えば図14において、補正範囲をユーザが指定した記憶色補正対象に関するもののみに限定することができる。そのため、色空間上での補正範囲を示す楕円球の数を減らすことができる。これにより、記憶色補正の補正範囲の干渉を考慮する必要が減少し、補正範囲を縮小する等の対応を行う必要を減らすことができる。補正範囲を縮小する必要が減るため、十分な強度の補正を行うことが可能となる。 The first reason is as follows. As described above, the memory color correction determination unit 302 calculates whether there is a memory color correction target designated by the user. Then, the movement source movement destination calculation unit 305 sets a correction range only for the memory color correction target designated and detected by the user. That is, for example, in FIG. 14, the correction range can be limited to only those related to the memory color correction target designated by the user. Therefore, it is possible to reduce the number of elliptic spheres indicating the correction range in the color space. As a result, it is possible to reduce the need to consider interference in the correction range of the memory color correction, and to reduce the need to take measures such as reducing the correction range. Since the need to reduce the correction range is reduced, it is possible to perform sufficient intensity correction.

次に上述の(2)の効果を奏する第2の理由を図15を参照しつつ説明する。なお図15の説明において、処理を行う画像に青空を表示した領域、及び青い花を表示した領域があるものとする。なお、ユーザは、青空の記憶色補正のみを行いたいものとする。 Next, a second reason for achieving the effect (2) described above will be described with reference to FIG. In the description of FIG. 15, it is assumed that the image to be processed includes an area displaying a blue sky and an area displaying a blue flower. It is assumed that the user wants to perform only blue sky memory color correction.

図15(A)は、実施の形態1にかかる画像処理装置1による記憶色補正を示す概念図である。この場合、画像処理装置1は、ユーザが入力した移動元座標と移動先座標をそのまま用いて補正範囲を定める。そのため、画像内において青空と青い花のように似た色のオブジェクトが存在していた場合、画像処理装置1は、補正を意図していない青い花の色まで変化させてしまう。   FIG. 15A is a conceptual diagram illustrating memory color correction by the image processing apparatus 1 according to the first embodiment. In this case, the image processing apparatus 1 determines the correction range using the movement source coordinates and the movement destination coordinates input by the user as they are. For this reason, when there are objects having similar colors such as blue sky and blue flowers in the image, the image processing apparatus 1 changes the color of the blue flowers that are not intended to be corrected.

図15(B)は、本実施の形態にかかる画像処理装置1による記憶色補正を示す概念図である。ヒストグラム解析部304は、色空間において、移動元座標のプリセット値と、移動先座標のプリセット値との間に所定数以上の画素が存在するか否かを判定する。仮に、所定数以上の画素が存在しない場合、移動元・移動先算出部305は、移動元座標のプリセット値をそのまま移動元座標とし、移動先座標のプリセット値をそのまま移動先座標とする。これにより、画像処理装置1は、十分な強度の記憶色補正を行うことができる。 FIG. 15B is a conceptual diagram showing memory color correction by the image processing apparatus 1 according to the present embodiment. The histogram analysis unit 304 determines whether or not a predetermined number or more pixels exist between the preset value of the movement source coordinate and the preset value of the movement destination coordinate in the color space. If there are no more than a predetermined number of pixels, the movement source / destination calculation unit 305 uses the movement source coordinate preset value as it is as the movement source coordinate, and the movement destination coordinate preset value as it is as the movement destination coordinate. Thereby, the image processing apparatus 1 can perform memory color correction with sufficient intensity.

一方、所定数以上の画素が存在した場合、移動元・移動先算出部305は、上述の式により、移動先座標のプリセット値(座標)を移動元座標のプリセット値に近づける方向に移動させ、当該移動点を移動先座標と決定する。例えば、画像内に青空と青い花が表示されている場合、画像処理装置1は、移動先座標のプリセット値を移動元座標のプリセット値に近づけた上で記憶色補正を行う(図15(B)参照)。ここで、移動元・移動先算出部305は、所定数以上の画素が存在するエリアに応じて、プリセット値(座標)の移動量を適宜調節している。これにより、図15(B)に示すように、画像処理装置1は、補正対象ではないオブジェクト(背景)に影響が出ない範囲を自動算出しつつ、補正対象のオブジェクト(背景)の記憶色補正を行うことができる。 On the other hand, when there are a predetermined number of pixels or more, the movement source / destination calculation unit 305 moves the preset value (coordinates) of the movement destination coordinates in a direction closer to the preset value of the movement source coordinates by the above formula, The movement point is determined as a movement destination coordinate. For example, when a blue sky and a blue flower are displayed in the image, the image processing apparatus 1 performs memory color correction after making the preset value of the movement destination coordinate close to the preset value of the movement source coordinate (FIG. 15B )reference). Here, the movement source / destination calculation unit 305 appropriately adjusts the movement amount of the preset value (coordinates) according to an area where a predetermined number of pixels or more exist. As a result, as shown in FIG. 15B, the image processing apparatus 1 automatically calculates a range that does not affect the object (background) that is not the correction target, and corrects the memory color of the correction target object (background). It can be performed.

上述のように、一般的な画像処理装置は、他のオブジェクト(背景)への弊害を考慮して記憶色補正の補正範囲を一律に縮小していた。しかし、本実施の形態にかかる画像処理装置1は、色空間内での色の存在位置を解析することにより(上述のヒストグラム解析を行うことにより)、補正を意図しない他のオブジェクトが存在する可能性を検知し、フレーム(画像)毎に最適な補正範囲を定めることができる。これにより、本実施の形態にかかる画像処理装置1は、画像(フレーム)の絵柄に応じ、十分な補正量を持つ記憶色補正を実現することができる。 As described above, a general image processing apparatus uniformly reduces the correction range of the memory color correction in consideration of adverse effects on other objects (backgrounds). However, the image processing apparatus 1 according to the present embodiment may have another object that is not intended to be corrected by analyzing the position of the color in the color space (by performing the above-described histogram analysis). The optimal correction range can be determined for each frame (image). Thereby, the image processing apparatus 1 according to the present embodiment can realize memory color correction having a sufficient correction amount according to the pattern of the image (frame).

動画像は、時間の経過に応じて絵柄が変化する。本実施の形態にかかる画像処理装置1は、絵柄の変化に追従して記憶色補正に用いる移動元座標、移動先座標を適宜調整する。そのため、本実施の形態にかかる画像処理装置1は、動画像に対して、精度の良い記憶色補正を実現することができる。 The design of the moving image changes with time. The image processing apparatus 1 according to the present embodiment appropriately adjusts the movement source coordinates and the movement destination coordinates used for memory color correction following the change in the pattern. Therefore, the image processing apparatus 1 according to the present embodiment can realize accurate memory color correction for moving images.

なお、上述の説明では、絵柄適応部300は、移動元座標のプリセット値及び移動先座標のプリセット値の調整を行ったが、必ずしもこれに限られず、一方の調整のみを行ってもよい。例えば、絵柄適応部300は、移動元座標のプリセット値の調整のみを行い、移動先座標に関してはユーザ入力をそのまま採用する。このような構成であっても、画像処理装置1は、一定の効果を奏することができる。   In the above description, the pattern adaptation unit 300 adjusts the preset value of the movement source coordinates and the preset value of the movement destination coordinates, but is not necessarily limited to this, and only one of the adjustments may be performed. For example, the picture adaptation unit 300 only adjusts the preset value of the movement source coordinates, and adopts the user input as it is for the movement destination coordinates. Even with such a configuration, the image processing apparatus 1 can achieve certain effects.

<実施の形態3>
本実施の形態にかかる画像処理装置は、3次元ルックアップテーブルの保持するテーブルデータ数を制限できることを特徴とする。本実施の形態にかかる画像処理装置は、主に動画像に対するダイナミック処理(絵柄を解析し、当該絵柄に応じた記憶色補正を行う処理)を前提とする。本実施の形態にかかる画像処理装置は、実施の形態2の変形であるため、実施の形態2と異なる点(補正範囲算出部110の構成、動作)を中心に説明する。
<Embodiment 3>
The image processing apparatus according to the present embodiment is characterized in that the number of table data held in the three-dimensional lookup table can be limited. The image processing apparatus according to the present embodiment is premised mainly on dynamic processing (processing for analyzing a picture and performing memory color correction according to the picture) for a moving image. Since the image processing apparatus according to the present embodiment is a modification of the second embodiment, a description will be given focusing on differences from the second embodiment (configuration and operation of the correction range calculation unit 110).

図16は、本実施の形態にかかる補正範囲算出部110の構成を示すブロック図である。補正範囲算出部110は、図3の構成に加えて変換座標数制限部116を備える。   FIG. 16 is a block diagram illustrating a configuration of the correction range calculation unit 110 according to the present embodiment. The correction range calculation unit 110 includes a conversion coordinate number limiting unit 116 in addition to the configuration of FIG.

ユーザは、3次元ルックアップテーブルに設定するテーブルデータ制限数を変換座標数制限部116に設定する。ここで、テーブルデータ制限数は、3次元ルックアップテーブルに変換対象として設定する格子点の上限数を意味する。例えば、ユーザは、記憶色補正の対象とする動画像データの種別、動画像データの画像データサイズ(縦と横のピクセル数)、要求動作スピード等を考慮して設定するテーブルデータ制限数を設定すればよい。   The user sets the table data limit number set in the three-dimensional lookup table in the conversion coordinate number limit unit 116. Here, the table data limit number means the upper limit number of grid points set as a conversion target in the three-dimensional lookup table. For example, the user sets a table data limit number to be set in consideration of the type of moving image data subject to memory color correction, the image data size (number of vertical and horizontal pixels) of the moving image data, the required operation speed, etc. do it.

変換座標数制限部116には、補正範囲楕円球式算出部115が算出した各記憶色補正対象の楕円球式が入力される。たとえば、青空の記憶色補正と、桜の花の記憶色補正を行う場合、2つの楕円球式が入力される。変換座標数制限部116は、これらの楕円球式を基に補正対象となる格子点の総数を算出する。楕円球式から当該楕円球内に含まれる格子点数は、格子点距離を基に算出可能である(図17(A))。ここで、変換座標数制限部116は、補正対象とする全ての楕円球式を基に補正対象となる格子点の総数を算出する。変換座標数制限部116は、ユーザから入力されたテーブルデータ制限数と、楕円球式を基に算出した補正対象となる格子点の総数と、を比較する。   The conversion coordinate number limiting unit 116 is input with the elliptical spherical type to be corrected for each memory color calculated by the correction range elliptical spherical type calculating unit 115. For example, when the blue sky memory color correction and the cherry blossom memory color correction are performed, two elliptic sphere types are input. The conversion coordinate number limiting unit 116 calculates the total number of lattice points to be corrected based on these elliptic sphere formulas. From the ellipsoidal formula, the number of grid points included in the ellipsoidal sphere can be calculated based on the grid point distance (FIG. 17A). Here, the conversion coordinate number limiting unit 116 calculates the total number of lattice points to be corrected based on all elliptic spheres to be corrected. The conversion coordinate number restriction unit 116 compares the table data restriction number input from the user with the total number of lattice points to be corrected, which are calculated based on the ellipsoidal formula.

テーブルデータ制限数が補正対象となる格子点の総数以上である場合、変換座標数制限部116は、補正範囲楕円球式算出部115に楕円球式の出力を指示する。   When the table data limit number is equal to or greater than the total number of grid points to be corrected, the conversion coordinate number limit unit 116 instructs the correction range elliptic sphere type calculation unit 115 to output an elliptic sphere type.

一方、テーブルデータ制限数が補正対象となる格子点の総数よりも少ない場合、変換座標数制限部116は、補正範囲ゲイン・オフセット調整部112にゲイン及び/またはオフセットの再調整を指示する。ここで、変換座標数制限部116は、補正範囲ゲイン・オフセット調整部112にテーブルデータ制限数と補正対象となる格子点の総数との比率を合わせて通知する。そして、変換座標数制限部116は、補正範囲楕円球式算出部115に楕円球式の出力の禁止を指示する。   On the other hand, when the table data limit number is smaller than the total number of grid points to be corrected, the conversion coordinate number limit unit 116 instructs the correction range gain / offset adjustment unit 112 to readjust the gain and / or offset. Here, the conversion coordinate number restriction unit 116 notifies the correction range gain / offset adjustment unit 112 together with the ratio of the table data restriction number and the total number of grid points to be corrected. Then, the conversion coordinate number limiting unit 116 instructs the correction range elliptic sphere type calculation unit 115 to prohibit the output of the elliptic sphere type.

補正範囲ゲイン・オフセット調整部112は、通知された比率を参照して、楕円球が小さくなるようにゲイン及び/またはオフセットを再設定する(図17(B))。なお、比率を参照して再設定するため、補正範囲ゲイン・オフセット調整部112は、必要以上に楕円球を小さくしすぎることを回避することができる。   The correction range gain / offset adjustment unit 112 refers to the notified ratio and resets the gain and / or offset so that the elliptical sphere becomes smaller (FIG. 17B). Since the correction is made with reference to the ratio, the correction range gain / offset adjustment unit 112 can avoid making the ellipsoid too small more than necessary.

ゲイン及び/またはオフセットの再設定の後に、補正範囲楕円球式算出部115は、再び楕円球式を算出する。   After resetting the gain and / or offset, the correction range elliptic sphere formula calculation unit 115 calculates the elliptic sphere formula again.

なお、上述の説明では、ゲイン及び/またはオフセットの調整により補正範囲を縮小したが、必ずしもこれに限られない。例えば、記憶色補正対象にかかる移動先座標及び/または移動先座標を移動させることにより補正範囲を縮小しても良い。例えば、図17(B)の例では、移動先座標を点線で示す位置に移動させることにより、記憶色補正対象の補正範囲を縮小している。これは、例えば変換座標数制限部116が、対象となる記憶理路対象の移動元座標及び/または移動先座標の位置を変更することを、絵柄適応部300に対して指示すればよい。   In the above description, the correction range is reduced by adjusting the gain and / or offset, but the present invention is not necessarily limited thereto. For example, the correction range may be reduced by moving the movement destination coordinates and / or movement destination coordinates related to the memory color correction target. For example, in the example of FIG. 17B, the correction range of the memory color correction target is reduced by moving the movement destination coordinates to the position indicated by the dotted line. For example, the conversion coordinate number restriction unit 116 may instruct the design adaptation unit 300 to change the position of the movement source coordinate and / or the movement destination coordinate of the target storage path object.

続いて、本実施の形態にかかる画像処理装置の効果について説明する。3次元ルックアップテーブルを用いたダイナミック処理の一般的な課題として、設定するテーブルデータ数の多さが挙げられる。テーブルデータ数が多いために、逐次的にデータが入力される動画像データの処理に3次元ルックアップテーブルを使用することが困難であった。   Next, effects of the image processing apparatus according to this embodiment will be described. As a general problem of dynamic processing using a three-dimensional lookup table, there is a large number of table data to be set. Since the number of table data is large, it is difficult to use a three-dimensional lookup table for processing moving image data in which data is sequentially input.

本実施の形態にかかる画像処理装置は、ユーザの入力したテーブルデータ制限数以下となるようにテーブルデータ数を制限している。すなわち、本実施の形態にかかる画像処理装置1は、たとえば729個(9×9×9)や4913個(17×17×17)といったテーブルサイズのルックアップテーブルに対して格納するデータサイズ数をテーブルデータ制限数以下とする。例えば、729個(9×9×9)の容量を持つルックアップテーブルに対して格納するテーブルデータ数を200個に制限する。これにより、単位時間内に転送されるデータ数の増大が防止でき、システム全体の処理高速化を実現することができる。   The image processing apparatus according to the present embodiment limits the number of table data so as to be less than or equal to the table data limit number input by the user. That is, the image processing apparatus 1 according to the present embodiment stores the number of data sizes stored in a lookup table having a table size such as 729 (9 × 9 × 9) and 4913 (17 × 17 × 17), for example. Less than the table data limit. For example, the number of table data stored for a lookup table having a capacity of 729 (9 × 9 × 9) is limited to 200. Thereby, an increase in the number of data transferred within a unit time can be prevented, and the processing speed of the entire system can be increased.

なお、上述の説明では、楕円球を小さくすることにより3次元ルックアップテーブルに格納するデータ数を減らすこととしたが、必ずしもこれに限られない。例えば、範囲楕円球式算出部115は、処理を行う記憶色補正対象を減らすこと等によってデータ数を減らしても良い。   In the above description, the number of data stored in the three-dimensional lookup table is reduced by reducing the size of the elliptic sphere. However, the present invention is not limited to this. For example, the range ellipsoidal calculation unit 115 may reduce the number of data by reducing the memory color correction target to be processed.

<実施の形態4>
本実施の形態にかかる画像処理装置は、記憶色補正対象が複数存在する場合に、優先順位を考慮して記憶色補正を行う。上述したように、1つの3次元ルックアップテーブルを用いた記憶色補正では、色領域の干渉が生じてしまうケースがある。これにより、複数の対象に対する記憶色補正を同時に実行できない、または十分な補正を行えないことがある。本実施の形態では、画像処理装置に対して、ユーザがオブジェクトや背景毎に記憶色補正の優先順位を設定する。本実施の形態にかかる画像処理装置は、複数のオブジェクトが記憶色補正の対象となった場合であっても、この優先順位に応じて最適な記憶色補正を行う。以下、図18を参照して、本実施の形態にかかる画像処理装置の構成を説明する。さらに、図19を適宜参照して、本実施の形態にかかる動作イメージを説明する。
<Embodiment 4>
The image processing apparatus according to the present embodiment performs memory color correction in consideration of priority when there are a plurality of memory color correction targets. As described above, in memory color correction using one three-dimensional lookup table, there are cases where interference of color regions occurs. As a result, the memory color correction for a plurality of objects may not be performed simultaneously, or sufficient correction may not be performed. In this embodiment, the user sets the priority order of memory color correction for each object or background in the image processing apparatus. The image processing apparatus according to the present embodiment performs optimal memory color correction according to this priority order even when a plurality of objects are subjected to memory color correction. Hereinafter, the configuration of the image processing apparatus according to the present embodiment will be described with reference to FIG. Further, an operation image according to the present embodiment will be described with reference to FIG. 19 as appropriate.

補正範囲算出部110は、図3の構成に加え、補正範囲重複検出部117を備える。補正範囲重複検出部117には、記憶色補正対象の優先順位(数値が少ないほど優先順位が高い)が供給される。この優先順位は、ユーザが設定する。例えば、ユーザは、「優先順位1:青空」、「優先順位2:青い花」、「優先順位3:桜の花」を入力する。 The correction range calculation unit 110 includes a correction range overlap detection unit 117 in addition to the configuration of FIG. The correction range overlap detection unit 117 is supplied with the priority order of the memory color correction target (the smaller the numerical value, the higher the priority order). This priority is set by the user. For example, the user inputs “priority 1: blue sky”, “priority 2: blue flowers”, and “priority 3: cherry blossoms”.

補正範囲重複検出部117には、さらに補正範囲楕円球式算出部115が算出した各記憶色補正対象の楕円球式が入力される。補正範囲重複検出部117は、複数の楕円球式が存在する場合に、楕円球に重複部分があるか否かを判定する。例えば、図19の例では、優先順位1のオブジェクトにかかる記憶色補正の楕円球と、優先順位2のオブジェクトにかかる記憶色補正の楕円球と、の間に重複箇所が存在する。なお、補正範囲重複箇所検出部117は、与えられた楕円球式から公知の3次元空間上の処理により重複があるか否かを判定すればよい。   The correction range overlap detection unit 117 is further input with the elliptical sphere type for each memory color correction calculated by the correction range elliptical sphere type calculation unit 115. The correction range overlap detection unit 117 determines whether or not there is an overlapping portion in the elliptic sphere when there are a plurality of elliptic sphere types. For example, in the example of FIG. 19, there is an overlap between an oval sphere for memory color correction applied to an object with priority 1 and an oval sphere for memory color correction applied to an object with priority 2. It should be noted that the correction range duplication location detection unit 117 may determine whether or not there is duplication by a process in a known three-dimensional space from the given elliptical sphere.

重複がある場合、補正範囲重複検出部117は、優先順位の低い記憶色補正対象、及び重複範囲の大きさを補正範囲ゲイン・オフセット調整部112に通知する。そして、補正範囲重複検出部117は、補正範囲楕円球式算出部115の楕円球式の出力の禁止を指示する。   When there is an overlap, the correction range overlap detection unit 117 notifies the correction range gain / offset adjustment unit 112 of the low-priority memory color correction target and the size of the overlap range. Then, the correction range overlap detection unit 117 instructs the correction range ellipsoidal calculation unit 115 to prohibit the elliptical output.

重複がない場合、補正範囲重複検出部117は、補正範囲楕円球式算出部115に楕円球式の出力を指示する。   When there is no overlap, the correction range overlap detection unit 117 instructs the correction range elliptic sphere type calculation unit 115 to output an elliptic sphere type.

補正範囲ゲイン・オフセット調整部112は、補正範囲重複検出部117からの通知を受信した場合、優先順位の低い記憶色補正対象にかかる楕円球が小さくなるようにゲイン又は/及びオフセットを調整する。ここで、補正範囲ゲイン・オフセット調整部112は、重複範囲の大きさに応じてゲイン又は/及びオフセットを調整する。そして、補正範囲ゲイン・オフセット調整部112は、調整後に算出したRGB毎の補正範囲を補正範囲楕円球式算出部115に供給する。   When the correction range gain / offset adjustment unit 112 receives the notification from the correction range duplication detection unit 117, the correction range gain / offset adjustment unit 112 adjusts the gain or / and the offset so that the elliptical sphere for the memory color correction target with a low priority is reduced. Here, the correction range gain / offset adjustment unit 112 adjusts the gain or / and the offset according to the size of the overlapping range. Then, the correction range gain / offset adjustment unit 112 supplies the correction range for each RGB calculated after the adjustment to the correction range elliptic sphere type calculation unit 115.

図19の例では、補正範囲ゲイン・オフセット調整部112は、優先順位2の補正範囲(優先順位の低い方の補正範囲)をゲイン及び/またはオフセットの調整により点線で示す補正範囲に変更し、この補正範囲を補正範囲楕円球式算出部115に供給する。   In the example of FIG. 19, the correction range gain / offset adjustment unit 112 changes the correction range of the priority order 2 (the correction range of the lower priority order) to the correction range indicated by the dotted line by adjusting the gain and / or offset, This correction range is supplied to the correction range elliptic sphere type calculation unit 115.

なお、重複がある場合、優先順位の低い記憶色補正対象に関しての記憶色補正を行わないことにしてもよい。   When there is an overlap, the memory color correction for the memory color correction target with a low priority may not be performed.

続いて、本実施の形態にかかる画像処理装置の効果について説明する。はじめに、優先順位を考慮しない記憶色補正の課題について説明する。図19に示すように、複数の記憶色補正対象を扱う場合、補正範囲の重複が生じる場合がある。この場合、一方の記憶色補正対象の補正を断念する等の対応を行う必要があった。そのため、意図した記憶色補正効果が得られない場合が生じていた。   Next, effects of the image processing apparatus according to this embodiment will be described. First, a problem of memory color correction that does not consider priority will be described. As shown in FIG. 19, when dealing with a plurality of memory color correction targets, there is a case where overlap of correction ranges occurs. In this case, it is necessary to take measures such as giving up the correction of one of the memory color correction targets. Therefore, the intended memory color correction effect may not be obtained.

一方、本実施の形態にかかる画像処理装置は、記憶色補正対象が複数ある場合に、記憶色補正対象に対して優先順位を設定することができる。そして、本実施の形態にかかる画像処理装置は、優先順位の高い記憶色補正対象に対しては確実に所望の強度の記憶色補正を行うことを担保することができる。さらに、本実施の形態にかかる画像処理装置は、補正範囲に重複がない場合には、優先順位の低い記憶色補正対象に対しても十分な補正強度の記憶色補正を行うことができる。   On the other hand, when there are a plurality of memory color correction targets, the image processing apparatus according to the present embodiment can set a priority order for the memory color correction targets. The image processing apparatus according to the present embodiment can ensure that memory color correction with a desired intensity is reliably performed on a memory color correction target with a high priority. Furthermore, the image processing apparatus according to the present embodiment can perform memory color correction with sufficient correction strength even for a memory color correction target with a low priority when there is no overlap in the correction range.

さらに、補正範囲に重複がある場合、補正範囲ゲイン・オフセット調整部112は、重複が無くなる程度にゲイン及び/またはオフセットを調整する。そのため、本実施の形態にかかる画像処理装置は、補正範囲に重複がある場合であっても、優先順位の低い記憶色補正対象に対して一定の記憶色補正を行うことができる。
Furthermore, when there is an overlap in the correction range, the correction range gain / offset adjustment unit 112 adjusts the gain and / or offset to the extent that there is no overlap. Therefore, the image processing apparatus according to the present embodiment can perform a fixed memory color correction on a memory color correction target with a low priority even when there is an overlap in the correction range.

すなわち、本実施の形態にかかる画像処理装置によれば、同一(近似)色領域に属する複数の記憶色補正対象に対して、ユーザの意図通りに記憶色補正を実行することができる。 That is, according to the image processing apparatus according to the present embodiment, it is possible to perform memory color correction as intended by the user on a plurality of memory color correction targets belonging to the same (approximate) color region.

さらに、実施の形態3にかかる構成と、実施の形態4にかかる構成とを、組み合わせることも可能である。すなわち、画像処理装置1は、テーブルデータ制限数以下のテーブルデータ数となるように、優先順位に応じて補正範囲を狭くするように調整しても良い。この場合、補正範囲に重複がない場合であっても補正範囲の縮小を行う。当該概念について以下に説明を行う。 Furthermore, the configuration according to the third embodiment and the configuration according to the fourth embodiment can be combined. That is, the image processing apparatus 1 may adjust the correction range to be narrowed according to the priority order so that the number of table data is equal to or less than the table data limit number. In this case, the correction range is reduced even when there is no overlap in the correction range. The concept will be described below.

はじめに、補正範囲算出部110は、テーブルデータ制限数を考慮することなく、各記憶色補正対象に対する補正範囲(楕円球式)を算出する。この場合、フレーム毎に設定すべきテーブルデータ数がテーブルデータ制限数を超える(システムの能力を超える)ことが予想される。しかしながら、ユーザが各記憶色補正対象の優先順位を定めていた場合には、画像処理装置1は、テーブルデータ制限数以下となるように、優先順位が低くなるほど記補正範囲の縮小率が高くなるように各補正範囲を調整する。 First, the correction range calculation unit 110 calculates a correction range (elliptical sphere) for each memory color correction target without considering the table data limit number. In this case, it is expected that the number of table data to be set for each frame exceeds the limit number of table data (exceeds system capacity). However, when the user has determined the priority order of each memory color correction target, the image processing apparatus 1 increases the reduction ratio of the correction range as the priority order decreases so that the table data limit number or less. Adjust each correction range as follows.

図20を参照して、動作概念を説明する。図20の例では、3つの記憶色補正対象が設定されている。図20(A)では、優先順位1の記憶色補正対象がフレーム内に存在していない。そのため、補正範囲算出部110は、優先順位2の記憶色補正対象の補正範囲と、優先順位3の記憶色補正対象の補正範囲と、の縮小を大幅にすることなく補正範囲を調整している。 The operation concept will be described with reference to FIG. In the example of FIG. 20, three memory color correction targets are set. In FIG. 20A, the memory color correction target of priority 1 does not exist in the frame. For this reason, the correction range calculation unit 110 adjusts the correction range without greatly reducing the correction range of the memory color correction target of priority 2 and the correction range of the memory color correction target of priority 3. .

一方、図20(B)では、優先順位1の記憶色補正対象がフレーム内に存在する。そのため、補正範囲算出部110は、優先順位2の記憶色補正対象の補正範囲と、優先順位3の記憶色補正対象の補正範囲と、を大幅に縮小している。一方、補正範囲算出部110は、優先順位1の記憶色補正対象の補正範囲の縮小を最小限としている。 On the other hand, in FIG. 20B, the memory color correction target with priority 1 exists in the frame. For this reason, the correction range calculation unit 110 significantly reduces the correction range of the memory color correction target of priority 2 and the correction range of the memory color correction target of priority 3. On the other hand, the correction range calculation unit 110 minimizes the reduction of the correction range of the priority 1 memory color correction target.

なお、優先順位に応じた縮小率の具体的な数値は、ユーザが適宜指定することが可能である。 Note that a specific numerical value of the reduction rate according to the priority order can be appropriately specified by the user.

このように、優先順位とテーブルデータ制限数を共に考慮することにより、画像処理装置1は、テーブルデータを所望の数まで制限しつつ、記憶色補正を行いたい記憶色補正対象の補正強度を十分に確保することができる。 As described above, by considering both the priority order and the table data limit number, the image processing apparatus 1 sufficiently sets the correction intensity of the memory color correction target to be subjected to memory color correction while limiting the table data to a desired number. Can be secured.

<実施の形態5>
本実施の形態にかかる画像処理装置は、複数の3次元ルックアップテーブルを保持できることを特徴とする。本実施の形態にかかる画像処理装置は、実施の形態2にかかる画像処理装置の変形であるため、実施の形態2にかかる画像処理装置との差異を中心に説明する。
<Embodiment 5>
The image processing apparatus according to the present embodiment is characterized in that it can hold a plurality of three-dimensional lookup tables. Since the image processing apparatus according to the present embodiment is a modification of the image processing apparatus according to the second embodiment, differences from the image processing apparatus according to the second embodiment will be mainly described.

図21は、本実施の形態にかかる画像処理装置1の構成を示すブロック図である。画像処理装置1は、図1の構成に加え、複数の3次元ルックアップテーブル部200〜202、及びセレクタ400を備える。   FIG. 21 is a block diagram showing a configuration of the image processing apparatus 1 according to the present embodiment. The image processing apparatus 1 includes a plurality of three-dimensional lookup table units 200 to 202 and a selector 400 in addition to the configuration of FIG.

記憶色補正対象検出部301は、記憶色補正対象の検出を行うとともに、各記憶色補正対象が画像内のどの領域に存在しているか、各記憶色補正対象の画像内での表示領域を検出する。図22を参照して、記憶色補正対象検出部301の処理について説明する。   The memory color correction target detection unit 301 detects the memory color correction target and detects in which area in the image each memory color correction target exists, and the display area in each memory color correction target image. To do. With reference to FIG. 22, the process of the memory color correction target detection unit 301 will be described.

以下の例では、記憶色補正対象検出部301は、記憶色補正対象として「青空」、「青い花」、「人の肌」の3つを検出する。また、ユーザは、「青空」、「青い花」を記憶色補正対象として設定している。図22は、補正処理を行う画像の例を示す図である。図示するように画像の上部に青空が存在し、画面左下部に青い花が存在する。ユーザは、「青空」、「青い花」について色空間における移動元座標(RGB値)と移動先座標(RGB値)を設定する。記憶色補正対象検出部301は、画像内の各画素についてどの記憶色補正対象が存在するかをセレクタ400に通知する。例えば、記憶色補正対象検出部301は、図22の画素1(X1,Y1)には青空が存在することを通知する。同様に、記憶色補正対象検出部301は、図22の画素2(X2,Y2)には青い花が存在することを通知する。なお、記憶色補正対象検出部301は、処理対象の画素に記憶色補正対象が存在しない場合、その旨を通知する。   In the following example, the memory color correction target detection unit 301 detects three “blue sky”, “blue flower”, and “human skin” as memory color correction targets. In addition, the user sets “blue sky” and “blue flower” as memory color correction targets. FIG. 22 is a diagram illustrating an example of an image on which correction processing is performed. As shown in the figure, there is a blue sky at the top of the image and a blue flower at the bottom left of the screen. The user sets a movement source coordinate (RGB value) and a movement destination coordinate (RGB value) in the color space for “blue sky” and “blue flower”. The memory color correction target detection unit 301 notifies the selector 400 which memory color correction target exists for each pixel in the image. For example, the memory color correction target detection unit 301 notifies that a blue sky exists in the pixel 1 (X1, Y1) in FIG. Similarly, the memory color correction target detection unit 301 notifies that a blue flower exists in the pixel 2 (X2, Y2) in FIG. Note that the memory color correction target detection unit 301 notifies the processing target pixel when there is no memory color correction target.

補正範囲算出部110は、実施の形態1と同様の手法で各記憶色補正対象の補正範囲を算出する。図23は、青空の補正範囲と、青い花の補正範囲を示す図である。ここで、青空の補正範囲と青い花の補正範囲との重複範囲D1が存在する。   The correction range calculation unit 110 calculates the correction range of each memory color correction target using the same method as in the first embodiment. FIG. 23 is a diagram illustrating a blue sky correction range and a blue flower correction range. Here, there is an overlapping range D1 between the blue sky correction range and the blue flower correction range.

格子点移動量算出部120は、入力された記憶色補正対象毎に、各格子点の移動量を算出する。図23の例では、格子点移動量算出部120は、青空の補正範囲内に含まれる各格子点の変換先座標を算出し、かつ、青い花の補正範囲内に含まれる各格子点の変換先座標を算出する。そのため、補正範囲移動量算出部120は、青空の補正範囲内に含まれる格子点として座標P1を扱う場合には変換座標としてP2を算出し、青い花の補正範囲内に含まれる格子点として座標P1を扱う場合には変換座標としてP3を算出する。   The grid point movement amount calculation unit 120 calculates the movement amount of each grid point for each input memory color correction target. In the example of FIG. 23, the lattice point movement amount calculation unit 120 calculates the conversion destination coordinates of each lattice point included in the blue sky correction range, and converts each lattice point included in the blue flower correction range. Calculate the destination coordinates. Therefore, the correction range movement amount calculation unit 120 calculates P2 as conversion coordinates when the coordinate P1 is handled as a grid point included in the blue sky correction range, and coordinates as a grid point included in the blue flower correction range. When P1 is handled, P3 is calculated as converted coordinates.

格子点移動量算出部120は、記憶色補正対象毎に各格子点の変換座標を算出する。そして、格子点移動量算出部120は、記憶色補正対象毎に3次元ルックアップテーブルを設定する。以下の例では、格子点移動量算出部120は、3次元ルックアップテーブル部200に青空の記憶色補正に関するテーブルデータを設定し、3次元ルックアップテーブル部201に青い花の記憶色補正に関するテーブルデータを設定し、3次元ルックアップテーブル部202に他の色補正用のテーブルデータを設定する。   The grid point movement amount calculation unit 120 calculates conversion coordinates of each grid point for each memory color correction target. Then, the lattice point movement amount calculation unit 120 sets a three-dimensional lookup table for each memory color correction target. In the following example, the grid point movement amount calculation unit 120 sets table data relating to blue sky memory color correction in the three-dimensional lookup table unit 200, and a table relating to blue flower memory color correction in the three-dimensional lookup table unit 201. Data is set, and other table data for color correction is set in the three-dimensional lookup table unit 202.

各ルックアップテーブル部(200〜202)は、設定されたルックアップテーブルに従って各画素の色空間上での補正を行う。各ルックアップテーブル部(200〜202)は、補正により得られた各画素のRGB値をセレクタ400に出力する。   Each look-up table unit (200 to 202) corrects each pixel in the color space according to the set look-up table. Each lookup table unit (200 to 202) outputs the RGB value of each pixel obtained by the correction to the selector 400.

前述のように、セレクタ400には、各記憶色補正対象の存在座標が記憶色補正対象検出部301から通知される。セレクタ400は、画素位置と各記憶色補正対象の存在座標との関係に応じて、ルックアップテーブル部(200〜202)から出力されるRGB値の一つを選択して出力する。例えば、図22の画素1の補正を行っている場合、セレクタ400は、ルックアップテーブル部200(青空の記憶色補正のテーブルデータが設定されている処理部)からの出力を選択して出力する。同様に、図22の画素2の補正を行っている場合、セレクタ400は、ルックアップテーブル部201(青い花の記憶色補正のテーブルデータが設定されている処理部)からの出力を選択して出力する。   As described above, the selector 400 is notified from the memory color correction target detection unit 301 of the coordinates of each memory color correction target. The selector 400 selects and outputs one of the RGB values output from the look-up table unit (200 to 202) according to the relationship between the pixel position and the coordinates of each memory color correction target. For example, when the pixel 1 in FIG. 22 is being corrected, the selector 400 selects and outputs an output from the lookup table unit 200 (a processing unit in which blue sky memory color correction table data is set). . Similarly, when the correction of the pixel 2 in FIG. 22 is performed, the selector 400 selects the output from the lookup table unit 201 (the processing unit in which the blue flower memory color correction table data is set). Output.

続いて本実施の形態にかかる画像処理装置の効果について説明する。上述したように、本実施の形態にかかる画像処理装置1は、記憶色補正対象毎にルックアップテーブルを設ける。画像処理装置1は、画像内の各記憶色補正対象の存在位置に応じて、複数のルックアップテーブルの変換結果から適切な値を選択する。これにより、図23に示すように、色空間における補正範囲に重複がある場合であっても、画像処理装置1は、補正範囲の重複の影響を受けることなく適切に記憶色補正を行うことができる。   Next, effects of the image processing apparatus according to this embodiment will be described. As described above, the image processing apparatus 1 according to the present embodiment provides a lookup table for each memory color correction target. The image processing apparatus 1 selects an appropriate value from the conversion results of a plurality of lookup tables in accordance with the position where each memory color correction target exists in the image. As a result, as shown in FIG. 23, even when there is an overlap in the correction range in the color space, the image processing apparatus 1 can appropriately perform the memory color correction without being affected by the overlap in the correction range. it can.

なお、上述の説明では、画像処理装置1が記憶色補正対象毎にルックアップテーブルを備える構成を説明したが、必ずしもこれに限られない。画像処理装置1は、補正範囲に重複がある場合にのみ別のルックアップテーブルにテーブルデータを格納すればよい。例えば、青空の補正範囲と青い花の補正範囲は重複するが、青空の補正範囲と桜の花の補正範囲は重複しない場合を考える。この場合、第1のルックアップテーブルに青空の補正範囲にかかるテーブルデータに加え、桜の花の補正範囲にかかるテーブルデータを格納する。そして、第2のルックアップテーブルに青い花の補正範囲にかかるテーブルデータを格納する。これにより、ルックアップテーブルの数の増加を最小限に抑えつつ、補正範囲の重複の影響を受けない記憶色補正処理を実現することができる。   In the above description, the configuration in which the image processing apparatus 1 includes the lookup table for each memory color correction target has been described, but the configuration is not necessarily limited thereto. The image processing apparatus 1 may store the table data in another lookup table only when there is an overlap in the correction range. For example, consider a case where the blue sky correction range and the blue flower correction range overlap, but the blue sky correction range and the cherry blossom correction range do not overlap. In this case, in addition to the table data relating to the blue sky correction range, the table data relating to the cherry blossom correction range is stored in the first lookup table. And the table data concerning the correction range of the blue flower is stored in the second lookup table. As a result, it is possible to realize a memory color correction process that is not affected by overlapping correction ranges while minimizing an increase in the number of lookup tables.

<実施の形態6>
本実施の形態にかかる画像処理装置は、RGB以外の画像信号を扱うことができることを特徴とする。本実施の形態にかかる画像処理装置では、ユーザは、記憶色補正対象の移動元座標と当該座標からの移動量を設定することができる。本実施の形態に画像処理装置について、実施の形態1と異なる点を中心に説明する。
<Embodiment 6>
The image processing apparatus according to the present embodiment is characterized in that it can handle image signals other than RGB. In the image processing apparatus according to the present embodiment, the user can set the movement source coordinates of the memory color correction target and the movement amount from the coordinates. The image processing apparatus according to the present embodiment will be described focusing on differences from the first embodiment.

本実施の形態にかかる画像処理装置1は、テーブルデータ生成部100(または絵柄適応部300)の前段に色空間変換部500を有することを特徴とする。図24は、色空間変換部500の構成を示すブロック図である。色空間変換部500は、RGB/HSV変換部510と、加算器520と、HSV/RGB変換部530と、を備える。   The image processing apparatus 1 according to the present embodiment includes a color space conversion unit 500 in front of the table data generation unit 100 (or the pattern adaptation unit 300). FIG. 24 is a block diagram illustrating a configuration of the color space conversion unit 500. The color space conversion unit 500 includes an RGB / HSV conversion unit 510, an adder 520, and an HSV / RGB conversion unit 530.

ユーザは、移動元座標O (Ro, Go, Bo)、及び当該移動元座標からの変化量を指定する。ここで、変化量は、例えば色相(H)、彩度(S)、輝度(V)の各項目について指定する。   The user designates the movement source coordinates O (Ro, Go, Bo) and the amount of change from the movement source coordinates. Here, the amount of change is specified for each item of hue (H), saturation (S), and luminance (V), for example.

RGB/HSV変換部510は、ユーザが指定した移動元座標をRGB値からHSV値に変換する。当該変換は、既知の手法により行えばよい。RGB/HSV変換部510は、変換したHSV値(Ho,So,Vo)を加算器520に出力する。   The RGB / HSV conversion unit 510 converts the movement source coordinates designated by the user from RGB values to HSV values. The conversion may be performed by a known method. The RGB / HSV conversion unit 510 outputs the converted HSV value (Ho, So, Vo) to the adder 520.

加算器520は、入力されたHSV値(Ho,So,Vo)に、色相(H)、彩度(S)、輝度(V)の各項目の変化量(ΔH,ΔS,ΔV)を加算する。加算器520は、加算値(Ht,St,Vt)をHSV/RGB変換部530に出力する。   The adder 520 adds the amount of change (ΔH, ΔS, ΔV) of each item of hue (H), saturation (S), and luminance (V) to the input HSV value (Ho, So, Vo). . The adder 520 outputs the added value (Ht, St, Vt) to the HSV / RGB conversion unit 530.

HSV/RGB変換部530は、入力された加算値であるHSV値(Ht,St,Vt)をRGB値に変換する。このRGB値は、移動先座標T (Rt, Gt, Bt)を示す。HSV/RGB変換部530は、移動先座標Tをテーブルデータ生成部100に供給する。なお、テーブルデータ生成部100には、ユーザが指定したRGB形式の移動元座標も供給される。   The HSV / RGB conversion unit 530 converts an input HSV value (Ht, St, Vt), which is an added value, into an RGB value. This RGB value indicates the destination coordinate T (Rt, Gt, Bt). The HSV / RGB conversion unit 530 supplies the movement destination coordinate T to the table data generation unit 100. The table data generation unit 100 is also supplied with the source coordinates in RGB format specified by the user.

以上の処理により、テーブルデータ生成部100には、移動元座標O及び移動先座標Tが設定される。以降の各処理は、実施の形態1と同様である。   Through the above processing, the movement source coordinate O and the movement destination coordinate T are set in the table data generation unit 100. The subsequent processes are the same as those in the first embodiment.

続いて、本実施の形態にかかる画像処理装置1の効果について説明する。記憶色補正を行いたい場合であっても、目標とする色座標が定まっていない場合がある。本実施の形態では、ユーザは、移動先座標にかわり移動元座標からの変化量を指定することができる。そのため、ユーザは、例えば「ちょっと黄色く」、「もっと色を濃く」、「かなり明るく」のようにあいまいな指定を行い、当該指定を変化量に換算することが可能となる。これにより、ユーザの設定の負担がさらに軽減する。   Next, effects of the image processing apparatus 1 according to the present embodiment will be described. Even when it is desired to perform memory color correction, the target color coordinates may not be determined. In the present embodiment, the user can specify the amount of change from the source coordinate instead of the destination coordinate. For this reason, the user can make ambiguous designations such as “slightly yellow”, “more darker”, and “pretty bright”, and convert the designation into a change amount. This further reduces the user's setting burden.

なお、上述の例では、HSVとRGBの変換を行う構成として説明したが、必ずしもこれに限られない。例えば、ユーザは、移動元座標と変化量をRGB形式で入力する。そして、加算器が加算処理により移動先座標を算出する構成であっても良い。   In the above-described example, the configuration is described in which HSV and RGB conversion is performed, but the configuration is not necessarily limited thereto. For example, the user inputs the movement source coordinates and the change amount in the RGB format. And the structure which an adder calculates a movement destination coordinate by an addition process may be sufficient.

なお、図24の例では、HSV値とRGB値の変換について説明したが必ずしもこれに限られず、HSU値、YUV値、HLS値、Lab値、YCM値等とRGB値との変換を行っても良い。   In the example of FIG. 24, the conversion between the HSV value and the RGB value has been described. However, the present invention is not necessarily limited to this. good.

以上、本発明にかかる画像処理装置について実施の形態に沿って説明した。しかしながら、本発明は上記実施の形態に限られたものではなく、趣旨を逸脱しない範囲で適宜変更することが可能である。上述の実施の形態では、色空間としてRGB空間を前提として座標変換処理を行ったが、本発明は他の色空間に応用することも可能である。すなわち、画像処理装置は、HSV、HSU、YUV、HLS、Lab、YCM等の色空間において上述の各処理を行っても良い。   The image processing apparatus according to the present invention has been described above according to the embodiment. However, the present invention is not limited to the above-described embodiment, and can be changed as appropriate without departing from the spirit of the present invention. In the above-described embodiment, coordinate conversion processing is performed on the premise of the RGB space as the color space, but the present invention can also be applied to other color spaces. That is, the image processing apparatus may perform the above-described processes in a color space such as HSV, HSU, YUV, HLS, Lab, or YCM.

上述の画像処理装置1は、例えばプリンタ装置、テレビ受像機、複写機、デジタル複合機、プロジェクタ装置、携帯電話端末、デジタルスチルカメラ、スマートフォン、デジタルフォトフレーム、ディスプレイ装置等に組み込まれて使用される。すなわち、画像処理装置1は、表示部に画像を表示する装置、表示部を有する装置に接続可能な装置、画像を印刷または表示する装置において利用される。   The above-described image processing apparatus 1 is used by being incorporated in, for example, a printer device, a television receiver, a copier, a digital multifunction peripheral, a projector device, a mobile phone terminal, a digital still camera, a smartphone, a digital photo frame, a display device, or the like. . That is, the image processing apparatus 1 is used in a device that displays an image on a display unit, a device that can be connected to a device that includes a display unit, and a device that prints or displays an image.

画像処理装置1内の各処理部(テーブルデータ生成部100、3次元ルックアップテーブル部200、絵柄適応部300、セレクタ400、色空間変換部500)の処理の一部又は全部は、回路によるハードウェア構成とすることができる。さらに、画像処理装置1内の各処理部(テーブルデータ生成部100、3次元ルックアップテーブル部200、絵柄適応部300、セレクタ400、色空間変換部500)の処理の一部又は全部は、任意のコンピュータ内で動作するプログラムとして実現してもよい。プログラムは、様々なタイプの非一時的なコンピュータ可読媒体(non-transitory computer readable medium)を用いて格納され、コンピュータに供給することができる。非一時的なコンピュータ可読媒体は、様々なタイプの実体のある記録媒体(tangible storage medium)を含む。非一時的なコンピュータ可読媒体の例は、磁気記録媒体(例えばフレキシブルディスク、磁気テープ、ハードディスクドライブ)、光磁気記録媒体(例えば光磁気ディスク)、CD−ROM(Read Only Memory)、CD−R、CD−R/W、半導体メモリ(例えば、マスクROM、PROM(Programmable ROM)、EPROM(Erasable PROM)、フラッシュROM、RAM(random access memory))を含む。また、プログラムは、様々なタイプの一時的なコンピュータ可読媒体(transitory computer readable medium)によってコンピュータに供給されてもよい。一時的なコンピュータ可読媒体の例は、電気信号、光信号、及び電磁波を含む。一時的なコンピュータ可読媒体は、電線及び光ファイバ等の有線通信路、又は無線通信路を介して、プログラムをコンピュータに供給できる。 Part or all of the processing of each processing unit (table data generation unit 100, three-dimensional lookup table unit 200, picture adaptation unit 300, selector 400, color space conversion unit 500) in the image processing apparatus 1 is implemented by a hardware circuit. Hardware configuration. Furthermore, a part or all of the processing of each processing unit (table data generation unit 100, three-dimensional lookup table unit 200, picture adaptation unit 300, selector 400, color space conversion unit 500) in the image processing apparatus 1 is arbitrary. You may implement | achieve as a program which operate | moves in this computer. The program may be stored using various types of non-transitory computer readable media and supplied to a computer. Non-transitory computer readable media include various types of tangible storage media. Examples of non-transitory computer-readable media include magnetic recording media (for example, flexible disks, magnetic tapes, hard disk drives), magneto-optical recording media (for example, magneto-optical disks), CD-ROMs (Read Only Memory), CD-Rs, CD-R / W and semiconductor memory (for example, mask ROM, PROM (Programmable ROM), EPROM (Erasable PROM), flash ROM, RAM (random access memory)) are included. The program may also be supplied to the computer by various types of transitory computer readable media. Examples of transitory computer readable media include electrical signals, optical signals, and electromagnetic waves. The temporary computer-readable medium can supply the program to the computer via a wired communication path such as an electric wire and an optical fiber, or a wireless communication path.

画像処理装置1の各処理部の処理をプログラムとして実行するコンピュータのハードウェア構成の一例を図25に示す。当該コンピュータは、中央処理装置(CPU, Central Processing Unit)600と、メモリ610と、を含んでいる。CPU600及びメモリ610は、バスを介して補助記憶装置としてのハードディスク装置(HDD)620に接続される。ハードディスク装置620等の記憶媒体にはオペレーティングシステムと協働してCPU600等に命令を与え、上述した画像処理装置1の各処理を実施するためのコンピュータ・プログラムを記憶することができる。 FIG. 25 shows an example of the hardware configuration of a computer that executes the processing of each processing unit of the image processing apparatus 1 as a program. The computer includes a central processing unit (CPU) 600 and a memory 610. The CPU 600 and the memory 610 are connected to a hard disk device (HDD) 620 as an auxiliary storage device via a bus. A storage medium such as the hard disk device 620 can store a computer program for giving an instruction to the CPU 600 or the like in cooperation with the operating system and performing each process of the image processing apparatus 1 described above.

1 画像処理装置
100 テーブルデータ生成部
110 補正範囲算出部
111 移動先−移動元距離算出部
112 補正範囲ゲイン・オフセット調整部
113 移動先−移動元直線傾き算出部
114 回転角度算出部
115 補正範囲楕円球式算出部
116 変換座標数制限部
117 補正範囲重複検出部
120 格子点移動量算出部
121 移動元−格子点直線式算出部
122 交点算出部
123 移動元−交点距離算出部
124 移動元−格子点距離算出部
125 影響度算出部
126 移動特性設定部
127 座標算出部
200 3次元ルックアップテーブル部
210 アドレス生成部
220 テーブルデータメモリ部
230 補間部
300 絵柄適応部
301 オブジェクト・背景検出部
302 記憶色補正決定部
303 3次元ヒストグラム生成部
304 ヒストグラム解析部
305 移動元・移動先算出部
400 セレクタ
500 色空間変換部
510 RGB/HSV変換部
520 加算器
530 HSV/RGB変換部
600 CPU
610 メモリ
620 HDD
DESCRIPTION OF SYMBOLS 1 Image processing apparatus 100 Table data generation part 110 Correction range calculation part 111 Destination-movement origin distance calculation part 112 Correction range gain / offset adjustment part 113 Destination-movement source linear inclination calculation part 114 Rotation angle calculation part 115 Correction range ellipse Spherical calculation unit 116 Conversion coordinate number limiting unit 117 Correction range overlap detection unit 120 Lattice point movement amount calculation unit 121 Movement source-grid point linear equation calculation unit 122 Intersection calculation unit 123 Movement source-intersection distance calculation unit 124 Movement source-grid Point distance calculation unit 125 Influence degree calculation unit 126 Movement characteristic setting unit 127 Coordinate calculation unit 200 Three-dimensional lookup table unit 210 Address generation unit 220 Table data memory unit 230 Interpolation unit 300 Pattern adaptation unit 301 Object / background detection unit 302 Memory color Correction determining unit 303 Three-dimensional histogram generating unit 304 Decoder 305 move source-destination calculator 400 selector 500 color space conversion unit 510 RGB / HSV converter 520 adder 530 HSV / RGB conversion section 600 CPU
610 Memory 620 HDD

Claims (22)

入力された画像信号の色情報を変換規則に基づいて変換する変換部と、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出する補正範囲算出部と、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させる各点移動量算出部と、を備え、
前記補正範囲算出部は、
ユーザからの前記変換規則の規則制限数の入力を受け付け、前記補正範囲の大きさから算出される前記補正範囲内の各点座標の個数と、前記規則制限数を比較し、
前記規則制限数が前記補正範囲内の各点座標の個数よりも少ない場合、領域範囲が小さくなるように前記補正範囲の再算出を行う画像処理装置。
A conversion unit that converts color information of the input image signal based on a conversion rule;
A correction range calculation unit that calculates a correction range in the color space based on the positional relationship between the movement source coordinates and the movement destination coordinates in the preset color space;
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion Each point movement amount calculation unit to be reflected in the rule,
The correction range calculation unit
Accepting an input of the rule limit number of the conversion rule from the user, comparing the number of each point coordinate in the correction range calculated from the size of the correction range, and the rule limit number,
An image processing apparatus that recalculates the correction range so that the region range becomes smaller when the rule restriction number is smaller than the number of each point coordinate in the correction range.
前記各点移動量算出部は、前記移動元座標からの距離が大きくなるにつれて各点の移動量を小さくすることを特徴とする請求項1に記載の画像処理装置。 The image processing apparatus according to claim 1, wherein the point movement amount calculation unit reduces the movement amount of each point as the distance from the movement source coordinate increases. 前記補正範囲は、前記移動元座標と前記移動先座標を結ぶ第1直線が長軸方向となる楕円球体であることを特徴とする請求項1または請求項2に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the correction range is an ellipsoidal sphere in which a first straight line connecting the movement source coordinates and the movement destination coordinates is a major axis direction. 前記補正範囲算出部は、
前記移動元座標と、前記移動先座標と、の距離を算出する第1距離算出部と、
前記第1直線の傾きを算出する直線傾き算出部と、
予め設定された調整値と、前記第1距離算出部が算出した距離と、に基づいて、座標範囲を算出する補正範囲調整部と、
前記直線傾き算出部が算出した前記第1直線の傾きに基づいて、前記座標範囲を回転させる回転角度を算出する回転角度算出部と、
前記補正範囲調整部が算出した前記座標範囲を前記回転角度だけ回転させることにより前記楕円球体の数式を算出する補正範囲楕円球式算出部と、を備えることを特徴とする請求項3に記載の画像処理装置。
The correction range calculation unit
A first distance calculation unit for calculating a distance between the movement source coordinates and the movement destination coordinates;
A straight line inclination calculating unit for calculating the inclination of the first straight line;
A correction range adjustment unit that calculates a coordinate range based on the preset adjustment value and the distance calculated by the first distance calculation unit;
A rotation angle calculation unit for calculating a rotation angle for rotating the coordinate range based on the inclination of the first straight line calculated by the linear inclination calculation unit;
The correction range elliptic sphere type calculation part which calculates the mathematical expression of the ellipsoidal sphere by rotating the coordinate range calculated by the correction range adjustment part by the rotation angle. Image processing device.
前記直線傾き算出部は、前記色空間の前記移動元座標をO(Ro, Go, Bo)、前記移動先座標をT(Rt, Gt, Bt)とした場合、前記色空間における前記第1直線の第1断面の傾きΔ1、第2断面の傾きΔ2を以下の式(数36)、(数37)により算出することを特徴とする請求項4に記載の画像処理装置。
Figure 2016054491
Figure 2016054491
The straight line inclination calculating unit, when the movement source coordinate of the color space is O (Ro, Go, Bo) and the movement destination coordinate is T (Rt, Gt, Bt), the first straight line in the color space. 5. The image processing apparatus according to claim 4, wherein the inclination Δ1 of the first cross section and the inclination Δ2 of the second cross section are calculated by the following equations (Equation 36) and (Equation 37).
Figure 2016054491
Figure 2016054491
前記回転角度算出部は、前記色空間における前記第1断面での前記回転角度をθ1、前記第1断面での前記回転角度θ2を以下の式(数38)、(数39)により算出することを特徴とする請求項5に記載の画像処理装置。
Figure 2016054491
Figure 2016054491
The rotation angle calculation unit calculates the rotation angle at the first cross section in the color space by θ1, and the rotation angle θ2 at the first cross section by the following equations (Equation 38) and (Equation 39). The image processing apparatus according to claim 5.
Figure 2016054491
Figure 2016054491
前記各点移動量算出部は、
前記補正範囲に含まれる第1座標点と、前記移動元座標と、を結ぶ第2直線の直線式を算出する直線式算出部と、
前記楕円球体の数式と、前記第2直線の直線式と、に基づいて、前記楕円球体と前記第2直線の交点を算出する交点算出部と、
前記移動元座標と、前記交点と、の距離を算出する第2距離算出部と、
前記第1座標点と、前記移動元座標と、の距離を算出する第3距離算出部と、
前記第2距離算出部の算出した距離と、前記第3距離算出部の算出した距離と、の比率に応じて前記第1座標点の移動量の基準となる影響度を算出する影響度算出部と、
前記影響度に基づいて、前記第1座標点の変換先座標を算出する座標算出部と、を備えることを特徴とする請求項3乃至請求項6のいずれか1項に記載の画像処理装置。
Each point movement amount calculation unit
A linear equation calculation unit for calculating a linear equation of a second straight line connecting the first coordinate point included in the correction range and the movement source coordinate;
An intersection calculation unit that calculates an intersection of the elliptic sphere and the second straight line based on the mathematical expression of the elliptic sphere and the linear equation of the second straight line;
A second distance calculation unit for calculating a distance between the movement source coordinates and the intersection;
A third distance calculating unit for calculating a distance between the first coordinate point and the movement source coordinate;
An influence degree calculating section that calculates an influence degree that serves as a reference for the amount of movement of the first coordinate point according to a ratio between the distance calculated by the second distance calculating section and the distance calculated by the third distance calculating section. When,
The image processing apparatus according to claim 3, further comprising: a coordinate calculation unit that calculates a conversion destination coordinate of the first coordinate point based on the degree of influence.
前記座標算出部は、ユーザが指定した補正方向(圧縮方向または平行方向)に応じて、前記第1座標点の変換先座標を算出することを特徴とする請求項7に記載の画像処理装置。   The image processing apparatus according to claim 7, wherein the coordinate calculation unit calculates a conversion destination coordinate of the first coordinate point according to a correction direction (compression direction or parallel direction) designated by a user. 前記各点移動量算出部は、
前記影響度を、リニアな変化よりも増加させるように調整した移動特性を算出し、前記移動特性を前記座標算出部が前記第1座標点の変換先座標を算出する際のパラメータとして設定する移動特性調整部を備えることを特徴とする請求項7または請求項8に記載の画像処理装置。
Each point movement amount calculation unit
A movement characteristic that is adjusted so that the degree of influence is increased more than a linear change is calculated, and the movement characteristic is set as a parameter when the coordinate calculation unit calculates a conversion destination coordinate of the first coordinate point. The image processing apparatus according to claim 7, further comprising a characteristic adjustment unit.
前記各点移動量算出部の処理する前記補正範囲内の各点の座標は、隣接点との距離が全て等しい格子点座標であることを特徴とする請求項1乃至請求項9のいずれか1項に記載の画像処理装置。   The coordinate of each point within the correction range processed by each point movement amount calculation unit is a grid point coordinate whose distances from adjacent points are all equal. The image processing apparatus according to item. 前記移動元座標及び前記移動先座標は、ユーザが指定した入力値であることを特徴とする請求項1乃至請求項10のいずれか1項に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the movement source coordinates and the movement destination coordinates are input values designated by a user. 記憶色補正対象の種別、補正を行いたい各記憶色補正対象にかかる前記移動元座標の第1プリセット値、前記移動先座標の第2プリセット値をユーザから受け付け、
前記画像信号が構成する画像内にユーザが指定した前記記憶色補正対象が存在するか否かを判定するとともに、前記画像の色分布を解析し、
前記画像内に存在する前記補正対象毎の前記第1プリセット値、及び前記第2プリセット値の少なくとも一方を、前記画像の色分布の解析結果に基づいて調整し、調整値を前記記憶色補正対象毎の前記移動元座標、前記移動先座標に設定する絵柄適応部、を更に備える請求項1乃至請求項11のいずれか1項に記載の画像処理装置。
The type of the memory color correction target, the first preset value of the movement source coordinate and the second preset value of the movement destination coordinate for each memory color correction target to be corrected are received from the user,
Determining whether or not the memory color correction target specified by the user exists in the image constituting the image signal, and analyzing the color distribution of the image;
At least one of the first preset value and the second preset value for each correction target existing in the image is adjusted based on an analysis result of the color distribution of the image, and an adjustment value is stored in the memory color correction target. The image processing apparatus according to claim 1, further comprising a picture adaptation unit that sets the movement source coordinates and the movement destination coordinates for each movement.
前記絵柄適応部は、
前記画像内において記憶色補正の対象となり得るオブジェクトまたは背景の有無、及び前記画像内での記憶色補正対象の検出領域を検出する補正対象検出部と、
前記補正対象検出部の検出結果と、前記ユーザが指定した前記記憶色補正対象の種別と、を比較して処理を行う記憶色補正対象を決定する記憶色補正決定部と、
前記画像の色空間ヒストグラムを生成するヒストグラム生成部と、
前記色空間ヒストグラムに基づいて、前記検出領域内での色分布解析にかかる第1解析結果、及び前記第1プリセット値と前記第2プリセット値の示す色空間座標間の色分布解析にかかる第2解析結果を算出するヒストグラム解析部と、
前記記憶色補正決定部の決定した記憶色補正対象、前記第1及び前記第2解析結果、前記第1及び前記第2プリセット値、に基づいて前記画像内に存在する前記記憶色補正対象毎の前記移動元座標、前記移動先座標を算出する移動元移動先算出部と、
を備えることを特徴とする請求項12に記載の画像処理装置。
The pattern adaptation unit is:
A correction target detection unit that detects the presence or absence of an object or background that can be a target of memory color correction in the image, and a detection region of the memory color correction target in the image;
A memory color correction determination unit that determines a memory color correction target to be processed by comparing the detection result of the correction target detection unit with the type of the memory color correction target specified by the user;
A histogram generator for generating a color space histogram of the image;
Based on the color space histogram, a first analysis result relating to color distribution analysis in the detection region, and a second relating to color distribution analysis between color space coordinates indicated by the first preset value and the second preset value. A histogram analysis unit for calculating an analysis result;
Based on the memory color correction target determined by the memory color correction determination unit, the first and second analysis results, and the first and second preset values, for each memory color correction target existing in the image. A movement source movement destination calculation unit that calculates the movement source coordinates and the movement destination coordinates;
The image processing apparatus according to claim 12, further comprising:
前記ヒストグラム解析部は、
前記検出領域の中心的な色を示す中心色座標を前記第1解析結果とし、
前記第1プリセット値と前記第2プリセット値の示す色空間座標間を複数エリアに分割し、前記第1プリセット値に近いエリアから順に所定画素数以上の画素が存在するか否かを判定し、所定画素数以上存在しているエリアの代表座標である存在座標を前記第2解析結果とする、ことを特徴とする請求項13に記載の画像処理装置。
The histogram analysis unit
The central color coordinate indicating the central color of the detection area is the first analysis result,
The color space coordinates indicated by the first preset value and the second preset value are divided into a plurality of areas, and it is determined whether or not there are pixels having a predetermined number of pixels or more in order from an area close to the first preset value, The image processing apparatus according to claim 13, wherein existence coordinates that are representative coordinates of an area where a predetermined number of pixels or more exist are used as the second analysis result.
前記移動元移動先算出部は、前記中心色座標をOC(OCr, OCg, OCb)、前記存在座標をTE(TEr, TEg, TEb)、前記第1プリセット値をOP(OPr, OPg, ORb)、前記第2プリセット値をTP(TPr, TPg, TRb)、前記移動元座標をO(Ro, Go, Bo)、前記移動先座標をT(Rt, Gt, Bt)、ユーザが調整可能な追従度をF1(0〜100%)、F2(0〜100%)とした場合、以下の式(数40)、(数41)により前記移動元座標、及び前記移動先座標を算出することを特徴とする請求項14に記載の画像処理装置。
Figure 2016054491
Figure 2016054491
The movement source movement destination calculation unit sets the center color coordinates to OC (OCr, OCg, OCb), the existence coordinates to TE (TEr, TEg, TEb), and the first preset value to OP (OPr, OPg, ORb). The second preset value is TP (TPr, TPg, TRb), the movement source coordinates are O (Ro, Go, Bo), the movement destination coordinates are T (Rt, Gt, Bt), and user-adjustable tracking When the degrees are F1 (0 to 100%) and F2 (0 to 100%), the movement source coordinates and the movement destination coordinates are calculated by the following equations (Equation 40) and (Equation 41). The image processing apparatus according to claim 14.
Figure 2016054491
Figure 2016054491
前記補正範囲算出部は、
ユーザからの記憶色補正対象の優先順位の入力を受け付け、各記憶色補正対象にかかる前記補正範囲に重複があるか否かを判定し、
重複がある場合、前記優先順位の低い順序で記憶色補正対象にかかる前記補正範囲の縮小率が大きくなるように、各記憶色補正対象にかかる前記補正範囲を再算出することを特徴とする請求項15に記載の画像処理装置。
The correction range calculation unit
Receiving the priority order of the memory color correction target from the user, determining whether or not there is an overlap in the correction range for each memory color correction target;
When there is an overlap, the correction range for each memory color correction target is recalculated so that the reduction ratio of the correction range for the memory color correction target increases in the order of low priority. Item 15. The image processing apparatus according to Item 15.
前記補正範囲算出部は、
前記移動元座標と前記移動元座標の距離が小さくなるように少なくとも一方の座標を調整した後に前記再算出を行うことを特徴とする請求項16に記載の画像処理装置。
The correction range calculation unit
The image processing apparatus according to claim 16, wherein the recalculation is performed after adjusting at least one of the coordinates so that a distance between the movement source coordinates and the movement source coordinates is small.
前記画像処理装置は、前記変換部として第1変換部及び第2変換部を少なくとも有し、
前記絵柄適応部は、前記ユーザが指定した前記記憶色補正対象である第1記憶色補正対象、第2記憶色補正対象のそれぞれの前記画像内での表示領域を検出し、
前記補正範囲算出部は、前記第1、前記第2記憶色補正対象のそれぞれに対応する前記補正範囲を算出し、
前記各点移動量算出部は、前記第1記憶色補正対象にかかる前記補正範囲内の各点の変換先座標を算出して前記第1変換部の有する前記変換規則に反映し、前記第2記憶色補正対象にかかる前記補正範囲内の各点の変換先座標を算出して前記第2変換部の有する前記変換規則に反映する、ことを特徴とする請求項13乃至請求項17のいずれか1項に記載の画像処理装置。
The image processing apparatus includes at least a first conversion unit and a second conversion unit as the conversion unit,
The pattern adaptation unit detects a display area in each of the first memory color correction target and the second memory color correction target that are the memory color correction targets specified by the user,
The correction range calculation unit calculates the correction range corresponding to each of the first and second memory color correction targets,
Each point movement amount calculation unit calculates a conversion destination coordinate of each point in the correction range related to the first memory color correction target, reflects it in the conversion rule of the first conversion unit, and the second 18. The conversion destination coordinates of each point within the correction range for a memory color correction target are calculated and reflected in the conversion rule of the second conversion unit. The image processing apparatus according to item 1.
前記色空間は、RGB、HSV、HSU、YUV、HLS、Lab、YCMのいずれかであることを特徴とする請求項1乃至請求項18のいずれか1項に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the color space is any one of RGB, HSV, HSU, YUV, HLS, Lab, and YCM. 前記変換規則は、LUT(ルックアップテーブル)であることを特徴とする請求項1乃至請求項19のいずれか1項に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the conversion rule is an LUT (Look Up Table). 入力された画像信号の色情報を変換規則に基づいて変換する画像処理方法であって、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出し、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させ、
前記補正範囲の算出処理において、
ユーザからの前記変換規則の規則制限数の入力を受け付け、前記補正範囲の大きさから算出される前記補正範囲内の各点座標の個数と、前記規則制限数を比較し、
前記規則制限数が前記補正範囲内の各点座標の個数よりも少ない場合、領域範囲が小さくなるように前記補正範囲の再算出を行う画像処理方法。
An image processing method for converting color information of an input image signal based on a conversion rule,
Based on the positional relationship between the movement source coordinates and the movement destination coordinates in the preset color space, a correction range in the color space is calculated,
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion Reflected in the rules,
In the calculation process of the correction range,
Accepting an input of the rule limit number of the conversion rule from the user, comparing the number of each point coordinate in the correction range calculated from the size of the correction range, and the rule limit number,
An image processing method for recalculating the correction range so that the area range becomes smaller when the rule limit number is smaller than the number of each point coordinate in the correction range.
コンピュータに、
入力された画像信号の色情報を変換規則に基づいて変換する処理と、
予め設定される色空間における移動元座標と移動先座標の位置関係に基づいて、色空間における補正範囲を算出する処理と、
前記移動元座標と前記移動先座標の位置関係、及び前記補正範囲内の各点の座標と前記移動元座標との位置関係、に基づいて、当該各点の変換先座標を算出し、前記変換規則に反映させる処理と、を実行させ、
前記補正範囲を算出する処理において、
ユーザからの前記変換規則の規則制限数の入力を受け付け、前記補正範囲の大きさから算出される前記補正範囲内の各点座標の個数と、前記規則制限数を比較し、
前記規則制限数が前記補正範囲内の各点座標の個数よりも少ない場合、領域範囲が小さくなるように前記補正範囲の再算出を行なわせるためのプログラム。
On the computer,
A process of converting the color information of the input image signal based on a conversion rule;
A process of calculating a correction range in the color space based on the positional relationship between the movement source coordinates and the movement destination coordinates in a preset color space;
Based on the positional relationship between the movement source coordinates and the movement destination coordinates, and the positional relationship between the coordinates of each point in the correction range and the movement source coordinates, the conversion destination coordinates of each point are calculated, and the conversion Process to be reflected in the rules,
In the process of calculating the correction range,
Accepting an input of the rule limit number of the conversion rule from the user, comparing the number of each point coordinate in the correction range calculated from the size of the correction range, and the rule limit number,
A program for causing the correction range to be recalculated so that the area range becomes smaller when the rule limit number is smaller than the number of point coordinates in the correction range.
JP2015206155A 2015-10-20 2015-10-20 Image processing apparatus, image processing method, and program Expired - Fee Related JP6039778B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2015206155A JP6039778B2 (en) 2015-10-20 2015-10-20 Image processing apparatus, image processing method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015206155A JP6039778B2 (en) 2015-10-20 2015-10-20 Image processing apparatus, image processing method, and program

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2011250926A Division JP5829107B2 (en) 2011-11-16 2011-11-16 Image processing apparatus, image processing method, and program

Publications (2)

Publication Number Publication Date
JP2016054491A true JP2016054491A (en) 2016-04-14
JP6039778B2 JP6039778B2 (en) 2016-12-07

Family

ID=55745393

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015206155A Expired - Fee Related JP6039778B2 (en) 2015-10-20 2015-10-20 Image processing apparatus, image processing method, and program

Country Status (1)

Country Link
JP (1) JP6039778B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111383054A (en) * 2020-03-10 2020-07-07 中国联合网络通信集团有限公司 Advertisement checking method and device
CN114650453A (en) * 2022-04-02 2022-06-21 北京中庆现代技术股份有限公司 Target tracking method, device, equipment and medium applied to classroom recording and broadcasting

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002223366A (en) * 2001-01-26 2002-08-09 Canon Inc Picture processor, its method and its system
JP2004112694A (en) * 2002-09-20 2004-04-08 Fuji Xerox Co Ltd Color control method, color control apparatus, color conversion definition editing apparatus, image processing apparatus, program, and storage medium
JP2004192614A (en) * 2002-11-29 2004-07-08 Ricoh Co Ltd Image processing device, image processing method, program and recording medium
JP2006033196A (en) * 2004-07-13 2006-02-02 Sharp Corp Color correcting device, image-forming device, color correction method, color correcting program, and computer-readable recording medium
JP2008182633A (en) * 2007-01-26 2008-08-07 Konica Minolta Business Technologies Inc Image processing apparatus
JP2009033361A (en) * 2007-07-25 2009-02-12 Fuji Xerox Co Ltd Color adjustment unit, image-forming device, and program
JP2009124526A (en) * 2007-11-16 2009-06-04 Fuji Xerox Co Ltd Color signal converter, image formation device, adjustment coefficient generator, and program

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002223366A (en) * 2001-01-26 2002-08-09 Canon Inc Picture processor, its method and its system
JP2004112694A (en) * 2002-09-20 2004-04-08 Fuji Xerox Co Ltd Color control method, color control apparatus, color conversion definition editing apparatus, image processing apparatus, program, and storage medium
JP2004192614A (en) * 2002-11-29 2004-07-08 Ricoh Co Ltd Image processing device, image processing method, program and recording medium
JP2006033196A (en) * 2004-07-13 2006-02-02 Sharp Corp Color correcting device, image-forming device, color correction method, color correcting program, and computer-readable recording medium
JP2008182633A (en) * 2007-01-26 2008-08-07 Konica Minolta Business Technologies Inc Image processing apparatus
JP2009033361A (en) * 2007-07-25 2009-02-12 Fuji Xerox Co Ltd Color adjustment unit, image-forming device, and program
JP2009124526A (en) * 2007-11-16 2009-06-04 Fuji Xerox Co Ltd Color signal converter, image formation device, adjustment coefficient generator, and program

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111383054A (en) * 2020-03-10 2020-07-07 中国联合网络通信集团有限公司 Advertisement checking method and device
CN114650453A (en) * 2022-04-02 2022-06-21 北京中庆现代技术股份有限公司 Target tracking method, device, equipment and medium applied to classroom recording and broadcasting
CN114650453B (en) * 2022-04-02 2023-08-15 北京中庆现代技术股份有限公司 Target tracking method, device, equipment and medium applied to classroom recording and broadcasting

Also Published As

Publication number Publication date
JP6039778B2 (en) 2016-12-07

Similar Documents

Publication Publication Date Title
JP5829107B2 (en) Image processing apparatus, image processing method, and program
US9373305B2 (en) Semiconductor device, image processing system and program
JP5539387B2 (en) Skin color enhancement image processing method and system
JP2017059235A (en) Apparatus and method for adjusting brightness of image
JP2009038498A (en) Unit and method for processing image
US10547819B2 (en) Inductive micro-contrast evaluation method
JP6039778B2 (en) Image processing apparatus, image processing method, and program
US8908964B2 (en) Color correction for digital images
JP2010141885A (en) Method and system for color enhancement with color volume adjustment and variable shift along luminance axis
JP3673092B2 (en) Image quality adjusting apparatus, image quality adjusting method, and recording medium recording image adjusting program
JP2007042033A (en) Color correction apparatus and image display device
JP2014192859A (en) Color correction method, program, and device
WO2019137396A1 (en) Image processing method and device
JP2004080100A (en) Method and apparatus for creating color conversion table, method and apparatus for converting colors, and imaging apparatus
JP6403811B2 (en) Image processing apparatus and program
KR102195279B1 (en) Method and system for image registering using regional warping
KR20180117685A (en) High Precision Gamut Mapping
JP5116873B2 (en) Image processing apparatus and image processing method
JP6794835B2 (en) Image processing equipment and programs
JP2016218663A (en) Illumination light color estimation device, illumination light color estimation method, and illumination light color estimation program
JP5029779B2 (en) Image processing method, medium storing image processing program, and image processing apparatus
JP2017016260A (en) Image processing device
JP4941575B2 (en) Image processing method, medium storing image processing program, and image processing apparatus
JP2020178166A (en) Projection control device, projection control method, and program
JP2015035805A (en) Image processing device and method

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20160728

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20160802

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20160930

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20161018

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20161104

R150 Certificate of patent or registration of utility model

Ref document number: 6039778

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees