# Patent

## Title
Image processing apparatus and method of generating color mapping parameters

## Abstract

Parameters for mapping colors from an input system to an output system are determined by displaying a set of adjustment colors in the input system and outputting a reference color pattern in the output system. A human operator selects the reference colors most closely matching the adjustment colors. The mapping parameters are determined from the operator's selections, by table look-up or by use of a mathematical formula, for example. Accurate color mapping parameters can be generated in this way without the need for trial and error.

## Background
BACKGROUND OF THE INVENTION
1. Field of the Invention
The present invention relates to an image processing method and apparatus, and more particularly to a method of selecting color mapping parameters.
2. Description of the Related Art
Conventional color image processing apparatus includes apparatus in which an image displayed by an input system, such as a cathode-ray-tube (CRT) monitor attached to a host computing device, is reproduced by an output system such as an electrophotographic printer or ink-jet printer. Such apparatus typically includes a printer driver, running as software on the host computing device, that can display images on the input system, as well as having images printed by the output system.
In this type of apparatus, the input system displays color images by additive color mixing of three primary colors, normally red, green, and blue (RGB), while the output system prints the same color images by subtractive color mixing of three or four different colors, generally including cyan, magenta, and yellow (CMY) and often also including black (CMYK). One result is that the gamut of colors reproducible by the output system usually differs from the gamut of colors reproducible by input system. When color images are converted from the input system to the output system, the conversion is effected by a mathematical mapping of RGB data to CMY or CMYK data. Ideally, all output colors should exactly match the corresponding input colors, but because of the different gamuts of reproducible colors, this is not in general possible. Moreover, since different printers employ different types of toner or ink, the mapping parameters need to be adjusted individually for each output system in order to obtain at least a reasonably close match between the input and output colors.
The adjustment is often carried out by having the operator of the host computing device enter and adjust the numerical values of the coefficients of the mathematical mapping functions, or the values of what are termed color mapping vectors. It is not easy, however, to intuit the effect of a change in these numerical values on the colors printed by the output system. Even an experienced operator finds adjusting the color mapping parameters by this method a time-consuming process of trial and error, requiring much test printing and comparison of sample images. Accurate matching of colors between the input and output systems by this method is quite difficult.
Japanese Unexamined Patent Application Publication No. H09-217386 discloses an apparatus with slide-bars corresponding to the colors cyan, magenta, yellow, and black. The operator can change the mixing ratios of these colors in a stepwise manner by operating the slide-bars, instead of having to enter numerical parameter values. Manipulating slide-bars may be more intuitive than entering numerical values, but it is still difficult to visualize what the effect of a slide-bar adjustment will be on the output colors, so the operator must still proceed by trial and error, and accurate color matching remains difficult.
SUMMARY OF THE INVENTION
An object of the present invention is to provide an image processing apparatus and method in which accurate matching of colors between an input system and an output system can be easily attained.
The invention provides a method of mapping colors from an input system to an output system by first outputting a reference color pattern in the output system. The reference color pattern includes colors with hues varying in a range targeted around the hue of an adjustment color. An input value related to a hue in the reference color pattern corresponding to the hue of the adjustment color in the input system is obtained, and a hue mapping parameter is determined from the input value. The hue mapping parameter is then used to convert colors from the input system to the output system.
The input value may designate a particular hue in the reference color pattern, in which case the hue mapping parameter may be determined from a table of hue mapping parameter values corresponding to different hues in the reference color pattern.
Alternatively, the input value may designate a hue difference between the hue of the adjustment color and the corresponding hue in the reference color pattern, in which case the hue mapping parameter may be determined from a mathematical formula applied to the input value.
In either case, the input value can be obtained by having a human operator select, from the reference color pattern, a hue most closely matching the hue of the adjustment color. For the human operator, this is a simple procedure by which accurate color matching results can be obtained without the need for trial and error.
The invention also provides image processing apparatus employing the invented method.



BRIEF DESCRIPTION OF THE DRAWINGS
In the attached drawings:
FIG. 1 is a block diagram of an image processing apparatus in a first embodiment of the invention;
FIG. 2 is an internal block diagram of the hue difference value calculation unit in the first embodiment;
FIG. 3 illustrates hues of primary colors employed in the first embodiment;
FIG. 4 is an internal block diagram of a gamut mapping processor employed in the first embodiment;
FIG. 5 is an internal block diagram of the color matching processing unit in the first embodiment;
FIG. 6 is a block diagram of an image processing apparatus in a second embodiment of the invention;
FIG. 7 illustrates a reference color pattern printed in the second embodiment;
FIG. 8 illustrates a printing color adjustment image displayed in the second embodiment; and
FIG. 9 is a block diagram of an image processing apparatus in a third embodiment of the invention.



