Image processing apparatus, method, and program
The image processing device controls color mapping to ensure consistent colors across areas by suppressing color corrections based on acquired color characteristics, preventing color inconsistencies.
Patent Information
- Application Number
- JP2024100743
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-06-21
- Publication Date
- 2026-01-08
AI Technical Summary
When correcting color mapping results in different areas of an image, colors that are the same between areas may end up becoming different colors, leading to inconsistencies.
An image processing device that includes a first acquisition means for color information, a color conversion means, a correction means, a second acquisition means, and a control means to suppress color correction based on characteristics of the color information, ensuring consistent color across areas.
Prevents the same color from appearing as a different color between areas, maintaining color consistency.
Smart Images

Figure 2026002623000001_ABST
Abstract
Description
[Technical Field]
[0001] The present invention relates to an image processing device capable of performing mapping, a method for the image processing device, and a program. [Background technology]
[0002] It is known that when a digital document described in a predetermined color space is received and each color in that color space is mapped to a color gamut that can be reproduced by a printer, the mapping destination to the color gamut is corrected according to the input data. Patent Document 1 describes that color mapping to the print gamut is performed so as to reduce the degree of color degeneration by increasing the inter-color distance between colors that cause color degeneration among the input colors. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Japanese Patent Application Publication No. 2024-008263 Summary of the Invention [Problem to be solved by the invention]
[0004] When correction is made to the mapping results according to the input colors in an area such as a page, colors that are the same between different areas may end up becoming different colors between the areas.
[0005] An object of the present invention is to provide an image processing device, method, and program that enable control of correction to mapping results. [Means for solving the problem]
[0006] In order to solve the above problem, the image processing device of the present invention is characterized in that it comprises a first acquisition means for acquiring color information of a first color gamut defined in image data; a color conversion means for converting the color information of the first color gamut acquired by the first acquisition means into color information of a second color gamut narrower than the first color gamut; a correction means for correcting the color conversion means so that the destination of the color information of the first color gamut by the color conversion means is changed in the second color gamut; a second acquisition means for acquiring information indicating the characteristics of the color information of the first color gamut acquired by the first acquisition means in an image represented by the image data; a setting means for setting color information of the first color gamut acquired by the first acquisition means that is to be targeted for suppression of correction by the correction means based on the information indicating the characteristics of the color information of the first color gamut acquired by the second acquisition means; and a control means for controlling the correction means to suppress correction of the color information set by the setting means. [Effects of the Invention]
[0007] According to the present invention, it is possible to control the correction of the mapping result, thereby preventing the same color from appearing in different areas as a different color between the areas. [Brief explanation of the drawings]
[0008] [Figure 1] FIG. 1 is a block diagram showing a configuration of an image processing device. [Figure 2] FIG. 2 is a diagram illustrating a recording head. [Figure 3] 10 is a flowchart showing the overall processing of the image processing device. [Figure 4] 10 is a flowchart showing a process for creating a table after color degeneration correction. [Figure 5] FIG. 10 is a diagram for explaining detection of the number of color combinations that are color-degenerated. [Figure 6] 10 is a flowchart showing the process of S102. [Figure 7] FIG. 2 is a diagram showing manuscript data. [Figure 8]FIG. 10 is a diagram showing color accompanying information. [Figure 9] FIG. 10 is a diagram for explaining a paper edge region. [Figure 10] 10 is a flowchart showing the overall processing of the image processing device. [Figure 11] 10 is a flowchart showing the processing of S1002. [Figure 12] 10 is a flowchart showing the overall processing of the image processing device. [Figure 13] 10 is a flowchart showing the overall processing of the image processing device. [Figure 14] 10 is a flowchart showing the processing of S1302. [Figure 15] FIG. 10 is a diagram illustrating a user interface screen. [Figure 16] FIG. 10 is a diagram illustrating a user interface screen. [Figure 17] FIG. 10 is a diagram illustrating a user interface screen. [Figure 18] FIG. 10 is a diagram for explaining the color degeneration determination process in step S202. [Figure 19] FIG. 10 is a diagram for explaining the color degeneration correction process in step S205. [Figure 20] FIG. 10 is a diagram for explaining the color degeneration correction process in step S205. [Figure 21] FIG. 10 is a diagram showing a correction table for expanding brightness in the brightness direction. [Figure 22] FIG. 10 is a diagram showing a correction table for expanding brightness in the brightness direction. [Figure 23] FIG. 10 is a diagram showing a correction table for expanding brightness in the brightness direction. [Figure 24] FIG. 10 is a diagram showing a correction table for expanding brightness in the brightness direction. DETAILED DESCRIPTION OF THE INVENTION
[0009] Hereinafter, embodiments will be described in detail with reference to the accompanying drawings. Note that the following embodiments do not limit the scope of the invention claimed. Although multiple features are described in the embodiments, not all of these multiple features are necessarily essential to the invention, and multiple features may be combined arbitrarily. Furthermore, in the accompanying drawings, the same reference numerals are used to designate the same or similar components, and redundant explanations will be omitted.
[0010] [First embodiment] The terms used in this specification are defined as follows.
[0011] (color gamut) The term "color gamut" is also referred to as the color reproduction range, color gamut, or gamut. Generally, the term "color gamut" refers to the range of colors that can be reproduced in an arbitrary color space. The color gamut volume is an index used to express the size of the color gamut. The color gamut volume is a three-dimensional volume in an arbitrary color space. The chromaticity points that make up the color gamut may be discrete. For example, a specific color gamut may be represented by 729 points on the CIE-L*a*b* space, and the points between them may be calculated using known interpolation methods such as tetrahedral interpolation or cubic interpolation. In such cases, the corresponding color gamut volume can be calculated by accumulating the volumes of the tetrahedrons or cubes that make up the color gamut in the CIE-L*a*b* space, depending on the interpolation method used. The color gamut and color gamut in this embodiment are not limited to a specific color space. However, in this embodiment, the color gamut in the CIE-L*a*b* space is used as an example. Furthermore, the numerical values of the color gamut in this embodiment indicate the volume when cumulatively calculated in the CIE-L*a*b* space on the premise of tetrahedral interpolation.
[0012] (gamut mapping) Gamut mapping is the process of converting between different color gamuts, such as mapping an input color gamut to the output color gamut of a device like a printer. Common ICC profiles include Perceptual, Saturation, and Colorimetric. Mapping can be achieved using a 3D lookup table (3DLUT). Alternatively, mapping can be performed after color space conversion to a standard color space. For example, if the input color space is sRGB, it is converted to the CIE-L*a*b* color space, and then mapped to the output color gamut in the CIE-L*a*b* color space. Mapping can be performed using a 3DLUT or a conversion formula. Furthermore, conversions between the input and output color spaces can be performed simultaneously. For example, the input color space can be sRGB, and the output color space can be converted to the printer's native RGB or CMYK values.
[0013] (Manuscript data) Original data refers to the entire input digital data to be processed. Original data can include one or more pages. Each individual page can be held as image data or expressed as drawing commands. If expressed as drawing commands, the data can be rendered and converted into image data before processing. Image data is made up of multiple pixels arranged two-dimensionally. The pixels hold information representing colors in a color space. Examples of information representing colors include RGB values, CMYK values, K values, CIE-L*a*b* values, HSV values, and HLS values. Note that this embodiment can be applied to both one page and multiple pages. In this embodiment, as an example, original data of one page will be described as image data.
[0014] (Color degeneration) In this embodiment, when gamut mapping is performed on any two colors, color degeneration is defined as the phenomenon in which the distance between the colors after mapping in a specified color space is smaller than the distance between the colors before mapping. Specifically, assume that a digital document contains colors A and B, and mapping to the printer's color gamut converts color A to color C and color B to color D. In this case, color degeneration is defined as the distance between colors C and D being smaller than the distance between colors A and B. When color degeneration occurs, colors that are perceived as different in the digital document are perceived as the same color when printed. For example, in a graph, different items are colored differently to make them appear different. When color degeneration occurs, different colors may be perceived as the same color, leading to the possibility that different items on the graph are mistakenly perceived as the same item. The specified color space used to calculate the distance between colors here may be any color space. For example, these include the sRGB color space, Adobe RGB color space, CIE-L*a*b* color space, CIE-LUV color space, XYZ color space, xyY color space, HSV color space, and HLS color space.
[0015] FIG. 1 is a block diagram showing an example of the configuration of an image processing device according to this embodiment. The image processing device 101 may be, for example, a PC, a tablet, a server, or a recording device. FIG. 1 shows an example in which the image processing device 101 is configured separately from a recording device 108. The CPU 102 reads programs stored in a storage medium 104, such as a hard disk drive (HDD) or a read-only memory (ROM), into a RAM 103 serving as a work area, and executes the programs to perform various image processing. For example, the CPU 102 receives commands from a user via a human interface device (HID) I / F (not shown). The CPU 102 then performs various image processing operations in accordance with the received commands and the programs stored in the storage medium 104. The CPU 102 also performs predetermined processing on manuscript data received via a data transfer I / F 106 in accordance with the programs stored in the storage medium 104. The CPU 102 then displays the results and various information on a display (not shown) and transmits the results and various information as recording data via the data transfer I / F 106.
[0016] The image processing accelerator 105 is hardware capable of executing image processing faster than the CPU 102. The image processing accelerator 105 is activated when the CPU 102 writes parameters and data required for image processing to a predetermined address in the RAM 103. The image processing accelerator 105 reads the parameters and data and then executes image processing on the data. However, the image processing accelerator 105 is not an essential element, and equivalent processing may be executed by the CPU 102. Specifically, the image processing accelerator is a GPU or a specially designed electrical circuit. The parameters may be stored in the storage medium 104 or may be obtained from an external device via the data transfer I / F 106. The image processing device 101 is not limited to the configuration shown in FIG. 1 and may have a configuration appropriate for the functions executable by the device used as the image processing device 101.
[0017] In the recording device 108, the CPU 111 reads out a program stored in the storage medium 113 into the RAM 112, which serves as a work area, and executes the program, thereby providing overall control over the recording device 108. The image processing accelerator 109 is hardware capable of executing image processing faster than the CPU 111. The image processing accelerator 109 is activated when the CPU 111 writes parameters and data required for image processing to a predetermined address in the RAM 112. After reading the parameters and data, the image processing accelerator 109 executes image processing on the data. However, the image processing accelerator 109 is not an essential element, and equivalent processing may be executed by the CPU 111. The parameters may be stored in the storage medium 113, or may be stored in storage (not shown), such as a flash memory or a HDD.
[0018] Here, we will explain the image processing performed by the CPU 111 or the image processing accelerator 109. Image processing is, for example, processing that generates data indicating the ink dot formation positions during each scan by the print head 115 based on the acquired print data. The CPU 111 or the image processing accelerator 109 performs color conversion processing and quantization processing on the acquired print data.
[0019] The color conversion process is a process for separating colors into ink densities that can be handled by the printing device 108. For example, the acquired printing data includes image data that represents an image. If the image data represents an image in color space coordinates such as sRGB, which are the representation colors of a monitor, the data that represents the image in the sRGB color coordinates (R, G, B) is converted into ink data (CMYK) that can be handled by the printing device 108. The color conversion method is realized by matrix calculation processing or processing using 3DLUT or 4DLUT, etc.
[0020] In this embodiment, the recording device 108 uses, as an example, black (K), cyan (C), magenta (M), and yellow (Y) inks for recording. Therefore, image data of RGB signals is converted into image data consisting of 8-bit color signals for K, C, M, and Y, respectively. Each color signal corresponds to the amount of ink applied. Although four ink colors (K, C, M, and Y) have been used as an example, other ink colors, such as fluorescent ink (F), light-density light cyan (Lc), light magenta (Lm), or gray (Gy) ink, may be used to improve image quality. In this case, color signals corresponding to those inks are generated.
[0021] After the color conversion process, the ink data is subjected to a quantization process. The quantization process reduces the number of gradation levels in the ink data. In this embodiment, quantization is performed using a dither matrix that arranges threshold values for comparison with the ink data value for each pixel. After the quantization process, binary data is ultimately generated that indicates whether or not a dot will be formed at each dot formation position.
[0022] After image processing, the printhead controller 114 transfers the binary data to the printhead 115. At the same time, the CPU 111 performs printing control via the printhead controller 114 to operate a carriage motor (not shown) that drives the printhead 115, and also to operate a transport motor that transports the print medium. The printhead 115 scans over the print medium, and at the same time, the printhead 115 ejects ink droplets onto the print medium, thereby forming an image.
[0023] The image processing device 101 and the recording device 108 are connected via a communication line 107. In this embodiment, a local area network (LAN) is described as an example of the communication line 107, but it may also be a USB hub, a wireless communication network using a wireless access point, or a connection using a Wi-Fi Direct communication function. Furthermore, devices other than the image processing device 101 and the recording device 108 may be connected to the communication line 107. For example, a host PC may be connected to the communication line 107, and the image processing device 101 and the recording device 108 may each be configured to be able to communicate with the host PC.
[0024] The following description will be given assuming that the recording head 115 has nozzle rows for four color inks: cyan (C), magenta (M), yellow (Y), and black (K).
[0025] FIG. 2 is a diagram illustrating a print head 115 according to this embodiment. In this embodiment, an image is printed in a unit area corresponding to one nozzle array through multiple scans N times. The print head 115 includes a carriage 116, nozzle arrays 117(K), 118(C), 119(M), and 120(Y), and an optical sensor 122. The carriage 116, which carries the five nozzle arrays 117, 118, 119, and 120 and the optical sensor 122, can move back and forth along the X direction (main scanning direction) in the figure by the driving force of a carriage motor transmitted via a belt 121. As the carriage 116 moves in the X direction relative to the print medium, ink droplets are ejected from each nozzle of the nozzle array in the direction of gravity (-z direction in the figure) based on image data. This prints an image corresponding to 1 / N main scanning passes on the print medium placed on a platen 123. When one main scan is completed, the recording medium is transported in a transport direction that intersects with the main scan direction (the -y direction in the figure) by a distance corresponding to the width of 1 / N of the main scan. Through these operations, an image with a width equivalent to one nozzle row is recorded over N scans. By alternately repeating such main scans and transport operations, an image is gradually formed on the recording medium. In this way, control is performed to complete image recording on a specified area.
[0026] Some printed materials require consistent color across different regions, such as pages. For example, when a theme color, whose color is important in design, is used, it is important that headings, text, and the like are represented in a specific color across multiple pages. Here, for example, if the same input color exists across different pages and different colors exist on each page, the combination of input colors will differ between pages. Therefore, if dynamic gamut mapping is performed on each page based on the input color and color reduction correction is performed, color variations will occur and the resulting colors will be different even for the same input color. In this embodiment, colors for which it is important that the color is consistent across pages are determined as target colors for color variation suppression based on information in the image data. Then, when creating a mapping after color reduction correction, color reduction correction is not performed on target colors for color variation suppression, but is performed on colors that are not target colors for color variation suppression. This achieves the effect of suppressing color variation for colors for which it is important that the color is consistent across pages, while maintaining the effect of dynamic color reduction correction as much as possible.
[0027] <Overall flow> FIG. 3 is a flowchart showing the overall processing of the image processing device 101 in this embodiment. In this embodiment, the processing of FIG. 3 can increase the distance between colors in a predetermined color space for color combinations that cause color degeneration. As a result, the degree of color degeneration can be reduced. The processing of FIG. 3 is realized, for example, by the CPU 102 reading a program stored in the storage medium 104 into the RAM 103 and executing it. The processing of FIG. 3 may also be executed by the image processing accelerator 105.
[0028] In S101, the CPU 102 acquires original data stored in the storage medium 104. Alternatively, the CPU 102 may input the acquired original data via the data transfer I / F 106. Image data including color information is acquired from the input original data. The image data includes, as color information, values representing colors expressed in a predetermined color space. In S101, the CPU 102 acquires values representing colors. Examples of values representing colors include sRGB data, Adobe RGB data, CIE-L*a*b* data, CIE-LUV data, XYZ color system data, xyY color system data, HSV data, and HLS data.
[0029] In S102, CPU 102 executes processing to generate color variation suppression information. FIG. 6 is a flowchart showing the processing of S102. In S601, CPU 102 acquires color accompanying information associated with each piece of color information of the image data constituting the original data acquired in S101. Specific examples of color accompanying information include the number of pixels, the position of a rectangular area, and distribution within the paper surface. Color variation suppression information is information that includes color information, color accompanying information, and information on colors targeted for color variation suppression. Specific examples of color accompanying information will be described with reference to FIG. 7.
[0030] FIG. 7 is a diagram showing an example of input manuscript data. FIG. 7 shows manuscript data including two pieces of image data, image data 700 and image data 704. FIG. 8 is a diagram showing an example of color-associated information acquired in S102. First, the image data 700 will be described. The image data 700 includes three input colors: input color 701, input color 702, and input color 703. In S101, values representing the colors of these three input colors, such as RGB values, are acquired as color information. In S601, color-associated information is acquired for each color in the color information acquired in S101. As an example, color-associated information 800 in FIG. 8 shows color-associated information acquired from the image data 700. RGB values are values representing colors. The number of pixels is the number of pixels corresponding to each input color in the image data. The start coordinate is the coordinate of the upper left corner when the location of each input color is represented as a rectangular area, and the end coordinate is the coordinate of the lower right corner. Note that, in this example, the upper left corner of the entire area in the image data is set as the origin.
[0031] In S602, the CPU 102 calculates a likelihood for determining a target color for color variation suppression based on the color-associated information obtained in S601. In this embodiment, this likelihood is called an intra-page likelihood. A target color for color variation suppression is a color that is determined to be a target for which color degeneration correction (or suppression) is not performed because it is important that the color consistency across pages is the same. An example of a color that is important that the color consistency across pages is a theme color on a document that has a common design or template across multiple pages and in which headings, text, etc. are created in a fixed color. Such colors often have characteristics in the color-associated information obtained in S601, such as a high ratio of the number of pixels to the total number of pixels on the page, a large rectangular area representing their location, or a location at the edge of the area represented by the image data. In this embodiment, these characteristics are used as criteria for selecting a target color for color variation suppression. The intra-page likelihood is calculated for each input color from the color-associated information.
[0032] An example of calculating the in-page likelihood will be described. The in-page likelihood is calculated by combining multiple values. In this embodiment, for example, the in-page likelihood is calculated by combining three values: a value calculated based on the number of pixels, a value calculated based on the rectangular area size, and a value calculated based on the location.
[0033] The value calculated from the number of pixels is the ratio of the number of pixels of the input color to the maximum number of pixels in the image data. At this time, a threshold value can be set, and if the ratio of the occupancy in the print area is smaller than the threshold value, it can be set to 0. The print area is, for example, an area corresponding to the size of the paper on which the image data is recorded.
[0034] The value calculated from the rectangular area size is the ratio of the rectangular area where the input color exists to the maximum rectangular size of the image data. The size of the rectangular area where the input color exists is obtained from the color-related information. Here too, a threshold value may be set, and if the ratio of the area to the print area is smaller than the threshold value, it may be set to 0. The maximum rectangular size is, for example, the size of the paper on which the image data is recorded.
[0035] The value calculated based on the location is a value calculated based on whether the rectangular area in which the input color exists is located within the area (paper edge area) represented by a threshold value in the printing area, and is explained below.
[0036] 9 is a diagram illustrating a process for determining how much a rectangular area in which an input color exists overlaps with an area whose start and end coordinates are represented by threshold values. Area 900 is, as an example, an area defined as the paper edge area in the X coordinate direction of the image data. Area 901 is, as an example, an area defined as the paper edge area in the Y coordinate direction of the image data. It is determined whether the X and Y start coordinates and the X and Y end coordinates of the rectangular area in which the input color exists belong to these areas, and if they do, 0.5 is added, and the total value is used to calculate the intra-page likelihood.
[0037] Image data 902 will be used as an example. Dotted line 906 is not image data, but is defined for ease of understanding to illustrate the paper edge region. The area outside the dotted line is the paper edge region. For input color 903, the X and Y coordinates of the start and end coordinates of the rectangular region in which the input color exists all belong to the paper edge region, so the total is 0.5 + 0.5 + 0.5 + 0.5 = 2.0. For input color 904, the X and Y coordinates of the start and end coordinates of the rectangular region in which the input color exists do not belong to the paper edge region, so the total is 0. For input color 905, the X coordinate of the start and end coordinates of the rectangular region in which the input color exists belongs to the paper edge region, but the Y coordinate does not belong to the paper edge region. Furthermore, neither of the end coordinates belong to the paper edge region. Therefore, the total is 0.5.
[0038] The three values obtained by the calculations above are multiplied to obtain the in-page likelihood for that input color. At this time, if there are multiple input colors with the same RGB values, the color information may be integrated before calculating the in-page likelihood, or the in-page likelihoods may be calculated individually and then added together. Furthermore, these values may be added rather than multiplied, or each value may be weighted.
[0039] In S603, the CPU 102 determines a target color for color variation suppression based on the intra-page likelihood for each input color obtained in S602. In this embodiment, the color with the highest intra-page likelihood is determined as the target color for color variation suppression. Multiple target colors for color variation suppression may be selected, or one may be determined based on priority. Depending on how the threshold value is set, there may be only input colors with an intra-page likelihood of 0. In such cases, no target color for color variation suppression may be determined. The CPU 102 stores information indicating which of the input colors are target colors for color variation suppression in the RAM 103 or the storage medium 104. After completing the above processing, the processing of FIG. 6 ends, and the process proceeds to S103.
[0040] In S103, the CPU 102 performs color conversion (gamut mapping) on the image data using color conversion information previously stored in the storage medium 104. Specifically, the color conversion information in this embodiment is, for example, a gamut mapping table, and gamut mapping is performed on the color information of each pixel of the image data. The image data after gamut mapping is stored in the RAM 103 or the storage medium 104. Specifically, for example, the gamut mapping table is a three-dimensional lookup table (3DLUT). The three-dimensional lookup table calculates a combination of output pixel values (Rout, Gout, Bout) for a combination of input pixel values (Rin, Gin, Bin). If the input values Rin, Gin, and Bin each have 256 gradations, for example, Table 1
[0256]
[0256]
[0256] [3] is used, which has a total of 16,777,216 sets of output values (256 x 256 x 256). Color conversion is performed using the gamut mapping table. Specifically, for example, the processes of equations (1) to (3) are executed for each pixel of an image made up of RGB pixel values of image data acquired from the document data input in S101.
[0041] Rout=Table1[Rin][Gin][Bin][0]...(1) Gout=Table1[Rin][Gin][Bin][1]...(2) Bout=Table1[Rin][Gin][Bin][2]...(3) Also, the number of grids in the lookup table may be reduced from 256 to, for example, 16, and the table size may be reduced by interpolating table values of a plurality of grids to determine the output value.
[0042] In S104, the CPU 102 creates a color degeneration corrected table based on the following information.
[0043] Image data acquired by S101 Image data after gamut mapping performed with S103 Gamut mapping table used in S103 Information on the target colors for color fluctuation suppression set in S102 The format of the color degeneration corrected table is the same as the format of the gamut mapping table. The process of creating the color degeneration corrected table in S104 will be described later.
[0044] In S105, the CPU 102 performs calculations on the image data acquired in S101 using the color degeneration correction table created in S104 to generate corrected image data that has undergone color degeneration correction. The generated corrected image data is stored in the RAM 103 or the storage medium 104.
[0045] In S106, the CPU 102 outputs the corrected image data stored in S105 from the image processing device 101 to the recording device 108 via the data transfer I / F 106. Thereafter, the processing in FIG. 3 ends.
[0046] The gamut mapping used in S103 may be mapping from the sRGB color space to the color reproduction gamut of the recording device 108. In this case, it is possible to suppress the reduction in saturation and color difference that would occur due to gamut mapping into the color reproduction gamut of the recording device 108. Alternatively, with emphasis on tone reproduction, it may be gamut reduction mapping from the sRGB color space to the color reproduction gamut of the recording device 108. In gamut reduction mapping, the white point and black point of the sRGB color space are mapped to the white point and black point of the color reproduction gamut of the recording device 108, respectively. Other colors are then converted so that their correlation with the white point and black point is maintained. Then, conversion is performed in a way that compresses saturation in the color direction so that the entire sRGB color space fits within the color reproduction gamut of the recording device 108.
[0047] The process of creating the table after color degeneration correction in S104 will be described with reference to Fig. 4. The process of Fig. 4 is realized, for example, by the CPU 102 reading a program stored in the storage medium 104 into the RAM 103 and executing it. The process of Fig. 4 may also be executed by the image processing accelerator 105.
[0048] In S201, CPU 102 detects a unique color to be subjected to color degeneration correction from the image data acquired in S101 (unique color detection process). The detection result is stored as a unique color list in RAM 103 or storage medium 104. The unique color list is initialized at the start of S201. The detection process is repeated for each pixel of the image data, and for all pixels included in the image data, it is determined whether the color of each pixel is different from any unique color detected up to that point. If it is determined to be a unique color, it is stored as a unique color in the unique color list.
[0049] The method involves determining whether the color of the target pixel is included in the unique color list. If not, new color information is added to the unique color list. This allows a list of unique colors included in the image data to be created. In the above example, for example, if the input image data is sRGB, each pixel has 256 gradations, and unique colors are detected from a total of 16,777,216 colors (256 x 256 x 256). This results in an enormous number of colors, slowing down processing speed. Therefore, unique colors can be detected discretely. For example, the 256 gradations can be reduced to 16 gradations before unique colors are detected. When reducing the number of colors, the color can be reduced to the color of the nearest grid. This allows unique colors to be detected from a total of 4,096 colors (16 x 16 x 16), for example, improving processing speed.
[0050] In S202, the CPU 102 detects the number of color degenerate combinations among the unique color combinations included in the image data based on the unique color list detected in S201.
[0051] Detecting the number of color combinations that are color degenerate will be described with reference to FIG. 5. Color gamut 401 is the color gamut of the input image data. Color gamut 402 is the color gamut after gamut mapping in S103. Color 403 and color 404 are colors included in the input image data. Color 405 is the color obtained when gamut mapping is performed on color 403. Color 406 is the color obtained when gamut mapping is performed on color 404. Color degeneration is determined when the color difference 408 between colors 405 and 406 is smaller than a predetermined color difference. In this embodiment, color degeneration is determined when the color difference 408 between colors 405 and 406 is smaller than the color difference 407 between colors 403 and 404. This determination process is repeated for the number of color combinations in the unique color list. The color difference is calculated using the Euclidean distance in the color space. In this embodiment, the Euclidean distance in the CIE-L*a*b* color space (hereinafter referred to as color difference ΔE) is used as a suitable example. Because the CIE-L*a*b* color space is a visually uniform color space, the Euclidean distance can approximate the amount of color variation. Therefore, humans perceive colors as closer together as the Euclidean distance in the CIE-L*a*b* color space decreases, and as the Euclidean distance increases, they perceive colors as farther apart. Color information in the CIE-L*a*b* color space is expressed in a color space with three axes: L*, a*, and b*. For example, color 403 is expressed as L403, a403, and b403. Color 404 is expressed as L404, a404, and b404. Color 405 is expressed as L405, a405, and b405. Color 406 is expressed as L406, a406, and b406. If the input image data is expressed in another color space, it is converted to the CIE-L*a*b* color space using known techniques. The color difference ΔE407 and the color difference ΔE408 are calculated by the formulas (4) and (5).
[0052] TIFF2026002623000002.tif21144...(4) TIFF2026002623000003.tif21144...(5) If the color difference ΔE408 is smaller than the color difference ΔE407, it is determined that color degeneration has occurred. Furthermore, it may also be determined that color degeneration has occurred if the color difference ΔE408 is not large enough to distinguish the color difference. This is because if the color 405 and the color 406 have a color difference that allows them to be distinguished as different colors based on human visual characteristics, it can be determined that there is no need to correct the color difference. An example of a color difference ΔE that allows colors to be distinguished as different based on visual characteristics is 2.0. In other words, it may also be determined that color degeneration has occurred if the color difference ΔE408 is smaller than the color difference ΔE407 and if the color difference ΔE408 is smaller than 2.0.
[0053] In S203, the CPU 102 determines whether the number of color combinations that have undergone color degeneration in S202 is zero. If it is determined that the number of color combinations that have undergone color degeneration is zero, the process proceeds to S204, where it is determined that the image data does not require color degeneration correction. Thereafter, the process of FIG. 4 ends. On the other hand, if it is determined that the number of color combinations that have undergone color degeneration is not zero, the process proceeds to S205.
[0054] Executing color degeneration correction results in color changes (color fluctuations). This causes color changes even in color combinations that are not color degenerated, resulting in unnecessary color changes. Therefore, the need for color degeneration correction may be determined based on the total number of unique color combinations and the number of color combinations that are color degenerated. Specifically, for example, it may be determined that color degeneration correction is necessary when the number of color combinations that are color degenerated is more than half of the total number of unique color combinations. This makes it possible to suppress the adverse effects of color changes caused by color degeneration correction.
[0055] In S205, the CPU 102 performs color degeneration correction on the color combination that causes color degeneration, based on the input image data, the image data after gamut mapping, and the gamut mapping table.
[0056] Color degeneration correction will be explained using FIG. 5. Color 403 and color 404 are input colors contained in the input image data. Color 405 is the color (destination color) after color 403 is converted by gamut mapping. Color 406 is the color after color 404 is converted by gamut mapping.
[0057] FIG. 5 shows that the color combination of colors 403 and 404 is color degenerated. Therefore, color degeneration can be corrected by increasing the color distance between colors 405 and 406. Specifically, correction processing is performed to increase the color distance between colors 405 and 406 beyond the distance at which they can be distinguished as different based on human visual characteristics. The color distance at which colors can be distinguished as different based on visual characteristics is a color difference ΔE of 2.0 or greater. More preferably, it is approximately the same as the color difference ΔE 407 between colors 405 and 406. The color degeneration correction processing is repeated for each combination of colors that are color degenerated. The results of the color degeneration correction are stored as a table, which associates color information before and after correction. In FIG. 5, the color information is in the CIE-L*a*b* color space. Therefore, the color space of the input image data and the output image data may be converted. In this case, the correspondence between the color information before correction in the color space of the input image data and the color information after correction in the color space of the output image data is stored as a table.
[0058] Next, the color degeneration correction process will be described. A color difference correction amount 409 that widens the color difference ΔE is calculated from the color difference ΔE 408. Because the color difference ΔE that can be recognized as a different color is 2.0 based on visual characteristics, the color difference correction amount 409 is the difference between the color difference ΔE 2.0 and the color difference ΔE 408 (2.0 - ΔE 408). Alternatively, to maintain the color differences of the input image data, the color difference correction amount 409 may be the difference between the color differences ΔE 407 and ΔE 408. The result of correcting color 405 by the color difference correction amount 409 on an extension of the line from color 406 to color 405 in the CIE-L*a*b* color space is color 410. Color 410 is separated from color 406 by the color difference ΔE 408 and the color difference correction amount 409. While the color difference ΔE 410 is on an extension of the line from color 406 to color 405 in the CIE-L*a*b* color space, this is not a limitation in this embodiment. As long as the color difference ΔE between color 406 and color 410 is equal to the color difference obtained by adding color difference ΔE 408 and color difference correction amount 409, the difference may be in any direction, including the lightness direction, saturation direction, or hue angle direction, in the CIE-L*a*b* color space. Furthermore, the difference may be in one direction or a combination of the lightness direction, saturation direction, and hue angle direction. Furthermore, while color degeneration was corrected by changing color 405 in the above example, color 406 may also be changed. Furthermore, both color 405 and color 406 may be moved. When changing color 406, because it cannot be moved outside the color gamut 402, color 406 is moved to the boundary surface of the color gamut 402. The missing color difference ΔE may be compensated for by changing color 405.
[0059] The above has described the case where neither the color 403 nor the color 404 is a target color for color variation suppression. However, if either the color 403 or the color 404 is a target color for color variation suppression set in S102 of Fig. 3, the following two correction control processes are performed in the above color degeneration correction process.
[0060] Color degeneration correction does not correct the target colors for color fluctuation suppression.
[0061] In color degeneration correction, colors that are not the target colors for color fluctuation suppression are corrected.
[0062] This prevents color fluctuations in the target colors for color variation suppression from occurring during color degeneration correction. In this embodiment, the above two processes are also referred to as color variation suppression processes. In this case, rather than not correcting the target colors for color variation suppression at all, the amount of correction may be limited to a predetermined range so that the color change is less noticeable to the user's eyes. This embodiment can reduce color degeneration in images that are adjacent to or close to an image composed of colors that are not the target colors for color variation suppression. In other words, it can reduce color degeneration, which occurs when sufficient color difference exists in the input image data but the color difference becomes insufficient as a result of gamut mapping processing. In addition, color degeneration correction is not performed (or is limited) on the target colors for color variation suppression, preventing color changes unexpected by the user.
[0063] In S206, CPU 102 creates a table after color degeneration correction by modifying the gamut mapping table (GMTBL) using the result of the color degeneration correction in S205. The gamut mapping table before modification is a table that converts the input color 403 into the output color 405. The result of the color degeneration correction in S205 is used to modify the table to convert the input color 403 into the output color 410, thereby creating a table after color degeneration correction. In this manner, a table after color degeneration correction can be created. The modification of the gamut mapping table described above is repeated for each combination of colors that will be color degenerated.
[0064] As described above, by applying the color degeneration correction table to input image data, the distance between colors in the input image data that are subject to color degeneration can be increased. As a result, color degeneration can be reduced for color combinations that are subject to color degeneration. Color degeneration occurs in conventional gamut mapping because, when the input image data is sRGB data, the gamut mapping table is created assuming that the entire input color space, i.e., the input image data contains 16,777,216 colors. Gamut mapping tables created under this assumption take into account the gradation and saturation of colors not included in the input image data. In this embodiment, colors present in the input image data can be detected and a gamut mapping table limited to only the colors present in the input image data can be created. This enables adaptive gamut mapping of the input image data, thereby reducing color degeneration appropriately. Furthermore, when the same color exists between unit areas, such as pages, that color is detected as a target color for color variation suppression, and when increasing the distance between colors to reduce color degeneration, changes to the target color for color variation suppression are suppressed. This makes it possible to prevent the same color from being recognized as a different color between unit areas.
[0065] In addition, by determining the target color for color variation suppression based on the intra-page likelihood calculated for each input color of the image data, it is possible to achieve consistent results for color reduction correction of the same color, even for different image data. As a result, it is possible to suppress color variations of the same color between different image data while maintaining the effect of reducing color reduction for other colors. For example, suppose that after performing the process of FIG. 3 on image data 700 in FIG. 7, input color 701 is the target color for color variation suppression, and after performing the process of FIG. 3 on image data 704 in FIG. 7, input colors 707 and 708 are the target colors for color variation suppression. In this case, since input colors 701, 707, and 708 are the same color, the results of color reduction correction for these colors are consistent. On the other hand, for the other input colors, the color differences within each image data are expanded by the color reduction correction described above, so the effect of color reduction correction is maintained.
[0066] In this embodiment, the gamut mapping table after color degeneration correction is applied to the input image data, but a correction table for performing color degeneration correction on the image data after gamut mapping may also be created. In this case, a correction table for converting pre-correction color information to corrected color information may be generated based on the results of the color degeneration correction in S205. The generated correction table is a table for converting color 405 to color 410 in FIG. 5. In S105, the generated correction table is applied to the image data after gamut mapping. As described above, the degree of color degeneration caused by gamut mapping can also be reduced by correcting the image data after gamut mapping.
[0067] In this embodiment, the processing for suppressing color variation due to color degeneration correction has been described. A table after color degeneration correction may also be dynamically created using a method different from that of this embodiment. As described above, in S102, target colors for color variation suppression are determined, and when a table after color degeneration correction is created according to the input color, color degeneration correction for the target colors for color variation suppression is suppressed. As a result, it is possible to obtain the effect of suppressing color variation for colors for which it is important that the hue be consistent between pages, while maintaining as much as possible the effect obtained as a result of dynamic color degeneration correction performed on image data.
[0068] [Second embodiment] The following describes the second embodiment, focusing on differences from the first embodiment. In the first embodiment, color-related information was acquired for each image data item, and intra-page likelihood was calculated based on the color-related information to determine target colors for color variation suppression. For example, consider manuscript data in which a theme color exists in a common position on all pages, while a specific page contains another input color that is larger than the theme color. In this case, depending on the results of the intra-page likelihood calculation, the theme color may not be determined as a target color for color variation suppression on a specific page. Therefore, in this embodiment, when processing manuscript data, color information, color-related information, and information on target colors for color variation suppression are carried over between pages. This makes it possible to determine target colors for color variation suppression based not only on the characteristics of each page but also on the characteristics common to the pages.
[0069] Fig. 10 is a flowchart showing the overall processing of the image processing device 101. The processing of Fig. 10 is realized, for example, by the CPU 102 reading a program stored in the storage medium 104 into the RAM 103 and executing it. The processing of Fig. 10 may also be executed by the image processing accelerator 105. Note that the same step numbers as in Fig. 3 are the same as in Fig. 3, and therefore their description will be omitted.
[0070] After S101, in S1001, CPU 102 determines whether the image data acquired in S101 is the first page of a document consisting of multiple pages. If it is determined that it is the first page, the process proceeds to S102. On the other hand, if it is determined that it is not the first page, the process proceeds to S1002.
[0071] In S1002, CPU 102 references the color variation suppression information (described later) of the previous page to determine the target color for color variation suppression. The processing of S1002 will be described later, but in this embodiment, in addition to the characteristics of the page currently being focused on, the color variation suppression information of the previous page is referenced to acquire characteristics common to the pages. Then, the target color for color variation suppression is determined based on both characteristics.
[0072] Once the target color for color variation suppression has been determined by the processing in S102 or S1002, the same processing as in the first embodiment is executed in S103 to S106. After S106, the process proceeds to S1003.
[0073] In S1003, the CPU 102 stores the color information, associated color information, and information on the target color for color variation suppression of the page currently being processed in the RAM 103 or the storage medium 104. Specifically, for example, as a result of performing the processing up to S106 on the image data 700 in Fig. 7, it is assumed that the input color 701 is determined to be the target color for color variation suppression. In this case, the RGB values of the input colors 701, 702, and 703, the associated color information, and information indicating that the input color 701 is the target color for color variation suppression, which are shown in the associated color information 800, are stored in S1003.
[0074] In this embodiment, in S1003, not only the information of the currently processed page but also the information of the previous page may be carried over and stored. Specifically, for example, the number of pixels included in the color-associated information of the currently processed page is maintained, while the number of pixels included in the color-associated information of the previous page is attenuated by 0.5 and stored as the color-associated information 800. In this case, if the number of pixels falls below a certain value, the color information is deleted from the color-associated information 800. In other words, the list of color-associated information represented by the color-associated information 800 is adjusted in S1003 by increasing the weight of color information of image data with a short inter-page distance and decreasing the weight of color information of image data with a long inter-page distance, with respect to the currently processed page. As a result, colors that appear throughout all pages remain in the color-associated information 800, while colors that appear only on specific pages continue to have a decreasing number of pixels and eventually disappear from the color-associated information 800. This makes it easier for colors that appear throughout all pages to be determined as target colors for color variation suppression by applying the inter-page likelihood described below. In the above description, the number of pixels is attenuated by 0.5 times. However, it is also possible to merge the number of pixels with the color-associated information of the previous page and average them. For example, it is also possible to calculate the average value with the number of pixels of the previous page. As a result, the number of pixels of colors that exist across pages is not attenuated, and the number of pixels of colors that do not exist across pages is halved. As a result, colors that exist across pages remain in the color-associated information 800 and are more likely to be determined as target colors for color variation suppression by applying the inter-page likelihood. On the other hand, from a certain page onwards, the number of pixels of non-existent colors continues to be halved and eventually reaches a pixel count below the threshold, so that the color ultimately disappears from the color-associated information 800. As a result, from a certain page onwards, colors that exist across pages are more likely to be determined as target colors for color variation suppression by applying the inter-page likelihood than non-existent colors. Although the above description uses the number of pixels, values obtained from color-associated information, such as the size and position of a rectangular area, may be used instead of the number of pixels. A calculated likelihood value may also be used.
[0075] Furthermore, information up to the previous page may not be stored (reset). The timing of resetting may be when the image data to be processed is the first page, when there is a blank page, or when the current page is monochrome. It may also be reset when a certain period of time has elapsed, regardless of the number of pages or division of the data to be processed. Alternatively, a combination of these conditions may be used. The information to be stored may also be color information alone. Furthermore, a histogram may be created using the same units as the grid units of the 3DLUT, and color-related information may be recorded therein. When mapping processing is performed using 3DLUT processing, even if the acquired color-related information has different values representing color, such as RGB values, they may be the same on the 3DLUT grid. Since the final unit for color variation suppression and color degeneration correction is the grid unit of the 3DLUT, treating the color-related information in the same units and calculating the likelihood may enable more efficient color variation suppression processing. Methods for converting the histogram of color-related information to grid units include, for example, summing the number of pixels or using the coordinates of the most extreme points among multiple points when calculating the rectangular area size.
[0076] Next, in S1004, CPU 102 determines whether the data currently being processed is the final page of the manuscript data. If it is determined that it is not the final page, the process returns to S101 and processes the next page. If it is determined that it is the final page, the process in FIG. 10 ends.
[0077] The processing of S1002 will now be described. Fig. 11 is a flowchart showing the processing of S1002. Note that the same step numbers as in Fig. 6 are the same as in Fig. 6, and so their description will be omitted. After S601 and S602, the process proceeds to S1101.
[0078] In S1101, the CPU 102 acquires color variation suppression information for the previous page. The information acquired here includes color information, color associated information, and information on target colors for color variation suppression for the previous page, on which color correction processing was performed and image data was output, and which was stored in the RAM 103 or storage medium 104 in S1003 when the processing of FIG. 10 was performed on a page previous to the page currently being processed. Next, in S1102, the CPU 102 calculates an inter-page likelihood based on the color associated information acquired in S601 and the color variation suppression information for the previous page acquired in S1101.
[0079] Here, the inter-page likelihood is a value for acquiring color features that cannot be acquired by the intra-page likelihood described in the first embodiment, and that are important for maintaining the same color tone across pages. Examples of such features include the same color existing in the same position across multiple pages, and the rectangular areas in which the color exists being similar in shape. The inter-page likelihood is calculated by acquiring such features from color-associated information and combining multiple values. In this embodiment, the inter-page likelihood is calculated by combining three values: a value calculated based on the location, a value calculated based on the similarity of shape, and a value calculated based on whether the color is the same as the previous page.
[0080] Furthermore, the inter-page likelihood is calculated only when the color information of the currently processed page and the previous page is the same or very close and is determined to be the same color. In other words, for colors that are not determined to be the same color on the currently processed page and the previous page, the inter-page likelihood is not calculated and the result is 0. Furthermore, as described above, the number of pixels continues to decrease and is deleted from the list, and the inter-page likelihood is also not calculated and the result is 0 for color information that was not stored in S1003.
[0081] The value calculated based on the existing position is a value that is obtained by comparing the start and end positions of the rectangular areas where the input color exists for the previous page and the currently processed page, and based on the comparison results. Specifically, for example, if the positions of the rectangular areas overlap, the value is set to 1.0, and if not, the value is set to 0. Here, it is also possible to calculate a continuous value by calculating the area of overlap.
[0082] The value calculated based on shape similarity is a value obtained by comparing the shapes of the rectangular areas where the input color exists between the previous page and the currently processed page, and based on the comparison results. Specifically, for example, the aspect ratio of the rectangular area is calculated for each of the previous page and the currently processed page, and the smaller value is divided by the larger value. Next, the length of the rectangular area in the X-axis direction and the length of the Y-axis direction are calculated for each of the previous page and the currently processed page, and the smaller value for each of the X-axis direction and the Y-axis direction is divided by the larger value. This is because dividing by the larger value makes the maximum value 1.0. These three values are then multiplied to obtain the value calculated based on shape similarity. If all three values match between the previous page and the currently processed page, the result is 1.0 x 1.0 x 1.0 = 1.0.
[0083] The value calculated based on whether the color was a retained color on the previous page is a value calculated based on whether the color being focused on on the currently processed page was a target color for color fluctuation suppression on the previous page. If it was a target color for color fluctuation suppression, the value is 1.0, and if not, the value is 0.
[0084] The three values obtained by the calculations above are added together to obtain the inter-page likelihood for that input color. At this time, if there are multiple input colors with the same RGB values, the color information may be integrated before calculating the inter-page likelihood, or the inter-page likelihoods may be calculated individually and then added. Furthermore, these values may be multiplied rather than added, or each value may be weighted.
[0085] In S1103, the CPU 102 calculates a total likelihood based on the intra-page likelihood and inter-page likelihood for each input color obtained in S602 and S1102. Here, the two values may be added or multiplied, or may be weighted and added together.
[0086] After S1103, in S603, the CPU 102 determines a target color for color variation suppression based on the overall likelihood for each input color obtained in S1103. In this embodiment, the color with the largest overall likelihood is determined as the target color for color variation suppression. Multiple target colors for color variation suppression may be determined, or one may be determined based on priority. Depending on how the threshold value is set, there may be only input colors whose overall likelihood is 0. In such cases, no target color for color variation suppression is determined. Information indicating which of the input colors is the target color for color variation suppression is stored in the RAM 103 or the storage medium 104. After S603, the processing of FIG. 11 ends, and the processing proceeds to S103 of FIG. 10.
[0087] Through the above process, inter-page likelihoods are calculated in addition to the intra-page likelihoods described in the first embodiment, and target colors for color variation suppression are determined based on these. Color variation suppression processing is then performed. As a result, even for different image data, colors with the same characteristics, for example, colors with characteristics common between pages, are more likely to be determined as target colors for color variation suppression, resulting in the same results for color reduction correction. As a result, it is possible to suppress color variations for the same color in input between different image data while maintaining as much of the color reduction reduction effect as possible for other colors.
[0088] In this embodiment, color associated information is inherited from different image data (i.e., the previous page) in the original data that has already been color corrected and output, and color variation suppression information is stored in S1003. Here, S105 and S106 may be separate flows, and image data for which information for color reduction correction has been determined may be the target for acquiring color associated information. Also, different image data in the original data that has not been subjected to color reduction correction may be the target for acquiring color associated information. Also, image data in different original data may be the target for acquiring color associated information. These may also be combined. By acquiring color associated information from different image data that has not been subjected to color reduction correction, colors commonly used in the original data can be more easily determined as target colors for color variation suppression. Furthermore, by acquiring color associated information from image data in different original data, it is possible to suppress color variations of the same color in the input, even between different original data, while maintaining as much color reduction reduction effect as possible for other colors.
[0089] So far, we have explained the process of determining target colors for color variation suppression using both intra-page likelihood and inter-page likelihood, and suppressing color variation of the same color in the input. However, even with a process that does not acquire color-related information or determine target colors for color variation suppression, it is possible to suppress color variation of the same color in the input by inheriting the color information of the previous page.
[0090] 12 is another flowchart showing the overall processing of the image processing device 101. Note that the same step numbers as in FIG. 10 are the same as in FIG. 10, and therefore their explanation will be omitted. After S101, the determination of S1001 is executed. If it is determined in S1001 that the image data acquired in S101 is the first page of a document consisting of multiple pages, the process proceeds to S103. Then, after S103, the process proceeds to S1203.
[0091] In S1203, the CPU 102 creates a color degeneration corrected table based on the following information.
[0092] Image data acquired by S101 Image data after gamut mapping performed with S103 Gamut mapping table used in S103 The process of creating the table after color degeneration correction in S1203 is the same as the process of creating the table after color degeneration correction in S104 when there is no target color for color variation suppression. After S1203, proceed to S105. On the other hand, if it is determined in S1001 that the image data acquired in S101 is not the first page of a document consisting of multiple pages, proceed to S1201.
[0093] In S1201, the CPU 102 performs gamut mapping on the color information that combines the color information of the currently processed page and the color information of the previous page. Specifically, for example, if the previous page has input colors A, B, and C and the current page has input colors B and C, the CPU 102 performs gamut mapping assuming that the current page has input colors A, B, and C.
[0094] In S1202, the CPU 102 creates a color degeneration corrected table based on the following information.
[0095] Image data input in S101 (i.e., the page currently being processed) Color information on the previous page Image data after gamut mapping performed with the S1201, including color information for both the current page and the previous page Gamut mapping table used in S1201 Note that the gamut mapping table used in S1201 is the same as the gamut mapping table used in S103. Regarding the process of creating a table after color degeneration correction in S1202, differences from S104 will be described. First, in S201, the color information of the previous page is added to the color information of the image data acquired in S101 (i.e., the page currently being processed) to detect a unique color. That is, processing is performed as if the color of the previous page exists in the page currently being processed. In the above example, input color A does not exist in the page currently being processed, but processing is performed as if input color A does exist. Next, the color information of the previous page is added to the color information of the page currently being processed, and processing in S202 is performed. The subsequent processing is similar to the flow of the process of creating a table after color degeneration correction in S104 when there is no target color for color variation suppression.
[0096] After the process of S1202 or S1203, the processes of S105 and S106 are executed.
[0097] After S106, in S1204, the CPU 102 stores the color information included in the image data acquired in S101 in the RAM 103 or the storage medium 104. After S1204, the process of S1004 is performed.
[0098] As described above, according to this embodiment, color variation suppression processing is performed based not only on information about the currently processed page but also on information about the previous page. This makes it easier for colors with the same characteristics, even in different image data, such as colors with characteristics common between pages, to be targeted for color variation suppression based on the inter-page likelihood. As a result, it becomes possible to suppress color variations of the same colors in the input between different pages while maintaining the color degeneration reduction effect as much as possible for other colors.
[0099] [Third embodiment] The third embodiment will be described below, focusing on the differences from the first and second embodiments. In the first and second embodiments, the target color for color variation suppression was determined from color accompanying information. However, even if the user desires a color for color variation suppression, it may not be determined as the target color for color variation suppression depending on the configuration of the image data. In this embodiment, the user is allowed to directly set the target color for color variation suppression. This allows the user to specify the color desired as the target color for color variation suppression.
[0100] Fig. 13 is a flowchart showing the overall processing of the image processing device 101. The processing of Fig. 13 is realized, for example, by the CPU 102 reading a program stored in the storage medium 104 into the RAM 103 and executing it. The processing of Fig. 13 may also be executed by the image processing accelerator 105. Note that the same step numbers as in Fig. 3 are the same as in Fig. 3, and therefore their description will be omitted.
[0101] After S101, the process proceeds to S1302. In S1302, the CPU 102 acquires color-associated information and information on target colors for color variation suppression designated by the user. Then, based on the color-associated information and the information on target colors for color variation suppression designated by the user, the CPU 102 determines the target colors for color variation suppression and generates color variation suppression information.
[0102] Fig. 14 is a flowchart showing the processing of S1302. Note that the same step numbers as in Fig. 6 are the same as in Fig. 6, and therefore their explanation will be omitted. After S601 and S602, the process proceeds to S1401.
[0103] In S1401, the CPU 102 acquires information about a target color for color variation suppression designated by the user. The designation of a target color for color variation suppression by the user will be described later. In S1401, the CPU 102 compares the information about the target color for color variation suppression designated by the user with the color information of the page currently being processed, and if the color information of the page currently being processed contains information about the target color for color variation suppression designated by the user, the CPU 102 sets the intra-page likelihood of that color to a value exceeding the maximum value that can be calculated.
[0104] For example, suppose that the in-page likelihood is calculated as the product of three values: a value calculated based on the number of pixels, a value calculated based on the rectangular area size, and a value calculated based on the location. Here, the calculation method for each value is specified as follows, for example.
[0105] The number of pixels is 0 if it is less than the threshold, and +1 is added if it is greater than or equal to the threshold.
[0106] The rectangular area size is 0 if it is less than the threshold, and +1 is added if it is equal to or greater than the threshold.
[0107] If the X and Y coordinates of the start coordinates and the X and Y coordinates of the end coordinates of the rectangular area where the input color exists belong to the paper edge area, add +0.5 to the existing position.
[0108] In this embodiment, the intra-page likelihood of the target color for color variation suppression specified by the user is set to a value exceeding the maximum value that can be calculated. For example, if the maximum value that can be calculated in the above case is calculated as (1 + 1) × (1 + 1) × (1 + 0.5 + 0.5 + 0.5 + 0.5) = 12, the value 13, which exceeds the maximum value, is set as the intra-page likelihood of the target color for color variation suppression specified by the user.
[0109] Next, in S603, the CPU 102 determines a target color for color variation suppression based on the calculated intra-page likelihood. Since the intra-page likelihood set for the color information specified by the user in S1401 is the maximum value, the color specified by the user is always determined as the target color for color variation suppression. The subsequent processing is the same as in the first embodiment.
[0110] 15 is a diagram showing an example of a user interface screen for receiving settings of target colors for color variation suppression from the user. A setting screen 1501 for setting target colors for color variation suppression includes an area 1502 and an area 1503. The area 1502 is an area for displaying a list of target colors for color variation suppression.
[0111] The list of target colors for color variation suppression displays a list of target colors for color variation suppression registered by the user. The list of target colors for color variation suppression includes color names and color values (R value, G value, B value). In the example shown in FIG. 15, two colors are registered: C Red (R value = R01, G value = G01, B value = B01) and F Green (R value = R01, G value = G01, B value = B01). The list of target colors for color variation suppression also includes a color retention (ON / OFF) setting for selecting whether or not to retain registered colors when printing. In the example shown in FIG. 15, the setting state for C Red is set to retain (ON), and for F Green is set to not retain (OFF). Note that "retain when printing" means that the color is to be targeted for color variation suppression.
[0112] Area 1503 is an area where the user can edit the list of target colors for color variation suppression. Fig. 15 shows a state in which the user has pressed the "Register" button in area 1502, which displays the list of target colors for color variation suppression, in order to register the third color. A black square in the figure indicates that the button has been pressed, and a white square indicates that it can be pressed.
[0113] Area 1503 displays an area for inputting and registering the color name and color values (R value, G value, B value). After the user has entered the necessary information in this area, the third color will be registered by pressing the "Register" button from the "Register / Delete" selection on the left side. If the "Delete" button is pressed, the third color will not be registered. Area 1503 is also used to update or delete the registered information for "C Red" and "F Green" that have already been registered. For example, to update or delete the registered information for "C Red," area 1503 is displayed by pressing the "C Red" portion of the color name. In this state, if "Delete" in area 1503 is pressed, the registered information for "C Red" will be deleted.
[0114] Fig. 16 is a diagram showing a state in which a button for specifying a color as a target color for color variation suppression has been pressed on the setting screen 1501 in Fig. 15. As an example, Fig. 16 shows a state in which the user has pressed a button displaying "OFF" to set whether "F Green," registered as the second color, should be specified as a target color for color variation suppression during printing.
[0115] An area 1601 is displayed on the setting screen 1501. Area 1601 is displayed so that ON / OFF can be selected. If the user selects "ON" in area 1601, color retention for "F green" is set to "ON." On the other hand, if the user selects "OFF," color retention for "F green" remains "OFF."
[0116] 17 is a diagram showing another example of a user interface screen for receiving settings of target colors for color variation suppression from the user. A setting screen 1701 for setting target colors for color variation suppression includes an area 1702, a page switching button 1703, and an area 1705. The area 1702 is an area for displaying an image of the manuscript data. If the manuscript data consists of multiple pages, the page switching button 1703 is also displayed. The user can switch the page displayed in the area 1702 by pressing the page switching button 1703. The area 1705 is an area for displaying a list of target colors for color variation suppression.
[0117] The user moves cursor 1704 in area 1702 and presses the color for which the user desires to suppress color variation on the document image displayed in area 1702. When the user presses a color, the corresponding color is registered in area 1705. Furthermore, when the user presses the "Delete" button displayed in area 1705, the registered color is deleted.
[0118] As described above, when a target color for color variation suppression is set on the screens of Figures 15 to 17, information on the target color for color variation suppression specified by the user is acquired in S1401, and the target color for color variation suppression can be determined.
[0119] [Fourth embodiment] The fourth embodiment will be described below, focusing on differences from the first to third embodiments. In the first embodiment, color degeneration correction is performed for each single color. Therefore, although the degree of color degeneration is reduced depending on the combination of colors in the input image data, a change in color tone may occur. Specifically, when color degeneration correction is performed on two colors with different hue angles, if the color is changed by changing the hue angle, the color tone will differ from the color tone in the input image data. For example, if color degeneration correction is performed on blue and purple by changing the hue angle, the purple will turn red. If the color tone changes, the user may be reminded of a device problem such as poor ink ejection.
[0120] Furthermore, in the first embodiment, when color degeneration correction is performed, the color degeneration correction is repeated for each unique color combination in the input image data. This ensures that the distance between colors can be increased. However, if the input image data contains a large number of unique colors, changing a color to increase the distance between the colors may result in a smaller distance between the colors relative to other unique colors. Therefore, the CPU 102 must repeatedly perform color degeneration correction in step S205 to ensure that the expected distance between colors is achieved for all unique color combinations in the input image data. The processing required to increase the distance between colors is enormous, resulting in increased processing time. In this embodiment, when color degeneration correction is performed, multiple unique colors are treated as a single color group for each specified hue angle and the color degeneration correction is performed in the same correction direction. To correct multiple unique colors as a single color group, a reference unique color is selected from the color group. By limiting the correction direction to the lightness direction, color variations can be suppressed. Correcting multiple unique colors as a single color group eliminates the need to process all color combinations in the input image data, thereby reducing processing time. First, an example will be described in which none of the colors to be processed are colors that are subject to color variation suppression. A case in which the colors to be processed include colors that are subject to color variation suppression will be described later.
[0121] FIG. 18 is a schematic diagram illustrating the color degeneration determination process of S202 in this embodiment, showing two axes, the a* and b* axes, in a CIE-L*a*b* color space, in a plane. A hue range 1801 represents a range in which multiple unique colors within a specific hue angle form one color group. In FIG. 18, a 360-degree hue angle is divided into six equal parts, so the hue angle is divided into 60-degree increments, and the hue range 1801 represents a range from 0 to 60 degrees. A hue range that can be recognized as the same color is preferable. For example, a hue angle in the CIE-L*A*B* color space ranges from 30 to 60 degrees. A 60-degree hue angle can separate six colors: red, green, blue, cyan, magenta, and yellow. A 30-degree hue angle can also separate colors between the 60-degree intervals. A fixed hue range, as shown in FIG. 18, may be determined. Alternatively, the number may be determined based on unique colors contained in the input image data. The CPU 102 detects the number of color combinations that are color-degenerated within the hue range 1801 for the unique color combinations contained in the input image data through the above-described process. In FIG. 18, colors 1804, 1805, 1806, and 1807 represent input colors. In FIG. 18, the CPU 102 determines whether color degeneration occurs for the four color combinations of colors 1804, 1805, 1806, and 1807. This process is repeated for all hue ranges. This allows the number of color combinations that are color-degenerated to be detected for each hue range. In FIG. 18, the number of six color combinations that are color-degenerated is detected. In this embodiment, the hue ranges are set every 60 degrees of hue angle, but this is not a limitation. For example, the hue ranges may be set every 30 degrees of hue angle, or the hue ranges may be set without dividing equally. Preferably, the hue ranges are set to a range of hue angles that provides visual uniformity. Since colors in the same color group are visually perceived as the same color, color degeneration correction can be performed on the same color. Furthermore, the number of color combinations that are color degenerated may be detected in two hue ranges, including adjacent hue ranges, for each hue range. Alternatively, the number of color combinations that are color degenerated may be detected in hue ranges that are shifted by 30 degrees each in a 60-degree hue range.In this case, the result of the immediately previous hue range can be reflected, so that color degeneration correction can be performed more reliably.
[0122] FIG. 19 is a schematic diagram illustrating the color degeneration correction processing of S205 in this embodiment. FIG. 19 is a diagram illustrating two axes, the L* axis and the C* axis, in the CIE-L*a*b* color space, on a plane. L* represents lightness, and C* represents saturation. In FIG. 19, colors 1901, 1902, 1903, and 1904 are input colors. Colors 1901, 1902, 1903, and 1904 represent colors that fall within the hue range 1801 in FIG. 18. Color 1905 is the color obtained after color 1901 has been converted using gamut mapping. Color 1906 is the color obtained after color 1902 has been converted using gamut mapping. Color 1907 is the color obtained after color 1903 has been converted using gamut mapping. The color obtained after color conversion using gamut mapping for color 1904 is the same color.
[0123] First, the CPU 102 determines a unique color that will be used as the reference for the color degeneration correction process for each hue range. As a preferred example, the CPU 102 determines the maximum lightness color, the minimum lightness color, and the maximum saturation color as the reference colors. In Figure 19, color 1901 is the maximum lightness color, color 1902 is the minimum lightness color, and color 1903 is the maximum saturation color.
[0124] Next, the CPU 102 calculates the correction factor R from the number of unique color combinations and the number of color-degenerated combinations in each hue range. An example of the calculation formula is shown below.
[0125] Correction factor R = number of degenerate color combinations / number of unique color combinations (6) The correction factor R decreases when the number of color combinations that are color-degenerated is small, and increases when the number is large. As described above, the more color combinations that are color-degenerated, the stronger the color-degeneration correction can be applied. FIG. 19 shows that there are four colors within the hue range 1801 in FIG. 18. Therefore, there are six unique color combinations. Of these, four combinations are color-degenerated. The correction factor in this case is 0.667. In FIG. 19, all combinations are color-degenerated by gamut mapping. However, even after gamut mapping, if the difference is greater than the minimum distinguishable color difference, the color is not considered to be color-degenerated. Therefore, the combinations of color 1904 and color 1903 and color 1904 and color 1902 are not considered to be color-degenerated. Here, the minimum distinguishable color difference ΔE is assumed to be 2.0, for example.
[0126] Next, the CPU 102 calculates a correction amount for each hue range from the correction rate R and the color information for the maximum lightness color, minimum lightness color, and maximum saturation color. The correction amounts are calculated as a correction amount Mh for the side brighter than the maximum saturation color and a correction amount Ml for the side darker than the maximum saturation color. The color 1901, which is the maximum lightness color, is represented as L1901, a1901, and b1901. The color 1902, which is the minimum lightness color, is represented as L1902, a1902, and b1902. The color 1903, which is the maximum saturation color, is represented as L1903, a1903, and b1903. The preferred correction amount Mh is the value obtained by multiplying the color difference ΔE between the maximum lightness color and the maximum saturation color by the correction rate R. The preferred correction amount Ml is the value obtained by multiplying the color difference ΔE between the maximum saturation color and the minimum lightness color by the correction rate R. The correction amounts Mh and Ml are calculated by the formulas (7) and (8).
[0127] TIFF2026002623000004.tif21144...(7) TIFF2026002623000005.tif21144...(8) As described above, the color difference ΔE to be retained after gamut mapping can be calculated. The color difference ΔE to be retained after gamut mapping is the color difference ΔE before gamut mapping. In FIG. 19, the correction amount Mh is the value obtained by multiplying the color difference 1908 by the correction factor R, and the correction amount Ml is the value obtained by multiplying the color difference ΔE 1909 by the correction factor R. Furthermore, if the color difference ΔE before gamut mapping is larger than the minimum distinguishable color difference, the color difference ΔE to be retained only needs to be larger than the minimum distinguishable color difference ΔE. By processing in this manner, the color difference ΔE reduced by gamut mapping can be restored to a distinguishable color difference ΔE. Furthermore, the color difference ΔE to be retained may be the color difference ΔE before gamut mapping. In this case, the ease of distinction can be made closer to that before gamut mapping. Furthermore, the color difference ΔE to be retained may be larger than the color difference before gamut mapping. In this case, the distinction can be made easier than before gamut mapping.
[0128] Next, the CPU 102 generates a color degeneration correction table for each hue range. The color degeneration correction table is a correction table for expanding lightness in the lightness direction based on the lightness of the maximum saturation color, the correction amount Mh, and the correction amount Ml. In FIG. 19, the lightness of the maximum saturation color is the lightness L1903 of color 1903. The correction amount Mh is the color difference ΔE1908. The correction amount Ml is the color difference ΔE1909.
[0129] A method for creating a table that extends brightness in the brightness direction will be described below.
[0130] The correction table that expands lightness in the lightness direction is 1DLUT. The input is the lightness before correction, and the output is the lightness after correction. The lightness after correction is determined by three points: the minimum lightness after correction, the lightness of the maximum saturation color after gamut mapping, and the maximum lightness after correction. The maximum lightness after correction is the lightness obtained by adding a correction amount Mh to the lightness of the maximum saturation color after gamut mapping. The minimum lightness after correction is the lightness obtained by subtracting a correction amount Ml from the lightness of the maximum saturation color after gamut mapping. The table that expands lightness in the lightness direction is created by linearly changing the minimum lightness after correction to the lightness of the maximum saturation color after gamut mapping, and linearly changing the lightness of the maximum saturation color after gamut mapping to the maximum lightness after correction. In Figure 19, the maximum lightness before correction is lightness L1905 of color 1901, which is the maximum lightness color. The minimum lightness before correction is lightness L1906 of color 1902, which is the minimum lightness color. The lightness of the maximum saturation color after gamut mapping is the lightness L1907 of color 1907. The maximum lightness after correction is lightness L1910, which is obtained by adding color difference ΔE 1908, which is the correction amount Mh, to lightness L1907. The minimum lightness after correction is lightness L1911, which is obtained by subtracting color difference 1909, which is the correction amount Ml, from lightness L1907. FIG. 21 shows a correction table for expanding lightness in the lightness direction in FIG. 19. In this embodiment, as a suitable example, color degeneration correction is performed by converting color difference ΔE to lightness difference. Visual sensitivity is high for lightness difference. Therefore, by converting saturation difference to lightness difference, even a small lightness difference can be perceived as having a color difference ΔE. Furthermore, in the sRGB color gamut and the color gamut of the recording device 108, lightness difference is smaller than saturation difference. Therefore, converting to lightness difference allows for effective use of the narrow color gamut. Note that the lightness of the most saturated color is not changed in order to maintain its visual appeal. In this way, by leaving the most saturated color unchanged, it is possible to correct the color difference ΔE while maintaining saturation. Correction of values greater than the maximum lightness and less than the minimum lightness does not need to be set, as these are not included in the input image data. However, when using a supplementary correction table, values greater than the maximum lightness and less than the minimum lightness are also referenced, so it is preferable to set values that result in a linear change, as shown in Figure 21.As described above, the capacity of the correction table can be reduced by reducing the number of grids, and the processing time required for transferring the correction table can be reduced.
[0131] Furthermore, if the maximum lightness after correction exceeds the maximum lightness of the color gamut after gamut mapping, the CPU 102 performs maximum value clipping. Maximum value clipping subtracts the difference between the maximum lightness after correction and the maximum lightness of the color gamut after gamut mapping across the entire correction table. In this case, the lightness of the most saturated color after gamut mapping is also shifted toward lower lightness. In this way, if the unique colors in the input image data are biased toward the high lightness side, the color difference ΔE can be expanded by also utilizing lightness gradation on the low lightness side. Furthermore, if the minimum lightness after correction is lower than the minimum lightness of the color gamut after gamut mapping, the CPU 102 performs minimum value clipping. Minimum value clipping adds the difference between the minimum lightness after correction and the minimum lightness of the color gamut after gamut mapping across the entire correction table. In this way, if the colors in the input image data are biased toward the low lightness side, color degeneration can be reduced by also utilizing lightness gradation on the high lightness side.
[0132] Next, CPU 102 applies the correction tables created for each hue range to the gamut mapping table. First, it determines which hue angle correction table to apply based on the color information contained in the gamut mapping output value. For example, if the hue angle of the gamut mapping output value is 25 degrees, it applies the correction table for hue range 1801 in FIG. 18. Then it applies the determined correction table to the output value of the gamut mapping table to correct it. The corrected color information is used as the new output value after gamut mapping.
[0133] As described above, by applying the correction table created based on the reference color to colors other than the reference color, the correction direction is limited to the lightness direction, thereby suppressing changes in color tone. Furthermore, there is no need to perform color degeneration correction processing for all unique color combinations contained in the input image data, thereby reducing processing time.
[0134] Furthermore, correction tables for adjacent hue ranges may be blended depending on the hue angle of the gamut mapping output value. For example, if the hue angle of the gamut mapping output value is Hn degrees, the color degeneration correction table for hue range 1801 is blended with the correction table for hue range 1802. Specifically, the lightness value of the output value after gamut mapping is corrected using the correction table for hue range 1801 to obtain lightness value Lc1801. The lightness value of the output value after gamut mapping is corrected using the correction table for hue range 1802 to obtain lightness value Lc1802. H1801 is the angle of the intermediate hue angle of hue range 1801, and H1802 is the angle of the intermediate hue angle of hue range 1802. According to each hue angle, the corrected lightness value Lc1801 and the corrected lightness value Lc1802 are interpolated using the hue angle of the output value after gamut mapping. The calculation formula is as follows:
[0135] TIFF2026002623000006.tif23145...(9) As described above, by blending the correction tables to be applied depending on the hue angle, it is possible to reduce the abrupt change in correction strength when the hue angle changes.
[0136] If the color space of the corrected color information differs from the color space of the output value after gamut mapping, the color space is converted to the output value after gamut mapping. For example, if the color space of the corrected color information is the CIE-L*a*b* color space, it is converted to the output value after gamut mapping.
[0137] Furthermore, if the corrected value exceeds the color gamut after gamut mapping, it is mapped to the color gamut after gamut mapping. The preferred mapping method is minimum color difference mapping that prioritizes lightness and hue. Minimum color difference mapping that prioritizes lightness and hue calculates the color difference ΔE using the following formula. Let Ls, as, and bs be the color information of colors that exceed the color gamut in the CIE-L*a*b* color space. Let Lt, at, and bt be the color information of colors within the color gamut after gamut mapping. Let ΔL be the lightness difference, ΔC be the saturation difference, and ΔH be the hue difference. Let Wl be the lightness weight, Wc be the saturation weight, Wh be the hue angle weight, and ΔEw be the weighted color difference.
[0138] TIFF2026002623000007.tif23145...(10) TIFF2026002623000008.tif1972...(11) TIFF2026002623000009.tif19106...(12) ΔH=ΔE-(ΔL+ΔC) (13) ΔEw=Wl×ΔL+Wc×ΔC+Wh×ΔH (14) Because the color difference ΔE has been extended in the lightness direction, color degeneration correction can be performed more accurately by mapping with more emphasis on lightness than saturation. In other words, the lightness weight Wl is greater than the saturation weight Wc. Furthermore, because hue has a large effect on color tone, mapping with more emphasis on hue than both lightness and saturation can minimize changes in color tone before and after correction. In other words, the hue weight Wh is greater than or equal to the lightness weight Wl and greater than the saturation weight Wc. As described above, the color difference ΔE can be corrected while maintaining color tone. Furthermore, the color space may be converted when performing color difference minimum mapping.
[0139] It is known that in the CIE-L*a*b* color space, color changes in the saturation direction do not result in a constant hue. Therefore, if the hue angle change is suppressed by increasing the weight of the hue, the color may not be mapped to a constant hue. Therefore, it is possible to convert to a color space in which the hue angle is bent so that color changes in the saturation direction result in a constant hue.
[0140] As described above, even when weighted color difference minimum mapping is performed, changes in color can be suppressed. In Fig. 19, color 1905, which is the result of gamut mapping of color 1901, is corrected to color 1912 using the correction table. Because color 1912 exceeds the color gamut 1916 after gamut mapping, it is mapped to color gamut 1916. In other words, color 1912 is mapped to color 1914. As a result, in the corrected gamut mapping table, if the input is color 1901, the output will be color 1914.
[0141] Up to now, the color degeneration correction process of S205 has been described with reference to FIGS. 19 and 21 for the case where none of the colors to be processed are the target colors for color variation suppression.
[0142] Next, a case where a color that is a target for color variation suppression is present among the colors to be processed will be described. Fig. 20 is a diagram that explains a case where a color that is a target for color variation suppression is present among the colors to be processed in the color degeneration correction process of S205. Fig. 20 is the same as Fig. 19 in the following respects, so a description thereof will be omitted.
[0143] Minimum brightness color 2002 in Figure 20 = Minimum brightness color 1902 in Figure 19 Maximum saturation color 2003 in Figure 20 = Maximum saturation color 1903 in Figure 19 Color 2004 in Figure 20 = Color 1904 in Figure 19 Color gamut 2016 in Figure 20 = Color gamut 1916 in Figure 19 The maximum lightness color is color 2001 in FIG. 20, which exists within color gamut 2016 and is the target color for color variation suppression.
[0144] First, the CPU 102 calculates a correction factor R for each hue range from the number of unique color combinations and the number of color-degenerated color combinations in the target hue range using equation (15).
[0145] Correction factor R = number of degenerate color combinations / number of unique color combinations (15) In FIG. 20, as in FIG. 19, the correction factor R is calculated as R=0.667.
[0146] Next, CPU 102 calculates correction amounts Mh and Ml for each hue range from the correction factor R and color information for the maximum lightness color, minimum lightness color, and maximum saturation color using equations (16) and (17), as in Figure 19. Color 2001, which is the maximum lightness color, is expressed as L2001, a2001, and b2001. Color 2002, which is the minimum lightness color, is expressed as L2002, a2002, and b2002. Color 2003, which is the maximum saturation color, is expressed as L2003, a2003, and b2003.
[0147] TIFF2026002623000010.tif15145...(16) TIFF2026002623000011.tif15145...(17) Next, the CPU 102 generates a color degeneration correction table for each hue range. In Fig. 20, the lightness of the maximum saturation color is the lightness L2003 of the color 2003. The correction amount Mh is the color difference ΔE2008. The correction amount Ml is the color difference ΔE2009.
[0148] In FIG. 19, the brightness is expanded around color 1903, which is the color with the highest saturation. In FIG. 20, however, color 2001, which is the color with the highest brightness, is the target color for color variation suppression, so the brightness is expanded around color 2001.
[0149] The maximum lightness before correction is the lightness L2005 of the maximum lightness color, color 2001. The minimum lightness before correction is the lightness L2006 of the minimum lightness color, color 2002. The lightness of the maximum saturation color before correction is the lightness L2007 of color 2003.
[0150] FIG. 22 shows a correction table for expanding lightness in the lightness direction in FIG. 20. The lightness of the maximum lightness color after gamut mapping remains unchanged at lightness L2005 of color 2001. The lightness of the maximum saturation color after correction is lightness L2010, which is obtained by subtracting color difference ΔE2008, which is the correction amount Mh, from lightness L2005. The minimum lightness after correction is lightness L2011, which is obtained by subtracting color difference 2009, which is the correction amount Ml, from lightness L2010. As described above, by expanding lightness centered on the color targeted for color variation suppression, it is possible to reduce the degree of color degeneration while suppressing color correction of the color targeted for color variation suppression. For simplicity's sake, the above description deals with the case where the color targeted for color variation suppression is the maximum lightness color. Below, we will explain the cases where the color targeted for color variation suppression has a lightness between the maximum lightness color and the maximum saturation color, and between the minimum lightness color and the maximum saturation color.
[0151] When the target color for color variation suppression has a lightness between the maximum lightness color and the maximum saturation color, the creation of a correction table for expanding the lightness will be described.
[0152] First, the correction table of Fig. 21 is created based on the color 1901 which is the maximum lightness color, the color 1902 which is the minimum lightness color, and the color 1903 which is the maximum saturation color. Then, the correction table of Fig. 21 is shifted to a position where the lightness 2301 (shown in Fig. 23(a)) of the color targeted for color variation suppression is not changed after correction.
[0153] Fig. 23(a) shows the result (graph B) of shifting the correction table (graph A) of Fig. 21 downward to position C where the lightness 2301 of the target color for color variation suppression remains unchanged after correction. As shown in Fig. 23(a), the lightness 2301 of the target color for color variation suppression remains unchanged even after correction. Therefore, it is possible to expand the lightness in the lightness direction while eliminating any change in the lightness of the target color for color variation suppression.
[0154] Next, a description will be given of how to create a correction table for expanding the lightness when the target color for color variation suppression has a lightness between the minimum lightness color and the maximum saturation color.
[0155] First, the correction table of Fig. 21 is created based on the color 1901 which is the maximum lightness color, the color 1902 which is the minimum lightness color, and the color 1903 which is the maximum saturation color. Then, the correction table of Fig. 21 is shifted to a position where the lightness 2302 (shown in Fig. 23(b)) of the color targeted for color variation suppression is not changed after correction.
[0156] Fig. 23(b) shows the result (graph D) of shifting the correction table (graph A) of Fig. 21 upward to position E where the lightness 2302 of the target color for color variation suppression remains unchanged after correction. As shown in Fig. 23(b), the lightness 2302 of the target color for color variation suppression remains unchanged even after correction. Therefore, it is possible to expand the lightness in the lightness direction while eliminating any change in the lightness of the target color for color variation suppression.
[0157] In addition, when the target color for color variation suppression has a brightness between the maximum brightness color and the maximum saturation color, or when the brightness is between the minimum brightness color and the maximum saturation color, a correction table that expands the brightness in the brightness direction may be created using other methods.
[0158] Another method for creating a correction table for expanding the lightness when the target color for color variation suppression has a lightness between the maximum lightness color and the maximum saturation color will be described.
[0159] A correction table is created using the same method as the correction table in FIG. 21 based on color 1901, which is the maximum lightness color, color 1902, which is the minimum lightness color, and color 2401, which is the target color for color variation suppression, in FIG. 24(a). That is, the lightness after correction is determined by three points: the minimum lightness after correction, the lightness of the target color for color variation suppression after gamut mapping, and the maximum lightness after correction. The maximum lightness after correction is the lightness obtained by adding a correction amount Mh to the lightness of the target color for color variation suppression after gamut mapping. The minimum lightness after correction is the lightness obtained by subtracting a correction amount Ml from the lightness of the target color for color variation suppression after gamut mapping. Note that the correction amounts Mh and Ml here are calculated by replacing L1903, a1903, and b1903 with L2401, a2401, and b2401 in equations (7) and (8).
[0160] The table for expanding the brightness in the brightness direction is created by linearly changing the minimum brightness after correction to the brightness of the target color for color variation suppression after gamut mapping, and then linearly changing the brightness of the target color for color variation suppression after gamut mapping to the maximum brightness after correction. Figure 24(a) shows the correction table created as a result of the above method. As shown by point F in Figure 24(a), the brightness 2402 of the target color for color variation suppression remains unchanged after correction.
[0161] Another method for creating a correction table for expanding the lightness when the target color for color variation suppression has a lightness between the minimum lightness color and the maximum saturation color will be described.
[0162] A correction table is created using a method similar to that of the correction table in FIG. 21 based on color 1901, which is the maximum lightness color, color 1902, which is the minimum lightness color, and color 2411, which is the target color for color variation suppression. That is, the lightness after correction is determined by three points: the minimum lightness after correction, the lightness of the target color for color variation suppression after gamut mapping, and the maximum lightness after correction. The maximum lightness after correction is the lightness obtained by adding a correction amount Mh to the lightness of the target color for color variation suppression after gamut mapping. The minimum lightness after correction is the lightness obtained by subtracting a correction amount Ml from the lightness of the target color for color variation suppression after gamut mapping. Note that the correction amounts Mh and Ml here are calculated by replacing L1903, a1903, and b1903 with L2411, a2411, and b2411 in equations (7) and (8).
[0163] The table for expanding the brightness in the brightness direction is created by linearly changing the minimum brightness after correction to the brightness of the target color for color variation suppression after gamut mapping, and then linearly changing the brightness of the target color for color variation suppression after gamut mapping to the minimum brightness after correction. Figure 24(b) shows the correction table created as a result of the above method. As shown at point G in Figure 24(b), the brightness 2412 of the target color for color variation suppression remains unchanged after correction.
[0164] In this embodiment, a correction table is created for each hue range. However, a correction table may also be created for each adjacent hue range. Specifically, the number of color combinations that are color-degenerated is detected in the hue range combining hue range 1801 and hue range 1802 in FIG. 18 . Next, the number of color combinations that are color-degenerated is detected in the hue range combining hue range 1802 and hue range 1803. By detecting overlapping hue ranges, abrupt changes in the number of color combinations that are color-degenerated across hue ranges can be suppressed. In this case, a preferable hue range is a hue angle range in which the two hue ranges combined can be recognized as the same color. For example, the hue angle range in which the same color can be recognized in the CIE-L*A*B* color space is 30 degrees. Therefore, by creating correction tables with a 15-degree offset, abrupt changes in correction intensity across hue ranges can be suppressed.
[0165] In this embodiment, multiple unique colors are treated as a group and the color difference ΔE is corrected in the lightness direction. Sensitivity to lightness differences varies depending on saturation as a visual characteristic. Sensitivity to lightness differences at low saturation is higher than that at high saturation. Therefore, the amount of correction in the lightness direction may be controlled by the saturation value. For example, correction is performed so that the amount of correction is smaller at low saturation, and correction is performed at the above-mentioned amount at high saturation. Specifically, when applying the correction table to the gamut mapping table, the pre-correction lightness value Ln and the post-correction lightness value Lc are divided internally by the saturation correction factor S. The saturation correction factor S is calculated using the saturation value Sn of the gamut mapping output value and the maximum saturation value Sm of the post-gamut gamut gamut at the hue angle of the gamut mapping output value. The calculation formulas are (18) and (19).
[0166] S = Sn / Sm (18) Lc'=S×Lc+(1-S)×Ln (19) Furthermore, the amount of correction may be set to zero in the low saturation color gamut, thereby suppressing color changes on the gray axis.
[0167] By performing color degeneration correction in this way, it is possible to perform color degeneration correction in accordance with visual sensitivity, and therefore it is possible to suppress excessive correction.
[0168] As described above, according to this embodiment, by suppressing color correction of colors that are the target of color variation suppression, it is possible to maintain the effect of dynamic color degeneration correction while suppressing color variation due to color degeneration correction for colors for which it is important that the color tone remains consistent across pages.
[0169] The present invention can also be realized by supplying a program that realizes one or more functions of the above-described embodiments to a system or device via a network or a storage medium, and having one or more processors in the computer of the system or device read and execute the program.The present invention can also be realized by a circuit (e.g., ASIC) that realizes one or more functions.
[0170] The disclosure of the present embodiment includes the following image processing device, method, and program. (Item 1) a first acquisition means for acquiring color information of a first color gamut defined in the image data; a color conversion means for converting the color information of the first color gamut acquired by the first acquisition means into color information of a second color gamut narrower than the first color gamut; a correcting means for correcting the color conversion means so that the destination of the conversion by the color conversion means of the color information of the first color gamut is changed in the second color gamut; a second acquisition means for acquiring information indicating characteristics of color information of the first color gamut acquired by the first acquisition means in an image represented by the image data; a setting unit that sets color information of the first color gamut acquired by the first acquisition unit, the color information being a target for suppressing correction by the correction unit, based on information indicating characteristics of the color information of the first color gamut acquired by the second acquisition unit; a control means for controlling the correction means so as to suppress correction of the color information set by the setting means; An image processing device comprising: (Item 2) Item 1. The image processing device according to item 1, characterized in that the information acquired by the second acquisition means includes at least one of the number of pixels in the area corresponding to the color information of the first color gamut, the position on the image of the area corresponding to the color information of the first color gamut, and the size on the image of the area corresponding to the color information of the first color gamut. (Item 3) 3. The image processing device according to item 2, wherein the greater the number of pixels, the more likely it is that color information corresponding to that number of pixels will be set as a target for suppressing correction by the correction means. (Item 4) The image processing device described in item 2 or 3, characterized in that the closer the position of the area corresponding to the color information of the first color gamut is to the edge of the image, the more likely that the color information is set as a target for suppressing correction by the correction means. (Item 5) 5. The image processing device according to any one of items 2 to 4, wherein the larger the size, the more likely it is that color information corresponding to that size is set as a target for suppressing correction by the correction means. (Item 6) a third acquisition means for acquiring information indicating characteristics of color information of the first color gamut defined in second image data different from the image data, the setting means sets color information of the first color gamut acquired by the first acquisition means that is to be subject to suppression of correction by the correction means, based on information indicating characteristics of the color information of the first color gamut acquired by the second acquisition means and information indicating characteristics of the color information of the first color gamut acquired by the third acquisition means. 6. The image processing device according to any one of items 1 to 5, (Item 7) Item 6. The image processing device according to item 6, characterized in that the setting means sets color information of the first color gamut acquired by the first acquisition means that is to be targeted for suppression of correction by the correction means, based on the result of a comparison between the information acquired by the second acquisition means and the information acquired by the third acquisition means. (Item 8) Item 8. The image processing device according to item 7, characterized in that the more similar the information acquired by the second acquisition means and the information acquired by the third acquisition means are among the color information of the first color gamut acquired by the first acquisition means, the more likely the color information is to be set as a target for suppressing correction by the correction means. (Item 9) 9. The image processing device according to any one of items 6 to 8, wherein the image data and the second image data are data corresponding to pages included in a document. (Item 10) 10. The image processing device according to item 9, wherein the page corresponding to the second image data is a page preceding the page corresponding to the image data. (Item 11) 9. The image processing device according to any one of items 6 to 8, wherein the image data is image data included in a document, and the second image data is image data included in a document different from the document. (Item 12) 12. The image processing device according to any one of items 6 to 11, characterized in that color information of the first color gamut defined in the second image data is inherited from the second image data to the image data. (Item 13) Item 13. The image processing device according to item 12, wherein the inherited color information is stored as color information of the first color gamut defined in the image data. (Item 14) An image processing device according to any one of items 6 to 11, characterized in that accompanying information associated with the color information of the first color gamut defined in the second image data is carried over from the second image data to the image data. (Item 15) If the associated information satisfies the condition, color information corresponding to the associated information is stored as color information of the first color gamut defined in the image data; If the associated information does not satisfy the condition, the color information corresponding to the associated information is not stored as color information of the first color gamut defined in the image data. Item 15. The image processing device according to item 14. (Item 16) Item 16. The image processing device according to item 15, wherein the accompanying information is the number of pixels, and the condition is that the number of pixels is greater than a threshold value. (Item 17) Item 17. The image processing device according to item 16, wherein the accompanying information is passed on in an attenuated state. (Item 18) 18. The image processing device according to any one of items 1 to 17, characterized in that, when the color information of the first color gamut acquired by the first acquisition means includes color information specified by a user, the setting means sets the color information specified by the user as a target for suppressing correction by the correction means. (Item 19) 19. The image processing device according to any one of items 1 to 18, wherein the correction means corrects the color conversion means so as to increase the color difference in the second color gamut when conversion is performed by the color conversion means. (Item 20) 20. The image processing device according to item 19, wherein the correction means corrects the color conversion means so that the color difference becomes at least a predetermined color difference. (Item 21) 21. The image processing device according to item 19 or 20, wherein the control means controls the correction means so as to limit the amount of correction for the color information set by the setting means to a predetermined range. (Item 22) 22. The image processing device according to item 21, wherein the predetermined range is a range of correction amounts in which a change in color is difficult for a user to visually recognize. (Item 23) 21. The image processing device according to item 19 or 20, wherein the control means controls the correction means so as not to perform correction on the color information set by the setting means. (Item 24) 24. The image processing device according to any one of items 19 to 23, wherein the correction means corrects the color conversion means so as to increase the color difference in at least one direction of lightness, saturation, and hue angle. (Item 25) 24. The image processing device according to any one of items 19 to 23, wherein the correction means corrects the color conversion means so as to increase the color difference in the direction of brightness. (Item 26) Item 26. The image processing device according to item 25, wherein the correction means corrects the color conversion means so as to increase the color difference in the direction of lightness between colors included in a predetermined hue angle. (Item 27) 27. The image processing device according to any one of items 1 to 26, wherein the second color gamut is a reproduction color gamut in a printing device. (Item 28) 1. A method performed in an image processing device, comprising: a first acquisition step of acquiring color information of a first color gamut defined in the image data; a color conversion step of converting the color information of the first color gamut acquired in the first acquisition step into color information of a second color gamut narrower than the first color gamut by a color conversion means; a correcting step of correcting the color conversion means so that a conversion destination of the color information of the first color gamut in the color conversion step is changed to the second color gamut; a second acquisition step of acquiring information indicating characteristics of the color information of the first color gamut acquired in the first acquisition step in the image represented by the image data; a setting step of setting color information of the first color gamut acquired in the first acquisition step, the color information being a target of suppression of correction in the correction step, based on information indicating characteristics of the color information of the first color gamut acquired in the second acquisition step; a control step of controlling the correction step so as to suppress correction of the color information set in the setting step; A method comprising: (Item 29) 28. A program for causing a computer to function as each means of the image processing device according to any one of items 1 to 27.
[0171] The invention is not limited to the above-described embodiments, and various changes and modifications can be made without departing from the spirit and scope of the invention. Accordingly, the following claims are appended to apprise the public of the scope of the invention. [Explanation of symbols]
[0172] 101 Image processing device: 108 Recording device: 102, 111 CPU: 103, 112 RAM: 104, 113 Storage medium
Claims
1. a first acquisition means for acquiring color information of a first color gamut defined in the image data; a color conversion unit that converts the color information of the first color gamut acquired by the first acquisition unit into color information of a second color gamut that is narrower than the first color gamut; a correcting unit that corrects the color conversion unit so that the destination of the conversion by the color conversion unit of the color information of the first color gamut is changed in the second color gamut; a second acquisition means for acquiring information indicating characteristics of color information of the first color gamut acquired by the first acquisition means in an image represented by the image data; a setting unit that sets color information of the first color gamut acquired by the first acquisition unit, the color information being a target for suppressing correction by the correction unit, based on information indicating characteristics of the color information of the first color gamut acquired by the second acquisition unit; a control means for controlling the correction means so as to suppress correction of the color information set by the setting means; An image processing device comprising:
2. 2. The image processing device according to claim 1, wherein the information acquired by the second acquisition means includes at least one of the number of pixels in the area corresponding to the color information of the first color gamut, the position on the image of the area corresponding to the color information of the first color gamut, and the size on the image of the area corresponding to the color information of the first color gamut.
3. 3. The image processing apparatus according to claim 2, wherein the greater the number of pixels, the more likely the color information corresponding to that number of pixels is to be set as a target for suppressing correction by the correcting means.
4. 3. The image processing device according to claim 2, wherein the closer the position of the area corresponding to the color information of the first color gamut is to the edge of the image, the more likely the color information is to be set as a target for suppressing correction by the correction means.
5. 3. The image processing apparatus according to claim 2, wherein the larger the size, the more likely the color information corresponding to that size is set as a target for suppressing correction by the correction unit.
6. a third acquisition means for acquiring information indicating characteristics of color information of the first color gamut defined in second image data different from the image data, the setting means sets color information of the first color gamut acquired by the first acquisition means that is to be targeted for suppression of correction by the correction means, based on information indicating characteristics of the color information of the first color gamut acquired by the second acquisition means and information indicating characteristics of the color information of the first color gamut acquired by the third acquisition means.
2. The image processing device according to claim 1, wherein:
7. 7. The image processing device according to claim 6, wherein the setting means sets color information of the first color gamut acquired by the first acquisition means that is to be targeted for suppression of correction by the correction means based on a result of a comparison between the information acquired by the second acquisition means and the information acquired by the third acquisition means.
8. The image processing device described in claim 7, characterized in that the more similar the information acquired by the second acquisition means and the information acquired by the third acquisition means are among the color information of the first color gamut acquired by the first acquisition means, the more likely the color information is to be set as a target for suppressing correction by the correction means.
9. 7. The image processing apparatus according to claim 6, wherein the image data and the second image data correspond to pages included in a document.
10. 10. The image processing apparatus according to claim 9, wherein the page corresponding to the second image data is a page preceding the page corresponding to the image data.
11. 7. The image processing apparatus according to claim 6, wherein the image data is image data included in a document, and the second image data is image data included in a document different from the image data.
12. 7. The image processing apparatus according to claim 6, wherein color information of the first color gamut defined in the second image data is inherited from the second image data to the image data.
13. 13. The image processing apparatus according to claim 12, wherein the inherited color information is stored as color information of the first color gamut defined in the image data.
14. 7. The image processing apparatus according to claim 6, wherein accompanying information accompanying color information of the first color gamut defined in the second image data is inherited from the second image data to the image data.
15. If the associated information satisfies the condition, color information corresponding to the associated information is stored as color information of the first color gamut defined in the image data; If the associated information does not satisfy the condition, the color information corresponding to the associated information is not stored as color information of the first color gamut defined in the image data.
15. The image processing device according to claim 14.
16. 16. The image processing apparatus according to claim 15, wherein the accompanying information is the number of pixels, and the condition is that the number of pixels is greater than a threshold value.
17. 17. The image processing apparatus according to claim 16, wherein the accompanying information is passed on in a decayed state.
18. 2. The image processing device according to claim 1, wherein, when the color information of the first color gamut acquired by the first acquisition means includes color information specified by a user, the setting means sets the color information specified by the user as a target for suppressing correction by the correction means.
19. 2. The image processing device according to claim 1, wherein the correction means corrects the color conversion means so as to increase the color difference in the second color gamut when conversion is performed by the color conversion means.
20. 20. The image processing apparatus according to claim 19, wherein said correcting means corrects said color converting means so that said color difference becomes at least a predetermined color difference.
21. 20. The image processing apparatus according to claim 19, wherein said control means controls said correction means so as to limit the amount of correction for the color information set by said setting means to a predetermined range.
22. 22. The image processing apparatus according to claim 21, wherein the predetermined range is a range of correction amounts in which a change in color is difficult for a user to visually recognize.
23. 20. The image processing apparatus according to claim 19, wherein said control means controls said correction means so as not to perform correction on the color information set by said setting means.
24. 20. The image processing apparatus according to claim 19, wherein said correcting means corrects said color converting means so as to increase the color difference in at least one direction of lightness, saturation, and hue angle.
25. 20. The image processing apparatus according to claim 19, wherein said correcting means corrects said color converting means so as to increase said color difference in the direction of brightness.
26. 26. The image processing apparatus according to claim 25, wherein said correcting means corrects said color converting means so as to increase the color difference in the direction of lightness between colors included in a predetermined hue angle.
27. 2. The image processing apparatus according to claim 1, wherein the second color gamut is a reproduction color gamut of a printing device.
28. 1. A method performed in an image processing device, comprising: a first acquisition step of acquiring color information of a first color gamut defined in the image data; a color conversion step of converting the color information of the first color gamut acquired in the first acquisition step into color information of a second color gamut narrower than the first color gamut by a color conversion means; a correcting step of correcting the color conversion means so that a conversion destination of the color information of the first color gamut in the color conversion step is changed to the second color gamut; a second acquisition step of acquiring information indicating characteristics of the color information of the first color gamut acquired in the first acquisition step in the image represented by the image data; a setting step of setting color information to be subjected to suppression of correction in the correction step, among the color information of the first color gamut acquired in the first acquisition step, based on information indicating characteristics of the color information of the first color gamut acquired in the second acquisition step; a control step of controlling the correction step so as to suppress correction of the color information set in the setting step; A method comprising:
29. 28. A program for causing a computer to function as each of the means of the image processing apparatus according to any one of claims 1 to 27.
Citation Information
Patent Citations
Image processing apparatus, image processing method, and program
JP2024008263A