DETAILED DESCRIPTION OF THE INVENTION
Embodiments of the invention will now be described with reference to the attached drawings, in which like elements are indicated by like reference characters.
In the descriptions of the embodiments, reference will be made to the well-known XYZ, Lab, L*a*b*, and LCH color spaces standardized by the International Commission on Illumination (Commission Internationale de l'Eclairage, or CIE), as well as to the RGB and CMY color spaces mentioned above. Each of these is a mathematical space in which colors are represented by three coordinates. The LCH (lightness, chroma, hue) color space is a cylindrical coordinate space. The L*a*b* color space (illustrated in FIG. 3) is a polar coordinate space that is considered perceptually even.
Referring to FIG. 1, a first embodiment of the invention is an image processing apparatus comprising a preprocessing unit 11, a prediction formula calculation unit 12, and a matching processing unit 13. These units 11, 12, 13 collectively include various hardware and software facilities, at least some of which reside in a host computing device connected to a color printer. The host computing device may be, for example, a personal computer; the color printer may be, for example, an electrophotographic printer or an ink-jet printer. The host computing device is also connected to a display unit such as a CRT monitor. From the standpoint of color conversion, the display unit is the input system and the color printer is the output system.
The preprocessing unit 11 includes an adjustment color RGB data storage unit 14 that stores red-green-blue data for six preset colors referred to below as adjustment colors. The stored data will be denoted Ri, Gi, Bi (i=1, 2, . . . , 6). The six adjustment colors are intermediate between the primary colors (red, green, blue) of the display unit and the primary colors (cyan, magenta, yellow) of the printer. Table 1 lists the six adjustment colors, their numbers, and their RGB data values, given as percentages.











TABLE 1





No.
Ri (%)
Gi (%)
Bi (%)
Description



















1
100
50
0
Red-yellow


2
50
100
0
Yellow-green


3
0
100
50
Green-cyan


4
0
50
100
Cyan-blue


5
50
0
100
Blue-magenta


6
100
0
50
Magenta-red









The preprocessing unit 11 also includes a hue difference value calculation unit 15, a hue mapping parameter storage unit 16, and a hue difference value storage unit 17. The hue difference value calculation unit 15 reads data from the adjustment color RGB data storage unit 14 and hue mapping parameter storage unit 16, and writes data in the hue mapping parameter storage unit 16 and hue difference value storage unit 17. The parameters and values stored in the hue mapping parameter storage unit 16 and hue difference value storage unit 17 are supplied to the prediction formula calculation unit 12.
In the hue mapping parameter storage unit 16, the hue difference value calculation unit 15 writes combinations of three typical values (−1, 0, 1) of six hue mapping parameters corresponding to the six intermediate colors in Table 1. The number N of combinations is seven hundred twenty-nine (N=36=729). These hue mapping parameter values will be denoted (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) (j=1, 2, . . . , 729). Table 2 lists some of the stored combinations of values.













TABLE 2





case
HPRYj
HPYGj
HPGCj
HPCBj
HPBMj
HPMRj





















1
−1
−1
−1
−1
−1
−1


2
−1
−1
−1
−1
−1
0


3
−1
−1
−1
−1
−1
1


4
−1
−1
−1
−1
0
−1


5
−1
−1
−1
−1
0
0


6
−1
−1
−1
−1
0
1


7
−1
−1
−1
−1
1
−1


8
−1
−1
−1
−1
1
0


9
−1
−1
−1
−1
1
1


10 
−1
−1
−1
0
−1
−1


:
:
:
:
:
:
:


:
:
:
:
:
:
:


729
1
1
1
1
1
1









The hue difference value calculation unit 15 uses all combinations of the hue mapping parameters in Table 2 to map the six adjustment colors from the input to the output system, calculates the difference between the hue of each adjustment color before and after each mapping, and stores the difference values (ΔHRYj, ΔHYGj, ΔHGCj, ΔHCBj, ΔHBMj, ΔHMRj) (j=1, 2, . . . , 729) in the hue difference value storage unit 17.
The prediction formula calculation unit 12 includes a hue mapping parameter prediction formula calculation unit 21 that uses the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) stored in the hue mapping parameter storage unit 16 and the hue difference values (ΔHRYj, ΔHYGj, ΔHGCj, ΔHCBj, ΔHBMj, ΔHMRj) stored in the hue difference value storage unit 17 to derive a formula for calculating or ‘predicting’ the hue mapping parameter values that will produce an arbitrary set of hue difference values. This formula is stored in a hue mapping parameter prediction formula storage unit 22.
The matching processing unit 13 includes a hue mapping parameter calculation unit 23 and a color matching processing unit 24. The hue mapping parameter calculation unit 23 receives six hue difference values (ΔH1 to ΔH6) from an input processing unit (not shown), and applies the formula stored in the hue mapping parameter prediction formula storage unit 22 to the received values to obtain six hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR). The color matching processing unit 24 uses the hue mapping parameters obtained by the hue mapping parameter calculation unit 23 to convert RGB data for the display unit to CMY data for the color printer, thereby mapping colors from the input system to the output system.
Alternatively, the color matching processing unit 24 may convert the RGB data to CMYK data, but for simplicity, CMY output data will be assumed below.
The first embodiment also includes a printer driver (not shown) that forms part of the software of the host computing device. Besides supplying control signals and data to the color printer, the printer driver generates a printing color adjustment image, which is displayed on the display unit. The printing color adjustment image includes the six adjustment colors.
The color printer has a control unit (not shown) including a microprocessor unit (MPU) or any other type of central processing unit (CPU) that controls the internal operation of the printer. One of the control functions performed by this control unit is to print a preset reference color pattern including colors with hues targeted around each of the six adjustment colors. That is, the pattern includes colors with CMY mixing ratios that vary in ranges expected to yield hues that give at least one close match to the hue of each of the adjustment colors. The printed reference color pattern also includes numbers identifying the printed reference colors.
The host computing device has an input unit (not shown) such as a keyboard, with which a human operator can enter the numbers of reference colors selected from the reference color pattern. The human operator compares the reference color pattern printed by the color printer with the adjustment colors displayed by the display unit in the printing color adjustment image, selects the six reference colors most closely matching the hues of the six adjustment color, and enters their numbers. The input processing unit mentioned above converts the entered numbers to the hue difference values (ΔH1 to ΔH6) supplied to the hue mapping parameter calculation unit 23.
Various input processing schemes are possible. One example will be shown in the third embodiment.
Next, the internal structure of the hue difference value calculation unit 15 will be described.
Referring to FIG. 2, the hue difference value calculation unit 15 includes three conversion units. An RGB/XYZ conversion unit 25 maps the RGB values (Ri, Gi, Bi) of the adjustment colors into the CIE XYZ color space and generates their XYZ values (Xi, Yi, Zi) (i=1, 2, . . . , 6). An XYZ/Lab conversion unit 26 maps the XYZ values from the CIE XYZ space to the CIE L*a*b* space and generates corresponding Lab values (Li, ai, bi) (i=1, 2, . . . , 6). The hues HR, HY, HG, HC, HB, HM of red, yellow, green, cyan, blue, and magenta in the input-system gamut are expressed on the a*b* plane in this color space as shown in FIG. 3. A Lab/LCH conversion unit 27 maps the Lab values (Li, ai, bi) from the CIE L*a*b* color space to the LCH color space and generates corresponding LCH values (Li, Ci, Hi) (i=1, 2, . . . , 6).
The hue difference value calculation unit 15 also includes a gamut mapping unit 28 and a hue angle difference calculation unit 29. The gamut mapping unit 28 maps the LCH values (Li, Ci, Hi) of the adjustment colors in the input-system gamut to LCH values (Li′, Ci′, Hi′) (i=1, 2, . . . , 6) in the output-system gamut, using the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) supplied from the hue mapping parameter storage unit 16. The hue angle difference calculation unit 29 compares the LCH values (Li, Ci, Hi) of the adjustment colors in the input system, as calculated by the Lab/LCH conversion unit 27, with the corresponding LCH values (Li′, Ci′, Hi′) in the output system, as calculated by the gamut mapping unit 28, and calculates the hue difference values (ΔHRYj, ΔHYGj, ΔHGCj, ΔHCBj, ΔHBMj, ΔHMRj).
Next, the internal structure of the gamut mapping unit 28 will be described.
Referring to FIG. 4, the gamut mapping unit 28 includes a hue mapping unit 41, a lightness adjustment unit 42, and a chroma adjustment unit 43. The hue mapping unit 41 uses the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) supplied from the hue mapping parameter storage unit 16 to map H values expressing hue angle in the input system to H′ values in the output system. The lightness adjustment unit 42 maps L values expressing lightness in the input system to L′ values within the lightness range of the output system. The chroma adjustment unit 43 maps C values expressing chroma in the input system to C′ values within the chroma range of the output system. The gamut mapping unit 28 thereby maps the gamut of colors reproducible in the input system to colors within the gamut reproducible in the output system.
Next, the internal structure of the color matching processing unit 24 will be described.
Referring to FIG. 5, the color matching processing unit 24 includes an RGB/XYZ conversion unit 35, an XYZ/Lab conversion unit 36, an Lab/LCH conversion unit 37, a gamut mapping unit 38, and an LCH/CMY conversion unit 39. The RGB/XYZ conversion unit 35 maps the RGB values of arbitrary input colors to the CIE XYZ space. The XYZ/Lab conversion unit 36 maps the resulting XYZ values (X, Y, Z) into the CIE L*a*b* space, generating Lab values (L, a, b). The Lab/LCH conversion unit 37 maps the Lab values from the L*a*b* space to the LCH space, obtaining LCH values (L, C, H) in the input-system gamut. The gamut mapping unit 38 maps these LCH values (L, C, H) to LCH values (Li′, Ci′, Hi′) in the output-system gamut, using the color mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) supplied from the hue mapping parameter calculation unit 23. The LCH/CMY conversion unit 39 converts the output-system LCH values (Li′, Ci′, Hi′) to CMY data for the color printer.
Next, the operation of the hue difference value calculation unit 15 will be described.
The hue difference value calculation unit 15 reads the six sets of RGB values (Ri, Gi, Bi) from the adjustment color RGB data storage unit 14, and the seven hundred twenty-nine sets of hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) from the hue mapping parameter storage unit 16. After mapping the RGB values (R1, G1, B1) of the first adjustment color into the LCH color space, the hue difference value calculation unit 15 uses the first set of hue mapping parameters (HPRY1, HPYG1, HPGC1, HPCB1, HPBM1, HPMR1) to map the resulting LCH values (L1, C1, H1), which lie in the input-system gamut, to LCH values (L1′, C1′, H1′) in the output-system gamut; then it compares the input-system hue value H1 with the output-system hue value H1′, and calculates and outputs the difference ΔHRY1 between the two hue values H1 and H1′.
Next, the hue difference value calculation unit 15 uses the second set of hue mapping parameters (HPRY2, HPYG2, HPGC2, HPCB2, HPBM2, HPMR2) to map the input-system LCH values (L1, C1, H1) of the first adjustment color to LCH values (L1′, C1′, H1′) in the output-system gamut, compares the input-system hue (H1) with the new output-system hue (H1′), and calculates and outputs the difference ΔHRY2 between them.
Hue difference values ΔHRYj (j=3, 4, . . . , 729) for the first adjustment color are similarly calculated and output by using the third to 729th sets of hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj).
Next, the hue difference value calculation unit 15 maps the RGB values (R2, G2, B2) of the second adjustment color into the LCH color space, uses the first set of hue mapping parameters (HPRY1, HPYG1, HPGC1, HPCB1, HPBM1, HPMR1) to map the resulting input-system LCH values (L2, C2, H2) to output-system LCH values (L2′, C2′, H2′), compares the hue values H2 and H2′, and calculates and outputs a hue difference value ΔHYG1 expressing the difference between H2 and H2′. Hue difference values ΔHYGj for the second adjustment color are similarly calculated and output using the second to 729th hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) The same process is repeated for the other four adjustment colors, so that a complete set of hue difference values (ΔHRYj, ΔHYGj, ΔHGCj, ≢HCBj, ΔHBMj, ΔHMRj) for all six adjustment colors is obtained (j=1 to 729).
Next, the operation of the RGB/XYZ conversion unit 25, XYZ/Lab conversion unit 26, Lab/LCH conversion unit 27, gamut mapping unit 28, and hue angle difference calculation unit 29 in the calculation of these hue difference values (ΔHRYj, ΔHYGj, ΔHGCj, ΔHCBj, ΔHBMj, ΔHMRj) will be described.
The RGB/XYZ conversion unit 25 converts input RGB values (Ri, Gi, Bi) to XYZ values (Xi, Yi, Zi) In the RGB values (Ri, Gi, Bi), colors are reproduced by additive color mixing, so the conversion is effected as a linear transformation represented by the following 3×3 matrix. 



   
  
    [
    
      
        
          
            X
            R
          
        
        
          
            X
            G
          
        
        
          
            X
            B
          
        
      
      
        
          
            Y
            R
          
        
        
          
            Y
            G
          
        
        
          
            Y
            B
          
        
      
      
        
          
            Z
            R
          
        
        
          
            Z
            G
          
        
        
          
            Z
            B
          
        
      
    
    ]
  




More specifically, the XYZ values (Xi, Yi, Zi) corresponding to the input RGB values (Ri, Gi, Bi) are calculated by the following matrix operation. 



  
    [
    
      
        
          
            X
            i
          
        
      
      
        
          
            Y
            i
          
        
      
      
        
          
            Z
            i
          
        
      
    
    ]
  
  =
  
    
      [
      
        
          
            
              X
              R
            
          
          
            
              X
              G
            
          
          
            
              X
              B
            
          
        
        
          
            
              Y
              R
            
          
          
            
              Y
              G
            
          
          
            
              Y
              B
            
          
        
        
          
            
              Z
              R
            
          
          
            
              Z
              G
            
          
          
            
              Z
              B
            
          
        
      
      ]
    
    ⁡
    
      [
      
        
          
            
              R
              i
            
          
        
        
          
            
              G
              i
            
          
        
        
          
            
              B
              i
            
          
        
      
      ]
    
  




The XYZ/Lab conversion unit 26 uses a well-known conversion formula to convert the XYZ values (Xi, Yi, Zi) supplied from the RGB/XYZ conversion unit 25 to Lab values (Li, ai, bi). A detailed description will be omitted.
The Lab/LCH conversion unit 27 converts the Lab values (Li, ai, bi) supplied from the XYZ/Lab conversion unit 26 to LCH values (Li, Ci, Hi) by the following formulas.

Li=Li

Ci=√(ai2+bi2)

Hi=tan−1(ai/bi)

As stated above, the gamut mapping unit 28 maps LCH values (Li, Ci, Hi) in the input-system gamut to LCH values (Li′, Ci′, Hi′) in the output-system gamut. In this process, the lightness adjustment unit 42 maps the Li value to an Li′ value as follows, where Li′max is the maximum value and Li′min is the minimum value in the lightness range of the output-system gamut.

Li′=Li′max if Li>Li′max,

Li′=Li′min if Li<Li′min, and

Li′=Li if Li′min≦Li′≦Li′max.

The chroma adjustment unit 43 maps the Ci value to a Ci′ value in the output-system gamut as follows, where Ci′max is the maximum value in the chroma range of the output-system gamut.

Ci′=Ci′max if Ci>Ci′max

Ci′=Ci if Ci≦Ci′max,

The hue mapping unit 41 uses the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) supplied from the hue mapping parameter storage unit 16 to map the Hi value expressing hue angle in the input system to an Hi′ value expressing hue angle in the output system. Further details of this mapping process will be given later.
Continuing, the hue angle difference calculation unit 29 calculates the hue difference between the Hi value supplied from the Lab/LCH conversion unit 27 and the Hi′ value supplied from the gamut mapping unit 28 by the following subtraction operation, in which value AH denotes one of the hue difference values ΔHRYj, ΔHYGj, ΔHGCj, ΔHCBj, ΔHBMj, ΔHMRj mentioned above (j=1, 2, . . . , 729).

ΔH=Hi′−Hi

Next, the operation of the RGB/XYZ conversion unit 35, XYZ/Lab conversion unit 36, Lab/LCH conversion unit 37, gamut mapping unit 38, and LCH/CMY conversion unit 39 in the color matching processing unit 24 will be described. The gamut mapping unit 38 has the same internal structure as the gamut mapping unit 28 shown in FIG. 4.
The RGB/XYZ conversion unit 35 converts RGB values (R, G, B) to XYZ values (X, Y, Z) by the 3×3 matrix operation described above. Specifically, the XYZ values (X, Y, Z) corresponding to the RGB values (R, G, B) are calculated as follows. 



  
    [
    
      
        
          X
        
      
      
        
          Y
        
      
      
        
          Z
        
      
    
    ]
  
  =
  
    
      [
      
        
          
            
              X
              R
            
          
          
            
              X
              G
            
          
          
            
              X
              B
            
          
        
        
          
            
              Y
              R
            
          
          
            
              Y
              G
            
          
          
            
              Y
              B
            
          
        
        
          
            
              Z
              R
            
          
          
            
              Z
              G
            
          
          
            
              Z
              B
            
          
        
      
      ]
    
    ⁡
    
      [
      
        
          
            R
          
        
        
          
            G
          
        
        
          
            B
          
        
      
      ]
    
  




The XYZ/Lab conversion unit 36 uses the well-known conversion formula mentioned above to convert the XYZ values (X, Y, Z) supplied from the RGB/XYZ conversion unit 35 to Lab values (L, a, b).
The Lab/LCH conversion unit 37 converts the Lab values (L, a, b) supplied from the XYZ/Lab conversion unit 36 to LCH values (L, C, H) by the following formulas.

L=L

C=√(a2+b2)

H=tan−1(a/b)

The gamut mapping unit 38 maps the input-system LCH values (L, C, H) to LCH values (L′, C′, H′) in the output-system gamut. Of the input-system LCH values (L, C, H), the L value is sent to the lightness adjustment unit 42 in the gamut mapping unit 38, and mapped to an L′ value in the output-system gamut as described above. The C value is sent to the chroma adjustment unit 43 in the gamut mapping unit 38, and mapped to a C′ value in the output-system gamut as described above. The H value is sent to the hue mapping unit 41 and mapped to an H′ value in the output-system gamut by use of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) supplied from the hue mapping parameter calculation unit 23.
The LCH/CMY conversion unit 39 converts the LCH values (L′, C′, H′) supplied from the gamut mapping unit 38 to CMY values (C, M, Y) for output to the color printer. Details of this conversion process will be omitted.
Next, the hue mapping operation carried out by the hue mapping units 41 in the two gamut mapping units 28, 38 will be described.
The hue mapping unit 41 in gamut mapping unit 28 receives hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) from the hue mapping parameter storage unit 16. The hue mapping unit 41 in gamut mapping unit 38 receives hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) from the hue mapping parameter calculation unit 23. Both hue mapping units 41 map a hue angle value (H or Hi) in the input-system gamut to a hue-angle value (H′ or Hi′) in the output-system gamut, as noted above.
As also noted above, the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) apply to hues intermediate between red and yellow (R-Y), yellow and green (Y-G), green and cyan (G-C), cyan and blue (C-B), blue and magenta (B-M), and magenta and red (M-R), respectively, and take on the three values −1, 0, 1. The predicted hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) likewise apply to hues intermediate between red and yellow (R-Y), yellow and green (Y-G), green and cyan (G-C), cyan and blue (C-B), blue and magenta (B-M), and magenta and red (M-R), respectively, but may take on arbitrary values in the interval from −1 to 1.
The values −1, 0, 1 and the values from −1 to 1 are weighting coefficients for the colors disposed between the two relevant hues. The larger the absolute values of the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) and (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) are, the more the hue angle is changed. The direction of the hue angle change is indicated by arrows in Table 3.














TABLE 3







R–Y
Y–G
G–C
C–B
B–M
M–R






















−1 to 0
R ←
Y ←
G ←
C ←
B ←
M ←








0
No change













  0 to 1
→ Y
→ G
→ C
→ B
→ M
→ R









The hue mapping processes carried out by the hue mapping units 41 in the two gamut mapping units 28, 38 differ only in the values of the hue mapping parameters, so the hue mapping process in the hue mapping unit 41 of the gamut mapping unit 38 will be described below, and a description of the hue mapping process in the hue mapping unit 41 of the gamut mapping unit 28 will be omitted.
First, the hue mapping unit 41 converts each of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) to a gamma coefficient γ and sets a flag. These operations are carried out as follows, where p represents the value of an arbitrary one of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR).

    
    
        if p<0
        then γ=2−p 
        and flag=−1,
        if p=0
        then γ=2p 
        and flag=0,
        if p>0
        then γ=2p 
        and flag=1.
    
    


Next, the hue mapping unit 41 calculates an inter-hue ratio for the hue of the input color, which has been mapped from the RGB color space to the LCH color space and has a hue value H.
First, the hue mapping unit 41 finds the hues (HS, HE) of the two primary colors between which the input hue H is disposed. For example, if the input hue H is disposed between red (HR) and yellow (HY), then:

    
    
        HS=HR 
        HE=HY 
    
    


Next, a Ratio describing the position of the input hue H between the two hues HS and HE) is calculated as follows:

    
    
        if flag=−1
        then Ratio=(H−HS)/(HE−HS),
        if flag=1
        then Ratio=(HE−H)/(HE−HS).
    
    


Next, the calculated ratio is weighted by the gamma coefficient γ. If Ratio′ is the weighted ratio, then

    
    
        Ratio′=Ratioγ
    
    


The value H representing the hue angle of the input color is then mapped to a value H′ in the output-system gamut by application of the weighted Ratio′. The mapping is carried out as follows:

    
    
        if flag=−1
        then H′=Ratio′×(HE−HS)+HS,
        if flag=1
        then H′=(1.0−Ratio′)×(HE−HS)+HS,
        if flag=0
        then H′=H.
    
    


Next the calculation of the prediction formula by the prediction formula calculation unit 12 will be described. This calculation is based on the assumption that there is a relationship of the following type between a given set of hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) and the hue difference value ΔH1 produced thereby for the first adjustment color. 



  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            1
          
        
        =
        
          
            
              a
              1
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              1
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              1
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              1
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              1
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              1
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            1
          
        
      
    
    
      
        (
        1
        )
      
    
  




The values of the hue mapping parameters (HPRYj, HPYGj, HPGCj, HPCBj, HPBMj, HPMRj) and the corresponding hue difference values ΔHRYj calculated by the hue difference value calculation unit 15 are substituted into this equation (1) as statistical data, and the coefficients a1 to g1 in are derived by multiple regression analysis by the hue mapping parameter prediction formula calculation unit 21.
Next, prediction formula coefficients a2 to g2, a3 to g3, a4 to g4, a5 to g5, and a6 to g6 are similarly calculated, on the basis of the relations below, using the hue difference values ΔH2 to ΔH6 calculated for the second through sixth adjustment colors. 



  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            2
          
        
        =
        
        ⁢
        
          
            
              a
              2
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              2
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              2
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              2
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              2
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              2
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            2
          
        
      
    
  
  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            3
          
        
        =
        
        ⁢
        
          
            
              a
              3
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              3
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              3
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              3
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              3
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              3
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            3
          
        
      
    
  
  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            4
          
        
        =
        
        ⁢
        
          
            
              a
              4
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              4
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              4
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              4
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              4
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              4
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            4
          
        
      
    
  
  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            5
          
        
        =
        
        ⁢
        
          
            
              a
              5
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              5
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              5
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              5
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              5
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              5
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            5
          
        
      
    
  
  
    
      
        
          Δ
          ⁢
          
            
          
          ⁢
          
            H
            6
          
        
        =
        
        ⁢
        
          
            
              a
              6
            
            ⁢
            
              HP
              RY
            
          
          +
          
            
              b
              6
            
            ⁢
            
              HP
              YG
            
          
          +
          
            
              c
              6
            
            ⁢
            
              HP
              GC
            
          
          +
          
            
              d
              6
            
            ⁢
            
              HP
              CB
            
          
          +
          
            
              e
              6
            
            ⁢
            
              HP
              BM
            
          
          +
          
            
              f
              6
            
            ⁢
            
              HP
              MR
            
          
          +
          
            g
            6
          
        
      
    
  




Once the values of the coefficients (a1 to g6) have been determined, the above set of six simultaneous equations can be solved to determine the unknown values of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) from a given set of hue difference values ΔH1 to ΔH6. These simultaneous equations can be written as a single matrix equation in which A represents the matrix of coefficients ai to fi (i=1, 2, . . . , 6) and C represents the column vector of coefficients gi (i=1, 2, . . . , 6). Specifically, 


  
    
      [
      
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                1
              
            
          
        
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                2
              
            
          
        
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                3
              
            
          
        
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                4
              
            
          
        
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                5
              
            
          
        
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                H
                6
              
            
          
        
      
      ]
    
    =
    
      
        A
        ⁡
        
          [
          
            
              
                
                  HP
                  RY
                
              
            
            
              
                
                  HP
                  YG
                
              
            
            
              
                
                  HP
                  GC
                
              
            
            
              
                
                  HP
                  CM
                
              
            
            
              
                
                  HP
                  MB
                
              
            
            
              
                
                  HP
                  BR
                
              
            
          
          ]
        
      
      +
      C
    
  




  
    where
    ,
  




  
    A
    =
    
      
        
          [
          
            
              
                
                  a
                  1
                
              
              
                
                  b
                  1
                
              
              
                
                  c
                  1
                
              
              
                
                  d
                  1
                
              
              
                
                  e
                  1
                
              
              
                
                  f
                  1
                
              
            
            
              
                
                  a
                  2
                
              
              
                
                  b
                  2
                
              
              
                
                  c
                  2
                
              
              
                
                  d
                  2
                
              
              
                
                  e
                  2
                
              
              
                
                  f
                  2
                
              
            
            
              
                
                  a
                  3
                
              
              
                
                  b
                  3
                
              
              
                
                  c
                  3
                
              
              
                
                  d
                  3
                
              
              
                
                  e
                  3
                
              
              
                
                  f
                  3
                
              
            
            
              
                
                  a
                  4
                
              
              
                
                  b
                  4
                
              
              
                
                  c
                  4
                
              
              
                
                  d
                  4
                
              
              
                
                  e
                  4
                
              
              
                
                  f
                  4
                
              
            
            
              
                
                  a
                  5
                
              
              
                
                  b
                  5
                
              
              
                
                  c
                  5
                
              
              
                
                  d
                  5
                
              
              
                
                  e
                  5
                
              
              
                
                  f
                  5
                
              
            
            
              
                
                  a
                  6
                
              
              
                
                  b
                  6
                
              
              
                
                  c
                  6
                
              
              
                
                  d
                  6
                
              
              
                
                  e
                  6
                
              
              
                
                  f
                  6
                
              
            
          
          ]
        
        ⁢
        
          
        
        ⁢
        C
      
      =
      
        [
        
          
            
              
                g
                1
              
            
          
          
            
              
                g
                2
              
            
          
          
            
              
                g
                3
              
            
          
          
            
              
                g
                4
              
            
          
          
            
              
                g
                5
              
            
          
          
            
              
                g
                6
              
            
          
        
        ]
      
    
  



The matrix A can be inverted to obtain a matrix A−1. This matrix A−1 and the column vector C provide a formula for calculating the hue mapping parameters from the hue difference values. The hue mapping parameter prediction formula calculation unit 21 stores the values of this matrix and vector (A−1, C) in the hue mapping parameter prediction formula storage unit 22.
The hue mapping parameter calculation unit 23 calculates the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) for performing color conversion on actual input colors (R, G, B) from the data stored in the hue mapping parameter prediction formula storage unit 22 by performing the following matrix operation on the six hue difference values (ΔH1 to ΔH6) obtained by the input processing unit from the six reference colors selected by the operator as most closely matching the hues of the adjustment colors. 



  
    [
    
      
        
          
            HP
            RY
          
        
      
      
        
          
            HP
            YG
          
        
      
      
        
          
            HP
            GC
          
        
      
      
        
          
            HP
            CM
          
        
      
      
        
          
            HP
            MB
          
        
      
      
        
          
            HP
            BR
          
        
      
    
    ]
  
  =
  
    
      
        A
        
          -
          1
        
      
      ⁡
      
        [
        
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  1
                
              
            
          
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  2
                
              
            
          
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  3
                
              
            
          
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  4
                
              
            
          
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  5
                
              
            
          
          
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  H
                  6
                
              
            
          
        
        ]
      
    
    -
    
      
        A
        
          -
          1
        
      
      ⁢
      C
    
  




The color matching processing unit 24 receives the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) from the hue mapping parameter calculation unit 23, receives input RGB color data from an external interface (not shown), and converts the input color values (R, G, B) to output color values (C, M, Y).
Since the output colors are printed by subtractive color mixing, LCH values (L′, C′, H′) corresponding to combinations of CMY values (C, M, Y) may be calculated in advance by colorimetry, and the LCH values (L′, C′, H′) and corresponding CMY values (C, M, Y) may be stored in a look-up table. The color matching processing unit 24 can then convert an LCH value (L′, C′, H′) to a CMY value (C, M, Y) by referring to the look-up table.
In the present embodiment, because the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) are calculated from the hue difference values (ΔH1, ΔH2, ΔH3, ΔH4, ΔH5,ΔAH6) of colors directly selected as matching the hues of the adjustment colors, the hues of the colors reproduced in the output system will generally match the hues of the colors reproduced in the input system closely. Moreover, there is no need to proceed by trial and error, so the work of adjusting the hue mapping parameters is greatly simplified.
Next, a second embodiment of the invention will be described.
FIG. 6 shows a block diagram of an image processing apparatus according to the second embodiment, FIG. 7 shows an example of the reference color pattern printed in the second embodiment, and FIG. 8 shows an example of the printing color adjustment image displayed in the second embodiment.
The color printer 51 used as the output system in the second embodiment is driven by a printer driver 52 residing as software in the host computing device (not shown). The color printer 51 includes a color matching processing unit 24 as described in the first embodiment, an adjustment color sample data storage unit 53, a printing control unit 54, and a hue mapping parameter storage unit 55. The adjustment color sample data storage unit 53 stores data for printing a reference color pattern in which the mixing ratios of the color components of the adjustment colors are varied in steps. The adjustment colors are the same as in the first embodiment (Table 1).
Referring to FIG. 7, the reference color pattern includes the six primary colors of the input and output systems, namely red (R), yellow (Y), green (G), cyan (C), blue (B), and magenta (M), and nine reference colors in each of the six intervals (red-yellow, yellow-green, green-cyan, cyan-blue, blue-magenta, and magenta-red) between mutually adjacent pairs of primary colors. In each interval, the mixing ratios of the primary colors vary in steps of 10% from 0% to 100%. The primary colors are identified as color 1 and color 2 in FIG. 7, and the mixing ratios are indicated between the reference colors. The reference colors themselves are identified by numbers from one to nine in each interval.
The printing control unit 54 includes a reference color output means (not shown) that prints the reference color pattern shown in FIG. 7, using the adjustment color sample data stored in the adjustment color sample data storage unit 53, and a printing processing means (not shown) that prints general color images according to CMY values (C, M, Y) supplied from the color matching processing unit 24. The color matching processing unit 24 operates on RGB data supplied from the printer driver 52 according to hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) stored in the hue mapping parameter storage unit 55. The hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) are supplied from the printer driver 52.
The reference color output means in the printing control unit 54 and the adjustment color sample data storage unit 53 form a reference color output processing unit that outputs the reference color pattern in the output system.
The printer driver 52 includes an adjustment starting unit 50, a sample hue mapping parameter storage unit 56, a hue mapping parameter readout unit 57 used as a hue mapping parameter determination means, a printing data output unit 58, and an application program 59. The sample hue mapping parameter storage unit 56 stores hue mapping parameters that map the adjustment colors to the reference colors printed in the reference color pattern in FIG. 7. The stored hue mapping parameters (HPRYk, HPYGk, HPGCk, HPCBk, HPBMk, HPMRk) are listed in Table 4, where the value of k (k=10, 20, . . . , 90) corresponds to the percentage of color 2 in FIG. 7.









TABLE 4









Hue interval spacing

















10[%]
20[%]
30[%]
40[%]
50[%]
60[%]
70[%]
80[%]
90[%]











Hue interval
















R–Y
HPRY10
HPRY20
HPRY30
HPRY40
HPRY50
HPRY60
HPRY70
HPRY80
HPRY90


Y–G
HPYG10
HPYG20
HPYG30
HPYG40
HPYG50
HPYG60
HPYG70
HPYG80
HPYG90


G–C
HPGC10
HPGC20
HPGC30
HPGC40
HPGC50
HPGC60
HPGC70
HPGC80
HPGC90


C–B
HPCB10
HPCB20
HPCB30
HPCB40
HPCB50
HPCB60
HPCB70
HPCB80
HPCB90


B–M
HPBM10
HPBM20
HPBM30
HPBM40
HPBM50
HPBM60
HPBM70
HPBM80
HPBM90


M–R
HPMR10
HPMR20
HPMR30
HPMR40
HPMR50
HPMR60
HPMR70
HPMR80
HPMR90









The numerical values of the hue mapping parameters in Table 4 may be calculated by the method described in the first embodiment, or by any other convenient method.
The printer driver 52 also includes means (not shown) for displaying the printing color adjustment image in FIG. 8. This image has a color display section 71 with areas AR1 to AR6 for display of the six adjustment colors in the hue intervals between red and yellow (R-Y), yellow and green (Y-G), green and cyan (G-C), cyan and blue (C-B), blue and magenta (B-M), and magenta and red (M-R). Frames fr1 are also displayed in which the operator can enter numbers from one to nine to identify a reference color matching the hue of each adjustment color, selected from the hue interval to which the adjustment color belongs in the reference color pattern in FIG. 7.
Displayed at the bottom of the printing color adjustment image in FIG. 8 are a button k1 that the operator can activate with a pointing device such as a mouse to start the hue mapping adjustment process, and a button k2 that can be activated to conclude the hue mapping adjustment process. When the operator activates button k1, the adjustment starting unit 50 sends a reference color pattern printing command to the color printer 51. When the operator activates button k2, the hue mapping parameter readout unit 57 sends the color printer 51 hue mapping parameters read from the sample hue mapping parameter storage unit 56.
The printing data output unit 58 generates RGB color data according to printing data obtained from the application program 59, and sends the RGB data to the color printer 51. The application program 59, incidentally, may be external to the printer driver 52 instead of internal thereto as shown.
Next, the operation of the second embodiment will be described.
To begin the process of adjusting the hue mapping parameters, the operator activates button k1 in FIG. 8, causing the adjustment starting unit 50 to send the color printer 51 a command to print the reference color pattern. In response to this command, the data stored in the adjustment color sample data storage unit 53 are provided to the printing control unit 54, which prints the data as the reference color pattern shown in FIG. 7. At the same time, the printer driver 51 displays the color printing adjustment image shown in FIG. 8 on the display unit of the host computing device.
Next, the operator selects the printed reference colors with hues closest to the hues of the six adjustment colors displayed in areas AR1 to AR6 of the printing color adjustment image, and enters the corresponding numbers in the frames fr1. An input processing unit (not shown) in the printer driver 52 processes the entered numbers and generates selected color designation signals (SNRY, SNYG, SNGC, SNCB, SNBM, SNMR), which are supplied to the hue mapping parameter readout unit 57. The hue mapping parameter readout unit 57 reads the six hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) corresponding to the selected color designation signals (SNRY, SNYG, SNGC, SNCB, SNBM, SNMR) from the sample hue mapping parameter storage unit 56.
When the operator activates button k2, the hue mapping parameter readout unit 57 sends these hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) to the color printer 51. The color printer 51 stores the received hue mapping parameters in the hue mapping parameter storage unit 55. Display of the printing color adjustment image may be terminated at this point.
After these preparations, when the application program 59 sends printing data to the printing data output unit 58 in the printer driver 52, the printing data output unit 58 sends corresponding RGB color data to the color matching processing unit 24 in the color printer 51. The color matching processing unit 24 uses the six hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) stored in the hue mapping parameter storage unit 55 to convert the RGB color data to CMY color data, as described in the first embodiment, and sends the CMY data to the printing control unit 54. The printing processing means in the printing control unit 54 performs printing processing according to the CMY data, thereby printing images created by the application program 59.
The second embodiment has the same effects as the first embodiment. Since the hue mapping parameters are determined by directly selecting printed reference colors that match the hues of the adjustment colors, accurate color mapping from the input system to the output system can be achieved without the need for a lengthy trial-an-error process of parameter adjustment.
Next, a third embodiment of the invention will be described.
Referring to FIG. 9, the third embodiment includes the same color printer 51 as in the second embodiment, and a printer driver 52. The printer driver 52 includes a hue mapping parameter prediction formula storage unit 22 and a hue mapping parameter calculation unit 23 as described in the first embodiment; an adjustment starting unit 50, a printing data output unit 58, and an application program 59 as described in the second embodiment; an adjustment color sample hue difference value storage unit 60; and a hue difference value readout unit 61. The printer driver 52 also includes means (not shown) for displaying a printing color adjustment image such as the one in FIG. 8, including the six adjustment colors used in the first and second embodiments.
The adjustment color sample hue difference value storage unit 60 stores hue difference values indicating hue differences between the adjustment colors and the reference colors in the same hue intervals as the adjustment colors. The stored hue difference values (ΔHRYn, ΔHYGn, ΔHGCn, ΔHCBn, ΔHBMn, ΔHMRn) (n=10, 20, . . . , 90) are listed in Table 5.









TABLE 5









Hue interval spacing

















10[%]
20[%]
30[%]
40[%]
50[%]
60[%]
70[%]
80[%]
90[%]











Hue interval
















R–Y
Δ HPRY10
Δ HPRY20
Δ HPRY30
Δ HPRY40
Δ HPRY50
Δ HPRY60
Δ HPRY70
Δ HPRY80
Δ HPRY90


Y–G
Δ HPYG10
Δ HPYG20
Δ HPYG30
Δ HPYG40
Δ HPYG50
Δ HPYG60
Δ HPYG70
Δ HPYG80
Δ HPYG90


G–C
Δ HPGC10
Δ HPGC20
Δ HPGC30
Δ HPGC40
Δ HPGC50
Δ HPGC60
Δ HPGC70
Δ HPGC80
Δ HPGC90


C–B
Δ HPCB10
Δ HPCB20
Δ HPCB30
Δ HPCB40
Δ HPCB50
Δ HPCB60
Δ HPCB70
Δ HPCB80
Δ HPCB90


B–M
Δ HPBM10
Δ HPBM20
Δ HPBM30
Δ HPBM40
Δ HPBM50
Δ HPBM60
Δ HPBM70
Δ HPBM80
Δ HPBM90


M–R
Δ HPMR10
Δ HPMR20
Δ HPMR30
Δ HPMR40
Δ HPMR50
Δ HPMR60
Δ HPMR70
Δ HPMR80
Δ HPMR90









A formula for calculating hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) from given hue difference values (ΔHRY, ΔHYG, ΔHGC, ΔHCB, ΔHBM, ΔHMR) is stored in the hue mapping parameter prediction formula storage unit 22. The same formula (A−1, C) as in the first embodiment may be used.
When the operator selects a reference color in the reference color pattern printed by the color printer 51 and enters its number as explained in the second embodiment, the hue difference value readout unit 61 reads the hue difference value corresponding to the selected color from the adjustment color sample hue difference value storage unit 60. After reference colors have been selected for all six adjustment colors, the corresponding hue difference values are sent to the hue mapping parameter calculation unit 23, which calculates the values of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) from the hue difference values and the formula stored in the hue mapping parameter prediction formula storage unit 22, as described in the first embodiment.
Next, the operation of the third embodiment will be described.
When the operator activates button k1 on the printing color adjustment image (FIG. 8) to begin the hue mapping parameter adjustment process, the adjustment starting unit 50 sends the color printer 51 a command to have the data stored in the adjustment color sample data storage unit 53 sent to the printing control unit 54 and printed, as described in the second embodiment.
The operator then selects the reference colors having hues closest to the hues of the six adjustment colors displayed in areas AR1 to AR6 of the printing color adjustment image, and enters the numbers of the selected reference colors in the frames fr1. An input processing facility (not shown) in the printer driver 52 processes the entered numbers to generate selected color designation signals (SNRY, SNYG, SNGC, SNCB, SNBM, SNMR), which are supplied to the hue difference value readout unit 61. The hue difference value readout unit 61 reads the six corresponding color difference values (which may be denoted ΔHRY, ΔHYG, ΔHGC, ΔHCB, ΔHBM, ΔHMR) from the adjustment color sample hue difference value storage unit 60. The input processing facility, the adjustment color sample hue difference value storage unit 60, and the hue difference value readout unit 61 thus form an input processing unit that obtains color difference values from the numbers entered by the operator.
The hue mapping parameter calculation unit 23 receives the six color difference values (ΔHRY, ΔHYG, ΔHGC, ΔHCB, ΔHBM, ΔHMR, equivalent to ΔH1 to ΔH6 in the first embodiment) from the hue difference value readout unit 61. The hue mapping parameter calculation unit 23 also reads the hue mapping parameter prediction formula (A−1, C) from the hue mapping parameter prediction formula storage unit 22, and calculates six hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) as described in the first embodiment.
When the operator activates button k2, the hue mapping parameter calculation unit 23 sends the calculated hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) to the color printer 51, where they are stored in the hue mapping parameter storage unit 55.
Subsequently, when the application program 59 sends printing data to the printing data output unit 58 in the printer driver 52, the printing data output unit 58 sends corresponding RGB color data to the color printer 51. As in the second embodiment, the color matching processing unit 24 in the color printer 51 uses the six hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR) stored in the hue mapping parameter storage unit 55 to map the RGB data to CMY data, and the printing control unit 54 directs the printing of a corresponding color image.
To the operator, the third embodiment provides the same advantages as the second embodiment, namely, accurate color mapping without the need to resort to trial and error to adjust the values of the hue mapping parameters (HPRY, HPYG, HPGC, HPCB, HPBM, HPMR).
The present invention is not limited to the preceding embodiments. Various modifications are possible.
To give one example, the reference color pattern may include colors with the same hue but different lightness and chroma values, so that lightness and chroma mapping parameters can also be adjusted according to the selected reference colors.
To give another example, for each adjustment color, the reference color pattern may include, instead of a number of discrete reference colors, a continuous swath of color with gradually varying hue. The selected reference color can be designated in terms of its distance from one end of the swath, preferably indicated by a distance scale printed adjacent to the swath.
Those skilled in the art will recognize that many further modifications are possible. The scope of the invention should accordingly be determined from the appended claims.

## Claims

1. An image processing apparatus for mapping colors reproduced in an input system to colors reproduced in an output system, comprising:
a reference color output processing unit generating a reference color pattern including colors with hues varying in respective ranges targeted around hues of a plurality of adjustment colors, each range of hues being created by mixing colors in different ratios, and causing the output system to reproduce the reference color pattern;
an input processing unit for obtaining input values related to hues in the reference color pattern corresponding respectively to the hues of the adjustment colors in the input system;
a hue mapping parameter determination unit determining hue mapping parameters from said input values; and
a color matching processing unit executing color conversion from the input system to the output system according to the hue mapping parameters determined by the hue mapping parameter determination unit.

2. The image processing apparatus of claim 1, wherein:
the input values obtained by the input processing unit designate hues in the reference color pattern; and
the hue mapping parameter determination unit includes a table of hue mapping parameter values corresponding to different hues in the reference color pattern.

3. The image processing apparatus of claim 1, wherein:
the input values obtained by the input processing unit designate hue differences between the hues of the adjustment colors and the corresponding hues in the reference color pattern; and
the hue mapping parameter determination unit stores a formula for calculating the hue mapping parameters from said hue differences.

4. The image processing apparatus of claim 3, further comprising:
a hue difference value calculation unit converting the adjustment colors from the input system of the output system according to different hue mapping parameter values, and calculating resulting hue difference values; and
a coefficient calculation unit using said different hue mapping parameter values and said resulting hue difference values to calculate said formula.

5. The image processing apparatus of claim 3, wherein the formula is derived by:
mapping the adjustment colors according to a plurality of sets of hue mapping parameters;
taking differences between hues of the adjustment colors before mapping and corresponding hues of the adjustment colors after mapping; and
determining the formula from the differences and the plurality of set of hue mapping parameters.

6. The image processing apparatus of claim 1, wherein the input processing unit obtains said input values according to a hues selected by a human operator from the reference color pattern as most closely matching the hues of the adjustment colors.

7. The image processing apparatus of claim 1, wherein each of said ranges comprises hues created by mixing two primary colors in different ratios.

8. A method of mapping colors reproduced in an input system to colors reproduced in an output system, comprising:
reproducing a reference color pattern in the output system, the reference color pattern including colors with hues varying in respective ranges targeted around hues of a plurality of adjustment colors, each range of hues being created by mixing colors in different ratios;
obtaining input values related to hues in the reference color pattern corresponding respectively to the hues of the adjustment colors in the input system;
determining hue mapping parameters from a said input values; and
converting colors from the input system to the output system according to the hue mapping parameters thus determined.

9. The method of claim 8, wherein:
said input values designate hues in the reference color pattern; and
said hue mapping parameters are determined from a table of hue mapping parameter values corresponding to different hues in the reference color pattern.

10. The method of claim 8, wherein:
said input values designate hue differences between the hues of the adjustment colors and the corresponding hues in the reference color pattern; and
said hue mapping parameters are determined from a formula for calculating the hue mapping parameters from said hue differences.

11. The method of claim 10, further comprising:
converting the adjustment colors from the input system to the output system according to different hue mapping parameter values;
calculating resulting hue difference values; and
using said different hue mapping parameter values and said resulting hue difference values to calculate said formula.

12. The method of claim 10, wherein the formula is derived by:
mapping the adjustment colors according to a plurality of sets of hue mapping parameters;
taking differences between hues of the adjustment colors before mapping and corresponding hues of the adjustment colors after mapping; and
determining the formula from the differences and the plurality of sets of hue mapping parameters.

13. The method of claim 8, wherein obtaining input values further comprises:
having a human operator select, from the reference color pattern hues most closely matching the hues of the adjustment colors;
having the human operator enter information corresponding to the selected hues into a computing device coupled to the input system; and
obtaining said input values from the entered information.

14. The method of claim 8, wherein:
reproducing said reference color pattern in the output system comprises outputting materials having the colors of said reference color pattern.

15. The method of claim 8, wherein:
reproducing said reference color pattern in the output system comprises printing said reference color pattern.

16. The method of claim 8, wherein each of said ranges comprises hues created by mixing two primary colors in different ratios.

17. An image processing apparatus for mapping colors reproduced in input system to colors reproduced in a printer, comprising:
a reference color output processing unit generating a reference color pattern including colors with hues varying in respective ranges targeted around hues of a plurality of adjustment colors, each range of hues being created by mixing colors in different ratios, and causing the printer to print the reference color pattern;
an input processing unit for obtaining input values related to hues in the reference color pattern corresponding respectively to the hues of the adjustment colors in the input system;
a hue mapping parameter determination unit determining hue mapping parameters from said input values; and
a color matching processing unit executing color conversion from the input system to the printer according to the hue mapping parameters determined by the hue mapping parameter determination unit.

18. The image processing apparatus of claim 17, wherein each of aid ranges comprises hues created by mixing two primary colors in different ratios.